GUI: TransactionRecord: Turn non-bitcoin fees into entries

This commit is contained in:
Luke Dashjr 2018-12-15 04:42:25 +00:00 committed by Gregory Sanders
parent ef2f717e67
commit a582fe03e4

View file

@ -144,13 +144,13 @@ QList<TransactionRecord> TransactionRecord::decomposeTransaction(const interface
}
parts.append(sub);
}
CAmount nTxFee = GetFeeMap(*wtx.tx)[::policyAsset];
if (nTxFee > 0)
{
for (const auto& tx_fee : GetFeeMap(*wtx.tx)) {
if (!tx_fee.second) continue;
TransactionRecord sub(hash, nTime);
sub.type = TransactionRecord::Fee;
sub.amount = -nTxFee;
sub.asset = ::policyAsset;
sub.asset = tx_fee.first;
sub.amount = -tx_fee.second;
parts.append(sub);
}
}