MCPcopy Create free account
hub / github.com/BTCGPU/BTCGPU / AcentryToJSON

Function AcentryToJSON

src/wallet/rpcwallet.cpp:1883–1898  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1881}
1882
1883static void AcentryToJSON(const CAccountingEntry& acentry, const std::string& strAccount, UniValue& ret)
1884{
1885 bool fAllAccounts = (strAccount == std::string("*"));
1886
1887 if (fAllAccounts || acentry.strAccount == strAccount)
1888 {
1889 UniValue entry(UniValue::VOBJ);
1890 entry.pushKV("account", acentry.strAccount);
1891 entry.pushKV("category", "move");
1892 entry.pushKV("time", acentry.nTime);
1893 entry.pushKV("amount", ValueFromAmount(acentry.nCreditDebit));
1894 if (IsDeprecatedRPCEnabled("accounts")) entry.pushKV("otheraccount", acentry.strOtherAccount);
1895 entry.pushKV("comment", acentry.strComment);
1896 ret.push_back(entry);
1897 }
1898}
1899
1900UniValue listtransactions(const JSONRPCRequest& request)
1901{

Callers 1

listtransactionsFunction · 0.85

Calls 4

ValueFromAmountFunction · 0.85
IsDeprecatedRPCEnabledFunction · 0.85
pushKVMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected