From 6c5e2930306f7a687ca64c47b4b469dd5e72ab2a Mon Sep 17 00:00:00 2001 From: levoncrypto Date: Fri, 20 Sep 2024 00:24:16 +0400 Subject: [PATCH] Sorting of PoSe score on masternode list by number --- src/qt/masternodelist.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/qt/masternodelist.cpp b/src/qt/masternodelist.cpp index 906b924326..685a845434 100644 --- a/src/qt/masternodelist.cpp +++ b/src/qt/masternodelist.cpp @@ -214,7 +214,8 @@ void MasternodeList::updateDIP3List() // Address, Protocol, Status, Active Seconds, Last Seen, Pub Key QTableWidgetItem* addressItem = new QTableWidgetItem(QString::fromStdString(dmn->pdmnState->addr.ToString())); QTableWidgetItem* statusItem = new QTableWidgetItem(mnList.IsMNValid(dmn) ? tr("ENABLED") : (mnList.IsMNPoSeBanned(dmn) ? tr("POSE_BANNED") : tr("UNKNOWN"))); - QTableWidgetItem* PoSeScoreItem = new QTableWidgetItem(QString::number(dmn->pdmnState->nPoSePenalty)); + QTableWidgetItem* PoSeScoreItem = new QTableWidgetItem(); + PoSeScoreItem->setData(Qt::EditRole, dmn->pdmnState->nPoSePenalty); QTableWidgetItem* registeredItem = new QTableWidgetItem(QString::number(dmn->pdmnState->nRegisteredHeight)); QTableWidgetItem* lastPaidItem = new QTableWidgetItem((dmn->pdmnState->nLastPaidHeight < params.DIP0003EnforcementHeight) ? tr("NONE") : QString::number(dmn->pdmnState->nLastPaidHeight)); QTableWidgetItem* nextPaymentItem = new QTableWidgetItem(nextPayments.count(dmn->proTxHash) ? QString::number(nextPayments[dmn->proTxHash]) : tr("UNKNOWN"));