Subversion Repositories OpenInventory

Compare Revisions

Ignore whitespace Rev 226 → Rev 227

/trunk/DBViewer/mainwindow.cpp
87,8 → 87,8
 
/// filter_model = new MyModel();
filter_model = new QSqlTableModel();
filter_model->setEditStrategy(QSqlTableModel::OnManualSubmit);
 
 
model_is_build = true;
connect(sql_mogel, SIGNAL(dataChanged(QModelIndex,QModelIndex)), this, SLOT(on_sql_mogel_dataChanged(QModelIndex,QModelIndex)));
connect(model_for_ListModelsTable, SIGNAL(dataChanged(QModelIndex,QModelIndex)), this, SLOT(on_model_for_ListModelsTable_dataChanged(QModelIndex,QModelIndex)));
869,6 → 869,7
 
filter_model = new QSqlTableModel();
/// filter_model = new MyModel();
filter_model->setEditStrategy(QSqlTableModel::OnManualSubmit);
 
connect(filter_model, SIGNAL(dataChanged(QModelIndex,QModelIndex)), this, SLOT(on_filter_model_dataChanged(QModelIndex,QModelIndex)));
int index;
911,6 → 912,8
/// filter_model = new MyModel();
 
filter_model = new QSqlTableModel();
filter_model->setEditStrategy(QSqlTableModel::OnManualSubmit);
 
connect(filter_model, SIGNAL(dataChanged(QModelIndex,QModelIndex)), this, SLOT(on_filter_model_dataChanged(QModelIndex,QModelIndex)));
filter_model->setTable(tr("Filters"));
filter_model->setFilter(filtr_str);
939,11 → 942,16
ui->tableView_3->setItemDelegateForColumn(3, &filterConditionDelegate);
 
conditionList.clear();
conditionList <<"" << "=" << "<" << ">" ;
conditionList <<"" << "=" << "<" << ">" << "IS NULL" << "IS NOT NULL";
filterConditionDelegate_1.setItems(conditionList);
ui->tableView_3->setItemDelegateForColumn(5, &filterConditionDelegate_1);
 
 
 
 
 
 
 
ui->tableView_3->setItemDelegateForColumn(6, &filterValueDelegate);