|
|
@ -374,6 +374,10 @@ void RPC::validateAddress(QString address, const std::function<void(QJsonValue)> |
|
|
|
conn->doRPCWithDefaultErrorHandling(makePayload(method, address), cb); |
|
|
|
} |
|
|
|
|
|
|
|
void RPC::getBlock(QString height, const std::function<void(QJsonValue)>& cb) { |
|
|
|
conn->doRPCWithDefaultErrorHandling(makePayload(height), cb); |
|
|
|
} |
|
|
|
|
|
|
|
void RPC::getBalance(const std::function<void(QJsonValue)>& cb) { |
|
|
|
QJsonObject payload = { |
|
|
|
{"jsonrpc", "1.0"}, |
|
|
@ -396,8 +400,14 @@ void RPC::listBanned(const std::function<void(QJsonValue)>& cb) { |
|
|
|
} |
|
|
|
|
|
|
|
void RPC::getTransactions(const std::function<void(QJsonValue)>& cb) { |
|
|
|
QString method = "listtransactions"; |
|
|
|
conn->doRPCWithDefaultErrorHandling(makePayload(method), cb); |
|
|
|
QJsonObject payload = { |
|
|
|
{"jsonrpc", "1.0"}, |
|
|
|
{"id", "42"}, |
|
|
|
{"method", "listtransactions"}, |
|
|
|
{"params", QJsonArray { "*", 99999 }} |
|
|
|
}; |
|
|
|
|
|
|
|
conn->doRPCWithDefaultErrorHandling(payload, cb); |
|
|
|
} |
|
|
|
|
|
|
|
void RPC::mergeToAddress(QJsonArray ¶ms, const std::function<void(QJsonValue)>& cb, |
|
|
|