Browse Source

msec fixes

import_zecw
Aditya Kulkarni 6 years ago
parent
commit
56e45bc64c
  1. 2
      src/senttxstore.cpp
  2. 4
      src/txtablemodel.cpp

2
src/senttxstore.cpp

@ -87,7 +87,7 @@ void SentTxStore::addToSentTx(Tx tx, QString txid) {
QJsonObject txItem;
txItem["type"] = "sent";
txItem["from"] = tx.fromAddr;
txItem["datetime"] = QDateTime().currentMSecsSinceEpoch();
txItem["datetime"] = QDateTime().currentMSecsSinceEpoch() / 1000;
txItem["address"] = QString(); // The sent address is blank, to be consistent with t-Addr sent behaviour
txItem["txid"] = txid;
txItem["amount"] = -totalAmount;

4
src/txtablemodel.cpp

@ -98,7 +98,7 @@ void TxTableModel::updateAllData() {
else
return addr;
}
case 2: return QDateTime::fromMSecsSinceEpoch(modeldata->at(index.row()).datetime).toLocalTime().toString();
case 2: return QDateTime::fromMSecsSinceEpoch(modeldata->at(index.row()).datetime * 1000).toLocalTime().toString();
case 3: return Settings::getInstance()->getZECDisplayFormat(modeldata->at(index.row()).amount);
}
}
@ -114,7 +114,7 @@ void TxTableModel::updateAllData() {
else
return addr;
}
case 2: return QDateTime::fromMSecsSinceEpoch(modeldata->at(index.row()).datetime).toLocalTime().toString();
case 2: return QDateTime::fromMSecsSinceEpoch(modeldata->at(index.row()).datetime * 1000).toLocalTime().toString();
case 3: return Settings::getInstance()->getUSDFormat(modeldata->at(index.row()).amount);
}
}

Loading…
Cancel
Save