Pull Payment UI: Redesign

This commit is contained in:
Dennis Reimann
2020-09-30 19:14:30 +02:00
parent 8a4834dd2b
commit 652604a36f
3 changed files with 155 additions and 129 deletions

View File

@@ -1,6 +1,7 @@
using System;
using System.Globalization;
using System.Linq;
using System.Text.RegularExpressions;
using System.Threading.Tasks;
using BTCPayServer;
using BTCPayServer.Data;
@@ -69,13 +70,13 @@ namespace BTCPayServer.Controllers
CurrencyData = cd,
LastUpdated = DateTime.Now,
Payouts = payouts
.Select(entity => new ViewPullPaymentModel.PayoutLine()
.Select(entity => new ViewPullPaymentModel.PayoutLine
{
Id = entity.Entity.Id,
Amount = entity.Blob.Amount,
AmountFormatted = _currencyNameTable.FormatCurrency(entity.Blob.Amount, blob.Currency),
Currency = blob.Currency,
Status = entity.Entity.State.ToString(),
Status = Regex.Replace(entity.Entity.State.ToString(), "(\\B[A-Z])", " $1"),
Destination = entity.Blob.Destination.Address.ToString(),
Link = GetTransactionLink(_networkProvider.GetNetwork<BTCPayNetwork>(entity.Entity.GetPaymentMethodId().CryptoCode), entity.TransactionId),
TransactionId = entity.TransactionId