mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-14 12:43:40 +02:00
update model
This commit is contained in:
parent
94ccfa8c5d
commit
de11d82856
2 changed files with 18 additions and 8 deletions
|
|
@ -12,7 +12,7 @@ static Qt::AlignmentFlag column_alignments[] = {
|
|||
TransactionTableModel::TransactionTableModel(QObject *parent):
|
||||
QAbstractTableModel(parent)
|
||||
{
|
||||
columns << "Status" << "Date" << "Description" << "Debit" << "Credit";
|
||||
columns << tr("Status") << tr("Date") << tr("Description") << tr("Debit") << tr("Credit");
|
||||
}
|
||||
|
||||
int TransactionTableModel::rowCount(const QModelIndex &parent) const
|
||||
|
|
@ -41,6 +41,11 @@ QVariant TransactionTableModel::data(const QModelIndex &index, int role) const
|
|||
{
|
||||
return column_alignments[index.column()];
|
||||
}
|
||||
/* user role: transaction type
|
||||
"s" (sent)
|
||||
"r" (received)
|
||||
"g" (generated)
|
||||
*/
|
||||
return QVariant();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue