mirror of
https://git.wownero.com/wownero/onion-wownero-blockchain-explorer.git
synced 2024-08-15 00:33:12 +00:00
indicate presence of sub-address in multi-output txs
This commit is contained in:
parent
b9e9c60267
commit
ad15b5c703
2 changed files with 20 additions and 2 deletions
|
@ -181,7 +181,13 @@ MempoolStatus::read_mempool()
|
|||
last_tx.pID = 'l'; // legacy payment id
|
||||
else if (payment_id8 != null_hash8)
|
||||
last_tx.pID = 'e'; // encrypted payment id
|
||||
|
||||
else if (!get_additional_tx_pub_keys_from_extra(tx).empty())
|
||||
{
|
||||
// if multioutput tx have additional public keys,
|
||||
// mark it so that it represents that it has at least
|
||||
// one sub-address
|
||||
last_tx.pID = 's';
|
||||
}
|
||||
// } // if (hex_to_pod(_tx_info.id_hash, mem_tx_hash))
|
||||
|
||||
} // for (size_t i = 0; i < mempool_tx_info.size(); ++i)
|
||||
|
|
14
src/page.h
14
src/page.h
|
@ -144,9 +144,13 @@ namespace xmreg
|
|||
uint64_t size;
|
||||
uint64_t blk_height;
|
||||
size_t version;
|
||||
|
||||
bool has_additional_tx_pub_keys {false};
|
||||
|
||||
char pID; // '-' - no payment ID,
|
||||
// 'l' - legacy, long 64 character payment id,
|
||||
// 'e' - encrypted, short, from integrated addresses
|
||||
// 's' - sub-address (avaliable only for multi-output txs)
|
||||
uint64_t unlock_time;
|
||||
uint64_t no_confirmations;
|
||||
vector<uint8_t> extra;
|
||||
|
@ -208,7 +212,8 @@ namespace xmreg
|
|||
{"payment_id8" , pod_to_hex(payment_id8)},
|
||||
{"unlock_time" , unlock_time},
|
||||
{"tx_size" , fmt::format("{:0.4f}", tx_size)},
|
||||
{"tx_size_short" , fmt::format("{:0.2f}", tx_size)}
|
||||
{"tx_size_short" , fmt::format("{:0.2f}", tx_size)},
|
||||
{"has_add_pks" , !additional_pks.empty()}
|
||||
};
|
||||
|
||||
|
||||
|
@ -6007,6 +6012,13 @@ namespace xmreg
|
|||
{
|
||||
txd.pID = 'e'; // encrypted payment id
|
||||
}
|
||||
else if (txd.additional_pks.empty() == false)
|
||||
{
|
||||
// if multioutput tx have additional public keys,
|
||||
// mark it so that it represents that it has at least
|
||||
// one sub-address
|
||||
txd.pID = 's';
|
||||
}
|
||||
|
||||
// get tx signatures for each input
|
||||
txd.signatures = tx.signatures;
|
||||
|
|
Loading…
Reference in a new issue