aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorselsta <selsta@sent.at>2020-04-22 22:05:20 +0200
committerselsta <selsta@sent.at>2020-04-28 19:30:22 +0200
commit2102e4be0d0888e66b50ed71150fc9d4b1cb1566 (patch)
treeec179a05e3d13ce9a2c0e59b39071555ff6bca16
parent3af99e91e4d61b1e63ab3ff780febc338e335add (diff)
downloadmonzero-gui-2102e4be0d0888e66b50ed71150fc9d4b1cb1566.tar.gz
monzero-gui-2102e4be0d0888e66b50ed71150fc9d4b1cb1566.tar.xz
monzero-gui-2102e4be0d0888e66b50ed71150fc9d4b1cb1566.zip
Merchant: fix confirmations
-rw-r--r--pages/merchant/Merchant.qml10
1 files changed, 3 insertions, 7 deletions
diff --git a/pages/merchant/Merchant.qml b/pages/merchant/Merchant.qml
index a474719a..8602945a 100644
--- a/pages/merchant/Merchant.qml
+++ b/pages/merchant/Merchant.qml
@@ -593,7 +593,6 @@ Item {
var model = appWindow.currentWallet.historyModel
var count = model.rowCount()
var nTransactions = 0
- var blockchainHeight = null
var txs = []
// Currently selected subaddress as per Receive page
@@ -616,15 +615,12 @@ Item {
var in_txpool = false;
var confirmations = 0;
- var displayAmount = 0;
+ var displayAmount = model.data(idx, TransactionHistoryModel.TransactionDisplayAmountRole);
- if (blockHeight == 0) {
+ if (blockHeight === undefined) {
in_txpool = true;
} else {
- if (blockchainHeight == null)
- blockchainHeight = walletManager.blockchainHeight()
- confirmations = blockchainHeight - blockHeight - 1
- displayAmount = model.data(idx, TransactionHistoryModel.TransactionDisplayAmountRole);
+ confirmations = model.data(idx, TransactionHistoryModel.TransactionConfirmationsRole);
}
txs.push({