Wallet: Distingush amounts for a single subaddress

Adding a new `amounts` field ot the output of `get_transfers` RPC
method. This field specifies individual payments made to a single
subaddress in a single transaction, e.g., made by this command:

    transfer <addr1> <amount1> <addr1> <amount2>
This commit is contained in:
Tadeas Moravec 2020-01-09 10:01:56 +01:00 committed by Tadeas Moravec
parent 3c01bffd0c
commit 096a9dbdf9
No known key found for this signature in database
GPG key ID: AE1066CC94FA7B49
4 changed files with 38 additions and 2 deletions

View file

@ -1354,6 +1354,7 @@ namespace wallet_rpc
typedef epee::misc_utils::struct_init<response_t> response;
};
typedef std::vector<uint64_t> amounts_container;
struct transfer_entry
{
std::string txid;
@ -1361,6 +1362,7 @@ namespace wallet_rpc
uint64_t height;
uint64_t timestamp;
uint64_t amount;
amounts_container amounts;
uint64_t fee;
std::string note;
std::list<transfer_destination> destinations;
@ -1380,6 +1382,7 @@ namespace wallet_rpc
KV_SERIALIZE(height);
KV_SERIALIZE(timestamp);
KV_SERIALIZE(amount);
KV_SERIALIZE(amounts);
KV_SERIALIZE(fee);
KV_SERIALIZE(note);
KV_SERIALIZE(destinations);