mirror of
https://github.com/dashpay/dash.git
synced 2024-12-27 21:12:48 +01:00
New Command: masternode list pose
- Shows proof-of-service score for masternodes
This commit is contained in:
parent
1a6be53733
commit
701886c8d5
@ -721,8 +721,8 @@ Value masternodelist(const Array& params, bool fHelp)
|
|||||||
if (params.size() == 2) strFilter = params[1].get_str();
|
if (params.size() == 2) strFilter = params[1].get_str();
|
||||||
|
|
||||||
if (fHelp ||
|
if (fHelp ||
|
||||||
(strMode != "active" && strMode != "vin" && strMode != "pubkey" && strMode != "lastseen"
|
(strMode != "active" && strMode != "vin" && strMode != "pubkey" && strMode != "lastseen" && strMode != "activeseconds" && strMode != "rank"
|
||||||
&& strMode != "activeseconds" && strMode != "rank" && strMode != "protocol" && strMode != "full" && strMode != "votes" && strMode != "donation"))
|
&& strMode != "protocol" && strMode != "full" && strMode != "votes" && strMode != "donation" && strMode != "pose"))
|
||||||
{
|
{
|
||||||
throw runtime_error(
|
throw runtime_error(
|
||||||
"masternodelist ( \"mode\" \"filter\" )\n"
|
"masternodelist ( \"mode\" \"filter\" )\n"
|
||||||
@ -741,6 +741,7 @@ Value masternodelist(const Array& params, bool fHelp)
|
|||||||
" vin - Print vin associated with a masternode (can be additionally filtered, partial match)\n"
|
" vin - Print vin associated with a masternode (can be additionally filtered, partial match)\n"
|
||||||
" votes - Print all masternode votes for a Dash initiative\n"
|
" votes - Print all masternode votes for a Dash initiative\n"
|
||||||
" donation - Show donation settings\n"
|
" donation - Show donation settings\n"
|
||||||
|
" pose - Show proof-of-service score\n"
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -840,6 +841,12 @@ Value masternodelist(const Array& params, bool fHelp)
|
|||||||
strOut += ":";
|
strOut += ":";
|
||||||
strOut += boost::lexical_cast<std::string>(mn.donationPercentage);
|
strOut += boost::lexical_cast<std::string>(mn.donationPercentage);
|
||||||
}
|
}
|
||||||
|
obj.push_back(Pair(strAddr, strOut.c_str()));
|
||||||
|
} else if (strMode == "pose") {
|
||||||
|
if(strFilter !="" && strAddr.find(strFilter) == string::npos) continue;
|
||||||
|
|
||||||
|
std::string strOut = boost::lexical_cast<std::string>(mn.nScanningErrorCount);
|
||||||
|
|
||||||
obj.push_back(Pair(strAddr, strOut.c_str()));
|
obj.push_back(Pair(strAddr, strOut.c_str()));
|
||||||
} else if (strMode == "vin") {
|
} else if (strMode == "vin") {
|
||||||
if(strFilter !="" && mn.vin.prevout.hash.ToString().find(strFilter) == string::npos &&
|
if(strFilter !="" && mn.vin.prevout.hash.ToString().find(strFilter) == string::npos &&
|
||||||
|
Loading…
Reference in New Issue
Block a user