mirror of
https://github.com/DrMboga/WotBlitzStatisticsBlazor.git
synced 2026-10-23 19:30:06 +02:00
feat: player achievements view
This commit is contained in:
1 parent
3767ff6a71
commit
fff699faf1
12 files changed
+210
-58
No files matched your search
@@ -0,0 +1,35 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using WotBlitzStatisticsPro.Blazor.GraphQl;
|
||||
using MediatR;
|
||||
using Radzen;
|
||||
using WotBlitzStatisticsPro.Blazor.Messages;
|
||||
using WotBlitzStatisticsPro.Blazor.Pages;
|
||||
|
||||
namespace WotBlitzStatisticsPro.Blazor.Services
|
||||
{
|
||||
public class MedalDialogService: IMedalDialogService, INotificationHandler<OpenMedalDescriptionMessage>
|
||||
{
|
||||
private readonly DialogService _dialogService;
|
||||
|
||||
public MedalDialogService(DialogService dialogService)
|
||||
{
|
||||
_dialogService = dialogService;
|
||||
}
|
||||
|
||||
public async Task OpenMedalInfoDIalog(IMedal medalInfo)
|
||||
{
|
||||
await _dialogService.OpenAsync<MedalInfoDialog>(medalInfo.Name,
|
||||
new Dictionary<string, object>() { { "MedalInfo", medalInfo } },
|
||||
new DialogOptions() { Width = "412px", Height = "600px" });
|
||||
|
||||
|
||||
}
|
||||
|
||||
public Task Handle(OpenMedalDescriptionMessage notification, CancellationToken cancellationToken)
|
||||
{
|
||||
return OpenMedalInfoDIalog(notification.MedalInfo);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user