Hi. i'm creating a application using the blazor components, this app has 2 main ways of creating records, one is trough a EditForm (blazor) and the other simpler method is using directly the SFGrid, inside the EditForm i'm using the FluentValidator Component.
Example Bellow:
<EditForm @attributes="atributes" Model="@Item.Entity" OnValidSubmit="@OnValidSubmitAsync" OnInvalidSubmit="@OnInvalidSubmitAsync">
@if (Validator != null)
{
<FluentValidator Validator="@Validator" />
<ValidationSummary />
}
@LayoutFragment(Item.Entity)
</EditForm>
But with the grid, i'm using the standard modal with a custom ActionBegin
<SfGrid ID="Grid" @ref="@Grid" TValue="TEntity" DataSource="@DataSource" AllowFiltering="true" AllowPaging="true" Toolbar="@ToolbarOptions" AllowExcelExport="true" AllowPdfExport="true" Height="315">
<GridEditSettings AllowAdding="true" AllowDeleting="true" AllowEditing="true" ShowDeleteConfirmDialog="true" Mode="EditMode.Dialog" Dialog="DialogParams">
<HeaderTemplate>
@{
var text = ModalHeaderText((context as TEntity));
<span>@text</span>
}
</HeaderTemplate>
</GridEditSettings>
<GridPageSettings PageSize="5"></GridPageSettings>
<GridFilterSettings Type="Syncfusion.Blazor.Grids.FilterType.Excel"></GridFilterSettings>
<GridSelectionSettings Mode="SelectionMode.Row" Type="Syncfusion.Blazor.Grids.SelectionType.Single"></GridSelectionSettings>
<GridEvents OnActionBegin="ActionBegin" OnToolbarClick="ToolbarClick" TValue="TEntity"></GridEvents>
<GridColumns>
@SimpleGridColumns
</GridColumns>
</SfGrid>
My question boils down to "How can i use the fluent validation i already have inside the modal of the Grid?"