blob: 25212c976efeba2356210abe86d014083da81cc5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
#ifndef TRANSACTIONVIEW_H
#define TRANSACTIONVIEW_H
#include <QWidget>
class TransactionTableModel;
class TransactionFilterProxy;
QT_BEGIN_NAMESPACE
class QTableView;
class QComboBox;
class QLineEdit;
class QModelIndex;
QT_END_NAMESPACE
class TransactionView : public QWidget
{
Q_OBJECT
public:
explicit TransactionView(QWidget *parent = 0);
void setModel(TransactionTableModel *model);
enum DateEnum
{
All,
Today,
ThisWeek,
ThisMonth,
LastMonth,
ThisYear,
Range
};
private:
TransactionTableModel *model;
TransactionFilterProxy *transactionProxyModel;
QTableView *transactionView;
QComboBox *dateWidget;
QComboBox *typeWidget;
QLineEdit *addressWidget;
QLineEdit *amountWidget;
signals:
void doubleClicked(const QModelIndex&);
public slots:
void chooseDate(int idx);
void chooseType(int idx);
void changedPrefix(const QString &prefix);
void changedAmount(const QString &amount);
void exportClicked();
};
#endif // TRANSACTIONVIEW_H
|