mirror of
https://github.com/monero-project/monero.git
synced 2024-10-01 11:49:47 -04:00
rpc: add received_timestamp for pool txes in gettransactions
This commit is contained in:
parent
fe3f6a3e6b
commit
d7cf872767
@ -953,18 +953,21 @@ namespace cryptonote
|
|||||||
{
|
{
|
||||||
e.double_spend_seen = it->second.double_spend_seen;
|
e.double_spend_seen = it->second.double_spend_seen;
|
||||||
e.relayed = it->second.relayed;
|
e.relayed = it->second.relayed;
|
||||||
|
e.received_timestamp = it->second.receive_time;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
MERROR("Failed to determine pool info for " << tx_hash);
|
MERROR("Failed to determine pool info for " << tx_hash);
|
||||||
e.double_spend_seen = false;
|
e.double_spend_seen = false;
|
||||||
e.relayed = false;
|
e.relayed = false;
|
||||||
|
e.received_timestamp = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
e.block_height = m_core.get_blockchain_storage().get_db().get_tx_block_height(tx_hash);
|
e.block_height = m_core.get_blockchain_storage().get_db().get_tx_block_height(tx_hash);
|
||||||
e.block_timestamp = m_core.get_blockchain_storage().get_db().get_block_timestamp(e.block_height);
|
e.block_timestamp = m_core.get_blockchain_storage().get_db().get_block_timestamp(e.block_height);
|
||||||
|
e.received_timestamp = 0;
|
||||||
e.double_spend_seen = false;
|
e.double_spend_seen = false;
|
||||||
e.relayed = false;
|
e.relayed = false;
|
||||||
}
|
}
|
||||||
|
@ -88,7 +88,7 @@ namespace cryptonote
|
|||||||
// advance which version they will stop working with
|
// advance which version they will stop working with
|
||||||
// Don't go over 32767 for any of these
|
// Don't go over 32767 for any of these
|
||||||
#define CORE_RPC_VERSION_MAJOR 3
|
#define CORE_RPC_VERSION_MAJOR 3
|
||||||
#define CORE_RPC_VERSION_MINOR 0
|
#define CORE_RPC_VERSION_MINOR 1
|
||||||
#define MAKE_CORE_RPC_VERSION(major,minor) (((major)<<16)|(minor))
|
#define MAKE_CORE_RPC_VERSION(major,minor) (((major)<<16)|(minor))
|
||||||
#define CORE_RPC_VERSION MAKE_CORE_RPC_VERSION(CORE_RPC_VERSION_MAJOR, CORE_RPC_VERSION_MINOR)
|
#define CORE_RPC_VERSION MAKE_CORE_RPC_VERSION(CORE_RPC_VERSION_MAJOR, CORE_RPC_VERSION_MINOR)
|
||||||
|
|
||||||
@ -351,6 +351,7 @@ namespace cryptonote
|
|||||||
bool double_spend_seen;
|
bool double_spend_seen;
|
||||||
uint64_t block_height;
|
uint64_t block_height;
|
||||||
uint64_t block_timestamp;
|
uint64_t block_timestamp;
|
||||||
|
uint64_t received_timestamp;
|
||||||
std::vector<uint64_t> output_indices;
|
std::vector<uint64_t> output_indices;
|
||||||
bool relayed;
|
bool relayed;
|
||||||
|
|
||||||
@ -372,6 +373,7 @@ namespace cryptonote
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
KV_SERIALIZE(relayed)
|
KV_SERIALIZE(relayed)
|
||||||
|
KV_SERIALIZE(received_timestamp)
|
||||||
}
|
}
|
||||||
END_KV_SERIALIZE_MAP()
|
END_KV_SERIALIZE_MAP()
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user