mirror of
https://github.com/status-im/nft-faucet.git
synced 2025-02-24 04:28:29 +00:00
26 lines
823 B
C#
26 lines
823 B
C#
using Microsoft.AspNetCore.Components;
|
|
using Radzen;
|
|
|
|
namespace NftFaucetRadzen.Components.CardList;
|
|
|
|
public partial class CardListItemConfigurationDialog : BasicComponent
|
|
{
|
|
[Parameter] public Guid CardListItemId { get; set; }
|
|
[Parameter] public CardListItem CardListItem { get; set; }
|
|
|
|
private async Task OnSavePressed()
|
|
{
|
|
var result = await CardListItem.Configuration.ConfigureAction(CardListItem.Configuration.Objects);
|
|
if (result.IsFailure)
|
|
{
|
|
NotificationService.Notify(NotificationSeverity.Error, "Invalid configuration", result.Error);
|
|
return;
|
|
}
|
|
|
|
await CardListItem.Configuration.ConfigureAction(CardListItem.Configuration.Objects);
|
|
RefreshMediator.NotifyStateHasChangedSafe();
|
|
|
|
DialogService.Close((bool?)true);
|
|
}
|
|
}
|