mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2025-12-17 22:14:26 +01:00
Properly counting transactions that impact NetworkFee
This commit is contained in:
committed by
Andrew Camilleri
parent
edc9429e84
commit
48355129c5
@@ -557,6 +557,13 @@ namespace BTCPayServer.Controllers
|
||||
RedirectAutomatically = invoice.RedirectAutomatically,
|
||||
StoreName = store.StoreName,
|
||||
TxCount = accounting.TxRequired,
|
||||
TxCountForFee = storeBlob.NetworkFeeMode switch
|
||||
{
|
||||
NetworkFeeMode.Always => accounting.TxRequired,
|
||||
NetworkFeeMode.MultiplePaymentsOnly => accounting.TxRequired - 1,
|
||||
NetworkFeeMode.Never => 0,
|
||||
_ => throw new NotImplementedException()
|
||||
},
|
||||
BtcPaid = accounting.Paid.ShowMoney(divisibility),
|
||||
#pragma warning disable CS0618 // Type or member is obsolete
|
||||
Status = invoice.StatusString,
|
||||
|
||||
@@ -49,6 +49,7 @@ namespace BTCPayServer.Models.InvoicingModels
|
||||
public string InvoiceBitcoinUrl { get; set; }
|
||||
public string InvoiceBitcoinUrlQR { get; set; }
|
||||
public int TxCount { get; set; }
|
||||
public int TxCountForFee { get; set; }
|
||||
public string BtcPaid { get; set; }
|
||||
public string StoreEmail { get; set; }
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@model PaymentModel
|
||||
@model PaymentModel
|
||||
|
||||
<div class="top-header">
|
||||
<div class="header">
|
||||
@@ -133,7 +133,7 @@
|
||||
{{ srvModel.networkFee }} {{ srvModel.cryptoCode }}
|
||||
</span>
|
||||
<span v-else>
|
||||
{{$t("txCount", {count: srvModel.txCount})}} x {{ srvModel.networkFee }} {{ srvModel.cryptoCode }}
|
||||
{{$t("txCount", {count: srvModel.txCountForFee})}} x {{ srvModel.networkFee }} {{ srvModel.cryptoCode }}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user