btcpayserver/BTCPayServer/Events/InvoiceDataChangedEvent.cs

21 lines
503 B
C#
Raw Normal View History

2021-12-31 08:59:02 +01:00
using BTCPayServer.Services.Invoices;
namespace BTCPayServer.Events
{
public class InvoiceDataChangedEvent : IHasInvoiceId
{
2018-02-17 05:18:16 +01:00
public InvoiceDataChangedEvent(InvoiceEntity invoice)
{
InvoiceId = invoice.Id;
State = invoice.GetInvoiceState();
2018-02-17 05:18:16 +01:00
}
public string InvoiceId { get; }
public InvoiceState State { get; }
public override string ToString()
{
return $"Invoice status is {State}";
}
}
}