Initial commit
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
#ifndef REFUNDS_MODEL_H
|
||||
#define REFUNDS_MODEL_H
|
||||
|
||||
#include "base_sql_table_model.h"
|
||||
|
||||
class RefundsModel : public BaseSqlTableModel {
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
enum RefundsColumns { Id, TicketId, RefundAt, RefundAmount };
|
||||
|
||||
public:
|
||||
explicit RefundsModel(QObject *parent, const QSqlDatabase &database);
|
||||
|
||||
// Initialize the model
|
||||
void initialize();
|
||||
|
||||
// Overlooking class BaseSqlTableModel methods
|
||||
|
||||
QVariant headerData(int section, Qt::Orientation orientation,
|
||||
int role = Qt::DisplayRole) const override;
|
||||
|
||||
inline bool isCompleteDatabaseFiltering() const final {
|
||||
#ifdef NO_DATE_TIME_SEARCH
|
||||
return false;
|
||||
#else
|
||||
return true;
|
||||
#endif
|
||||
};
|
||||
|
||||
protected:
|
||||
QString createMultiColumnFilter(const QString &filter) const final;
|
||||
};
|
||||
|
||||
#endif // REFUNDS_MODEL_H
|
||||
Reference in New Issue
Block a user