Double clicking a table now opens a CRUD page for that table however data cannot be changed yet thought it will display an editbox.

This commit is contained in:
eelke 2018-01-09 20:39:43 +01:00
parent abd4020ddf
commit 2ba27178a2
13 changed files with 288 additions and 33 deletions

View file

@ -15,18 +15,20 @@ class ConstraintModel;
class PgDatabaseCatalog;
class NamespaceFilterWidget;
class IndexModel;
class MainWindow;
class TablesPage : public QWidget
{
Q_OBJECT
public:
explicit TablesPage(QWidget *parent = 0);
explicit TablesPage(MainWindow *parent = 0);
~TablesPage();
void setCatalog(std::shared_ptr<PgDatabaseCatalog> cat);
private:
Ui::TablesPage *ui;
MainWindow *m_window;
std::shared_ptr<PgDatabaseCatalog> m_catalog;
TablesTableModel* m_tablesModel = nullptr;
ColumnTableModel* m_columnsModel = nullptr;
@ -39,6 +41,7 @@ private slots:
void tableListTable_currentRowChanged(const QModelIndex &current, const QModelIndex &previous);
void constraintsTable_currentRowChanged(const QModelIndex &current, const QModelIndex &previous);
void constraintsTable_selectionChanged(const QItemSelection &selected, const QItemSelection &deselected);
void on_tableListTable_doubleClicked(const QModelIndex &index);
};
#endif // TABLESPAGE_H