diff --git a/SiemensIXBlazor/Components/AGGrid/AGGrid.razor.cs b/SiemensIXBlazor/Components/AGGrid/AGGrid.razor.cs index b146401..cc4fa96 100644 --- a/SiemensIXBlazor/Components/AGGrid/AGGrid.razor.cs +++ b/SiemensIXBlazor/Components/AGGrid/AGGrid.razor.cs @@ -4,19 +4,19 @@ namespace SiemensIXBlazor.Components.AGGrid { - public partial class AGGrid - { - [Parameter, EditorRequired] - public string Id { get; set; } = string.Empty; + public partial class AGGrid + { + [Parameter, EditorRequired] + public string Id { get; set; } = string.Empty; - public async Task CreateGrid(GridOptions options) - { - if (Id == string.Empty) - { - return; - } + public async Task CreateGrid(GridOptions options) + { + if (Id == string.Empty) + { + return null; + } - await JSRuntime.InvokeVoidAsync("agGridInterop.createGrid", Id, JsonConvert.SerializeObject(options)); - } - } + return await JSRuntime.InvokeAsync("agGridInterop.createGrid", Id, JsonConvert.SerializeObject(options)); + } + } }