Basic support for update in Crud implementation, error reporting and transfering data to modified set is still missing.

This commit is contained in:
eelke 2018-02-05 21:42:54 +01:00
parent 3fb32f1200
commit d626c19e14
15 changed files with 530 additions and 83 deletions

View file

@ -21,6 +21,10 @@ CrudTab::CrudTab(MainWindow *parent)
m_crudModel = new CrudModel(parent);
ui->tableView->setModel(m_crudModel);
ui->tableView->setSelectionMode(QAbstractItemView::SingleSelection);
//auto selection_model = ui->tableView->selectionModel();
// connect(ui->tableView->selectionModel(), &QItemSelectionModel::currentRowChanged, this,
// &CrudTab::tableView_currentRowChanged);
}
CrudTab::~CrudTab()
@ -41,3 +45,8 @@ void CrudTab::setConfig(std::shared_ptr<OpenDatabase> db, const PgClass &table)
// highlighter->setTypes(*cat->types());
m_crudModel->setConfig(db, table);
}
//void CrudTab::tableView_currentRowChanged(const QModelIndex &current, const QModelIndex &previous)
//{
//}