Files
btcpayserver/BTCPayServer/Services/Notifications/INotificationHandler.cs
Andrew Camilleri 1440e8c55d BTCPay Server Extensions (#1925)
* BTCPay Server Extensions

![demo](https://i.imgur.com/2S00aL2.gif)

* cleanup

* fix

* Polish UI a bit,detect when docker deployment
2020-10-15 21:28:09 +09:00

19 lines
656 B
C#

using System;
using BTCPayServer.Contracts;
using BTCPayServer.Models.NotificationViewModels;
namespace BTCPayServer.Services.Notifications
{
public abstract class NotificationHandler<TNotification> : INotificationHandler
{
public abstract string NotificationType { get; }
Type INotificationHandler.NotificationBlobType => typeof(TNotification);
void INotificationHandler.FillViewModel(object notification, NotificationViewModel vm)
{
FillViewModel((TNotification)notification, vm);
}
protected abstract void FillViewModel(TNotification notification, NotificationViewModel vm);
}
}