Subversion Repositories OpenInventory

Rev

Rev 158 | Rev 179 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 158 Rev 159
Line 24... Line 24...
24
*************************************************/
24
*************************************************/
25
25
26
 if (bolleans_list.indexOf(index.column()) != -1)
26
 if (bolleans_list.indexOf(index.column()) != -1)
27
{
27
{
28
     flags |= Qt::ItemIsUserCheckable;         // åñëè â ñòîëáöå òèï "BOOL", äåëàåì åãî âèáèðàåìûì
28
     flags |= Qt::ItemIsUserCheckable;         // åñëè â ñòîëáöå òèï "BOOL", äåëàåì åãî âèáèðàåìûì
-
 
29
     //flags |= Qt::ItemIsEnabled;
29
     flags &= ~Qt::ItemIsEditable;
30
     flags &= ~Qt::ItemIsEditable;
30
 }
31
 }
31
32
32
 return flags; // òåêóùèé ñòîëáåö
33
 return flags; // òåêóùèé ñòîëáåö
33
34
Line 79... Line 80...
79

80

80
*/
81
*/
81
82
82
83
83
        lResult = QSqlTableModel::setData(index, value, Qt::EditRole);
84
        lResult = QSqlTableModel::setData(index, value, Qt::EditRole);
-
 
85
-
 
86
// Qt::CheckState state = (value.toInt() == 2) ? Qt::Checked : Qt::Unchecked;
-
 
87
   //     lResult = QSqlTableModel::setData(index, value.toBool(), Qt::CheckStateRole);
-
 
88
-
 
89
        //  QSqlTableModel::setItemData(index,Qt::CheckStateRole);
-
 
90
   //     lResult = QSqlTableModel::setData(index, value, role);
-
 
91
84
//        emit MyModel::dataChanged(index, index);
92
      //  emit MyModel::dataChanged(index, index);
85
93
86
       //     MyModel::reset();
94
         //   MyModel::updateRowInTable();
87
     //  lResult = QSqlTableModel::setData(index, value, Qt::DisplayRole);
95
     //  lResult = QSqlTableModel::setData(index, value, Qt::DisplayRole);
88
       //  QSqlTableModel::setData(index, value, Qt::CheckStateRole);
96
       //  QSqlTableModel::setData(index, value, Qt::CheckStateRole);
89
       MyModel::submitAll();
97
       MyModel::submitAll();
90
  ////// //     MyModel::select();
98
  ////// //     MyModel::select();
91
       // MyModel::data(index, Qt::DisplayRole);
99
       // MyModel::data(index, Qt::DisplayRole);