2017-12-17 06:17:42 +01:00
|
|
|
|
using System;
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
|
|
namespace BTCPayServer.Events
|
|
|
|
|
{
|
|
|
|
|
public class InvoiceDataChangedEvent
|
|
|
|
|
{
|
|
|
|
|
public string InvoiceId { get; set; }
|
2018-01-14 13:48:23 +01:00
|
|
|
|
public string Status { get; internal set; }
|
|
|
|
|
public string ExceptionStatus { get; internal set; }
|
2017-12-17 06:17:42 +01:00
|
|
|
|
|
|
|
|
|
public override string ToString()
|
|
|
|
|
{
|
2018-01-14 13:48:23 +01:00
|
|
|
|
if (string.IsNullOrEmpty(ExceptionStatus) || ExceptionStatus == "false")
|
|
|
|
|
{
|
|
|
|
|
return $"Invoice status is {Status}";
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
{
|
|
|
|
|
return $"Invoice status is {Status} (Exception status: {ExceptionStatus})";
|
|
|
|
|
}
|
2017-12-17 06:17:42 +01:00
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|