use user roles instead of hidden columns for model sort/filter keys
This commit is contained in:
@@ -10,11 +10,14 @@ public:
|
||||
explicit AddressTableModel(QObject *parent = 0);
|
||||
|
||||
enum {
|
||||
Label = 0, /* User specified label */
|
||||
Address = 1, /* Bitcoin address */
|
||||
Type = 2 /* Send/Receive, used for filter */
|
||||
Label = 0, /* User specified label */
|
||||
Address = 1 /* Bitcoin address */
|
||||
} ColumnIndex;
|
||||
|
||||
enum {
|
||||
TypeRole = Qt::UserRole
|
||||
} RoleIndex;
|
||||
|
||||
static const QString Send; /* Send addres */
|
||||
static const QString Receive; /* Receive address */
|
||||
|
||||
|
||||
@@ -15,10 +15,13 @@ public:
|
||||
Date = 1,
|
||||
Description = 2,
|
||||
Debit = 3,
|
||||
Credit = 4,
|
||||
Type = 5
|
||||
Credit = 4
|
||||
} ColumnIndex;
|
||||
|
||||
enum {
|
||||
TypeRole = Qt::UserRole
|
||||
} RoleIndex;
|
||||
|
||||
/* Transaction type */
|
||||
static const QString Sent;
|
||||
static const QString Received;
|
||||
|
||||
Reference in New Issue
Block a user