Make filtering out change explicit

This commit is contained in:
Aditya Kulkarni
2018-10-24 09:39:32 -07:00
parent fed17ba0ee
commit 60c047bf71
3 changed files with 25 additions and 9 deletions

View File

@@ -42,7 +42,7 @@ QList<TransactionItem> SentTxStore::readSentTxFile() {
sentTx["address"].toString(),
sentTx["txid"].toString(),
sentTx["amount"].toDouble() + sentTx["fee"].toDouble(),
0};
0, sentTx["from"].toString()};
items.push_back(t);
}
@@ -81,6 +81,7 @@ void SentTxStore::addToSentTx(Tx tx, QString txid) {
auto list = jsonDoc.array();
QJsonObject txItem;
txItem["type"] = "sent";
txItem["from"] = tx.fromAddr;
txItem["datetime"] = QDateTime().currentSecsSinceEpoch();
txItem["address"] = QString(); // The sent address is blank, to be consistent with t-Addr sent behaviour
txItem["txid"] = txid;