Sort the list of columns for a table by attnum (creation order).

This commit is contained in:
eelke 2018-12-16 12:49:44 +01:00
parent 2aef965787
commit 2f527a8380

View file

@ -28,6 +28,7 @@ ColumnPage::ColumnPage(QWidget *parent)
m_tableView->setModel(m_sortFilterProxy); m_tableView->setModel(m_sortFilterProxy);
m_tableView->setSortingEnabled(true); m_tableView->setSortingEnabled(true);
m_tableView->setSelectionBehavior(QAbstractItemView::SelectRows); m_tableView->setSelectionBehavior(QAbstractItemView::SelectRows);
m_sortFilterProxy->sort(ColumnTableModel::AttnumCol, Qt::AscendingOrder);
// With this delegate the coloring of the datatype column doesn't work.... // With this delegate the coloring of the datatype column doesn't work....
// auto item_delegate = new PgLabItemDelegate(this); // auto item_delegate = new PgLabItemDelegate(this);