Closed BogdanJak closed 2 years ago
I use Syncfusion in new pages but I have a problem with rewriting the code for pages with e.g. UserManagement.
Procedure
protected override Task OpenCreateModalAsync()
{
CreateModalSelectedTab = DefaultSelectedTab;
NewUserRoles = Roles.Select(x => new AssignedRoleViewModel
{
Name = x.Name,
IsAssigned = x.IsDefault
}).ToArray();
return base.OpenCreateModalAsync();
}
refers to AbpCrudPageBase.cs from Volo.Abp.BlazoriseUI There is procedure in this class
protected Modal CreateModal;
and from the level of AbpCrudPageBase the Modal component from Blazorise is opened
Procedure
protected virtual async Task OpenCreateModalAsync()
{
try
{
if (CreateValidationsRef != null)
{
await CreateValidationsRef.ClearAll();
}
await CheckCreatePolicyAsync();
NewEntity = new TCreateViewModel();
// Mapper will not notify Blazor that binded values are changed
// so we need to notify it manually by calling StateHasChanged
await InvokeAsync(async () =>
{
StateHasChanged();
if (CreateModal != null)
{
await CreateModal.Show();
}
});
}
catch (Exception ex)
{
await HandleErrorAsync(ex);
}
}
?
Unfortunately, there is no option for replacing entire components from a single point. If you really want to do it, you have to replace all components with your chosen component one by one.
I'm not sure but Blazorise might have some adapters.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
ABP Framework version - 5.2.2 User Interface - Blazor Server Database provider - EF Core / SQL Server
Is it possible to replace the native Blazorise controls in a component, e.g. UserManagement, with controls such as Syncfusion?
I am able to do the frontend without any problems. But I already have a problem with the backend - eg in the "OpenCreateModalAsync" function, which uses the AbpCrudPageBase class - the procedure for opening the Modal component from Blazorise is permanently entered. Could it be changed in a simpler way without rewriting the whole code from scratch?