Files
2026-07-12 14:34:52 +04:00

36 lines
777 B
C++

#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