Skip to content

Commit

Permalink
History: sort by blockheight for date ordering
Browse files Browse the repository at this point in the history
  • Loading branch information
tobtoht committed Jan 21, 2024
1 parent c4beab7 commit f291649
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/model/TransactionHistoryModel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,10 @@ QVariant TransactionHistoryModel::parseTransactionInfo(const TransactionRow &tIn
case Column::Date:
{
if (role == Qt::UserRole) {
return tInfo.timestamp();
if (tInfo.blockHeight() > 0) {
return tInfo.blockHeight();
}
return tInfo.timestamp().toMSecsSinceEpoch();
}
return tInfo.timestamp().toString(QString("%1 %2 ").arg(conf()->get(Config::dateFormat).toString(),
conf()->get(Config::timeFormat).toString()));
Expand Down

0 comments on commit f291649

Please sign in to comment.