You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

51 lines
889 B
C

#ifndef IGRIDFORM_H
#define IGRIDFORM_H
#include <QWidget>
#include <QString>
#include <QTableView>
#include "defaultformhandler.h"
#include "core_global.h"
namespace Ui {
class GridForm;
}
class CORESHARED_EXPORT IGridForm : public QWidget
{
Q_OBJECT
public:
explicit IGridForm(QWidget *parent = 0);
virtual ~IGridForm();
void setPluginId(const QString &pluginId);
QString pluginId();
QTableView *tableView();
signals:
void dataChanged();
public slots:
virtual void fillData() = 0;
protected:
virtual void handleNewRecord() = 0;
virtual void handleEditRecord() = 0;
virtual void handleDeleteRecord() = 0;
private slots:
void on_btnNew_clicked();
void on_btnEdit_clicked();
void on_btnDelete_clicked();
private:
QString m_pluginId;
IFormHandler *m_formHandler;
Ui::GridForm *ui;
};
#endif // IGRIDFORM_H