30 QList<TransactionRecord> parts;
31 int64_t nTime = wtx.
time;
34 CAmount nNet = nCredit - nDebit;
36 std::map<std::string, std::string> mapValue = wtx.
value_map;
43 for(
unsigned int i = 0; i < wtx.
tx->vout.size(); i++)
45 const CTxOut& txout = wtx.
tx->vout[i];
82 if(fAllFromMe > mine) fAllFromMe = mine;
89 if(fAllToMe > mine) fAllToMe = mine;
92 if (fAllFromMe && fAllToMe)
110 CAmount nTxFee = nDebit - wtx.
tx->GetValueOut();
112 for (
unsigned int nOut = 0; nOut < wtx.
tx->vout.size(); nOut++)
114 const CTxOut& txout = wtx.
tx->vout[nOut];
178 const bool up_to_date = ((int64_t)QDateTime::currentMSecsSinceEpoch() / 1000 - block_time <
MAX_BLOCK_TIME_GAP);
int64_t CAmount
Amount in satoshis (Can be negative)
static constexpr int64_t MAX_BLOCK_TIME_GAP
Maximum gap between node time and block time used for the "Catching up..." mode in GUI.
An output of a transaction.
UI model for a transaction.
int idx
Subtransaction index, for sort key.
static QList< TransactionRecord > decomposeTransaction(const interfaces::WalletTx &wtx)
static const int RecommendedNumConfirmations
Number of confirmation recommended for accepting a transaction.
static bool showTransaction()
Decompose CWallet transaction to model transaction records.
TransactionStatus status
Status: can change with block chain update.
int getOutputIndex() const
Return the output index of the subtransaction
QString getTxHash() const
Return the unique identifier for this transaction (part)
bool statusUpdateNeeded(const uint256 &block_hash) const
Return whether a status update is needed.
void updateStatus(const interfaces::WalletTxStatus &wtx, const uint256 &block_hash, int numBlocks, int64_t block_time)
Update status from core wallet tx.
bool involvesWatchAddress
Whether the transaction was sent/received with a watch-only address.
bool countsForBalance
Transaction counts towards available balance.
uint256 m_cur_block_hash
Current block hash (to know whether cached status is still valid)
qint64 open_for
Timestamp if status==OpenUntilDate, otherwise number of additional blocks that need to be mined befor...
@ Confirmed
Have 6 or more confirmations (normal tx) or fully mature (mined tx)
@ OpenUntilDate
Normal (sent/received) transactions.
@ Unconfirmed
Not yet mined into a block.
@ Immature
Generated (mined) transactions.
@ Confirming
Confirmed, but waiting for the recommended number of confirmations.
@ NotAccepted
Mined but not accepted.
@ OpenUntilBlock
Transaction not yet final, waiting for block.
@ Conflicted
Conflicts with other transaction or mempool.
@ Abandoned
Abandoned from the wallet.
std::string sortKey
Sorting key based on status.
std::string ToString() const
isminetype
IsMine() return codes, which depend on ScriptPubKeyMan implementation.
std::string EncodeDestination(const CTxDestination &dest)
static const unsigned int LOCKTIME_THRESHOLD
std::vector< CTxDestination > txout_address
std::vector< isminetype > txout_is_mine
std::map< std::string, std::string > value_map
std::vector< isminetype > txout_address_is_mine
std::vector< isminetype > txin_is_mine
Updated transaction status.
unsigned int time_received