Fix a bunch of warnings
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
<MudTooltip Text="Delete">
|
||||
<MudIconButton Icon="@Icons.Material.Outlined.Delete"
|
||||
Color="Color.Error"
|
||||
OnClick="() => DeleteOnClick()"/>
|
||||
OnClick="HandleDeleteClick"/>
|
||||
</MudTooltip>
|
||||
}
|
||||
</MudButtonGroup>
|
||||
@@ -25,5 +25,13 @@
|
||||
|
||||
[Parameter] public string? DetailsHref { get; set; }
|
||||
[Parameter] public string? EditHref { get; set; }
|
||||
[Parameter] public Action? DeleteOnClick { get; set; }
|
||||
[Parameter] public Func<Task>? DeleteOnClick { get; set; }
|
||||
|
||||
private async Task HandleDeleteClick()
|
||||
{
|
||||
if (DeleteOnClick != null)
|
||||
{
|
||||
await DeleteOnClick();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user