Account Table form

This commit is contained in:
Krad
2021-12-08 15:10:56 +08:00
parent f00501f680
commit a65d293fb2
5 changed files with 117 additions and 2 deletions

View File

@@ -0,0 +1,23 @@
//
// Created by Krad on 2021/12/8.
//
#ifndef GUI_ACCOUNTROLECOMBODELEGATE_H
#define GUI_ACCOUNTROLECOMBODELEGATE_H
#include <QAbstractItemModel>
#include <QItemDelegate>
class AccountRoleComboDelegate:public QItemDelegate {
Q_OBJECT
public:
explicit AccountRoleComboDelegate(QWidget *parent = nullptr);
void paint(QPainter *painter,
const QStyleOptionViewItem &option,
const QModelIndex &index) const override;
private:
QAbstractItemModel* model = nullptr;
QMap<QString,QVariant> map ;
};
#endif //GUI_ACCOUNTROLECOMBODELEGATE_H