 |
Bitcoin Core
22.99.0
P2P Digital Currency
|
Go to the documentation of this file.
5 #ifndef BITCOIN_QT_RECENTREQUESTSTABLEMODEL_H
6 #define BITCOIN_QT_RECENTREQUESTSTABLEMODEL_H
12 #include <QAbstractTableModel>
13 #include <QStringList>
30 unsigned int date_timet;
31 SER_WRITE(obj, date_timet = obj.date.toSecsSinceEpoch());
32 READWRITE(obj.nVersion, obj.id, date_timet, obj.recipient);
33 SER_READ(obj, obj.date = QDateTime::fromSecsSinceEpoch(date_timet));
70 int rowCount(
const QModelIndex &parent)
const override;
71 int columnCount(
const QModelIndex &parent)
const override;
72 QVariant
data(
const QModelIndex &
index,
int role)
const override;
73 bool setData(
const QModelIndex &
index,
const QVariant &value,
int role)
override;
74 QVariant
headerData(
int section, Qt::Orientation orientation,
int role)
const override;
75 QModelIndex
index(
int row,
int column,
const QModelIndex &parent = QModelIndex())
const override;
76 bool removeRows(
int row,
int count,
const QModelIndex &parent = QModelIndex())
override;
77 Qt::ItemFlags
flags(
const QModelIndex &
index)
const override;
78 void sort(
int column, Qt::SortOrder order = Qt::AscendingOrder)
override;
92 QList<RecentRequestEntry>
list;
101 #endif // BITCOIN_QT_RECENTREQUESTSTABLEMODEL_H
QList< RecentRequestEntry > list
SendCoinsRecipient recipient
Interface to Bitcoin wallet from Qt view code.
const RecentRequestEntry & entry(int row) const
int columnCount(const QModelIndex &parent) const override
SERIALIZE_METHODS(RecentRequestEntry, obj)
int rowCount(const QModelIndex &parent) const override
void updateAmountColumnTitle()
Updates the column title to "Amount (DisplayUnit)" and emits headerDataChanged() signal for table hea...
WalletModel * walletModel
bool removeRows(int row, int count, const QModelIndex &parent=QModelIndex()) override
static const int CURRENT_VERSION
RecentRequestEntryLessThan(int nColumn, Qt::SortOrder fOrder)
RecentRequestsTableModel(WalletModel *parent)
QString getAmountTitle()
Gets title for amount column including current display unit if optionsModel reference available.
Model for list of recently generated payment requests / bitcoin: URIs.
bool setData(const QModelIndex &index, const QVariant &value, int role) override
Qt::ItemFlags flags(const QModelIndex &index) const override
void addNewRequest(const SendCoinsRecipient &recipient)
int64_t nReceiveRequestsMaxId
~RecentRequestsTableModel()
QModelIndex index(int row, int column, const QModelIndex &parent=QModelIndex()) const override
bool operator()(const RecentRequestEntry &left, const RecentRequestEntry &right) const
void sort(int column, Qt::SortOrder order=Qt::AscendingOrder) override
QVariant data(const QModelIndex &index, int role) const override
#define SER_WRITE(obj, code)
#define SER_READ(obj, code)
QVariant headerData(int section, Qt::Orientation orientation, int role) const override