2020-06-11 18:14:23 -05:00
|
|
|
|
using BTCPayServer.Data;
|
2020-06-11 01:00:41 -05:00
|
|
|
|
using BTCPayServer.Models.NotificationViewModels;
|
|
|
|
|
using Newtonsoft.Json;
|
2020-05-27 18:41:00 -05:00
|
|
|
|
|
2020-06-14 23:47:11 -05:00
|
|
|
|
namespace BTCPayServer.Services.Notifications.Blobs
|
2020-05-27 18:41:00 -05:00
|
|
|
|
{
|
2020-06-14 23:48:58 -05:00
|
|
|
|
internal class NewVersionNotification : BaseNotification
|
2020-05-27 18:41:00 -05:00
|
|
|
|
{
|
2020-06-13 18:40:30 -05:00
|
|
|
|
internal override string NotificationType => "NewVersionNotification";
|
|
|
|
|
|
2020-05-27 18:41:00 -05:00
|
|
|
|
public string Version { get; set; }
|
2020-06-11 01:00:41 -05:00
|
|
|
|
|
2020-06-15 00:36:50 -05:00
|
|
|
|
public override void FillViewModel(ref NotificationViewModel vm)
|
2020-06-11 01:00:41 -05:00
|
|
|
|
{
|
2020-06-14 23:17:21 -05:00
|
|
|
|
vm.Body = $"New version {Version} released!";
|
|
|
|
|
vm.ActionLink = $"https://github.com/btcpayserver/btcpayserver/releases/tag/v{Version}";
|
2020-06-11 01:00:41 -05:00
|
|
|
|
}
|
2020-05-27 18:41:00 -05:00
|
|
|
|
}
|
|
|
|
|
}
|