2017-12-10 14:20:45 +01:00
|
|
|
|
#ifndef TABLESPAGE_H
|
2017-12-10 08:17:07 +01:00
|
|
|
|
#define TABLESPAGE_H
|
|
|
|
|
|
|
|
|
|
|
|
#include <QWidget>
|
2017-12-10 14:20:45 +01:00
|
|
|
|
#include <memory>
|
2017-12-10 08:17:07 +01:00
|
|
|
|
|
|
|
|
|
|
namespace Ui {
|
|
|
|
|
|
class TablesPage;
|
|
|
|
|
|
}
|
|
|
|
|
|
|
2017-12-10 14:20:45 +01:00
|
|
|
|
class TablesTableModel;
|
2017-12-12 20:13:53 +01:00
|
|
|
|
class ColumnTableModel;
|
2017-12-10 14:20:45 +01:00
|
|
|
|
class PgDatabaseCatalog;
|
|
|
|
|
|
|
2017-12-10 08:17:07 +01:00
|
|
|
|
class TablesPage : public QWidget
|
|
|
|
|
|
{
|
|
|
|
|
|
Q_OBJECT
|
|
|
|
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
explicit TablesPage(QWidget *parent = 0);
|
|
|
|
|
|
~TablesPage();
|
|
|
|
|
|
|
2017-12-10 14:20:45 +01:00
|
|
|
|
void setCatalog(std::shared_ptr<PgDatabaseCatalog> cat);
|
2017-12-10 08:17:07 +01:00
|
|
|
|
private:
|
|
|
|
|
|
Ui::TablesPage *ui;
|
2017-12-10 14:20:45 +01:00
|
|
|
|
std::shared_ptr<PgDatabaseCatalog> m_catalog;
|
|
|
|
|
|
TablesTableModel* m_tablesModel = nullptr;
|
2017-12-12 20:13:53 +01:00
|
|
|
|
ColumnTableModel* m_columnsModel = nullptr;
|
|
|
|
|
|
|
|
|
|
|
|
private slots:
|
|
|
|
|
|
|
|
|
|
|
|
void on_tableListTable_currentRowChanged(const QModelIndex ¤t, const QModelIndex &previous);
|
2017-12-10 08:17:07 +01:00
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif // TABLESPAGE_H
|