Subversion Repositories OpenInventory

Rev

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

Rev 201 Rev 202
Line 565... Line 565...
565
QMap <int, QString> pointersToModel;
565
QMap <int, QString> pointersToModel;
566
566
567
567
568
568
569
569
570
-
 
-
 
570
QMap <int, QString> filesFieldsToModel;
571
for (int i=0; i < fileFieldList.count(); i++){ // äëÿ âñåõ ïîëåé, õðàíÿùèõ ôàéëû
571
for (int i=0; i < fileFieldList.count(); i++){ // äëÿ âñåõ ïîëåé, õðàíÿùèõ ôàéëû
572
  //  static FileDelegate flDelegate;
572
  //  static FileDelegate flDelegate;
573
   // static TimeEditDelegate dateDelegate("01.10.2010");
573
   // static TimeEditDelegate dateDelegate("01.10.2010");
574
    QString fileFieldName; // èìÿ ïîëÿ
574
    QString fileFieldName; // èìÿ ïîëÿ
575
    int fileFieldIndex; //
575
    int fileFieldIndex; //
576
    fileFieldName = fileFieldList.at(i); // îïðåäåëÿåì èìÿ ïîëÿ, õðàíÿùåãî ôàéë
576
    fileFieldName = fileFieldList.at(i); // îïðåäåëÿåì èìÿ ïîëÿ, õðàíÿùåãî ôàéë
577
    fileFieldIndex = sql_mogel->record().indexOf(fileFieldName); // îïðåäåëÿåì íîìåð ñòîëáöà â ìîäåëå
577
    fileFieldIndex = sql_mogel->record().indexOf(fileFieldName); // îïðåäåëÿåì íîìåð ñòîëáöà â ìîäåëå
-
 
578
    filesFieldsToModel.insert(fileFieldIndex, fileFieldName);
578
    file_colomns_indexes.append(fileFieldIndex);// çàïîìíèì íîìåð ñòîëáöà ñ äåëåãàòîì äëÿ òèïà "àøäó"
579
    file_colomns_indexes.append(fileFieldIndex);// çàïîìíèì íîìåð ñòîëáöà ñ äåëåãàòîì äëÿ òèïà "file"
579
    ui->tableView->setItemDelegateForColumn(fileFieldIndex, fileDelegate);
580
    ui->tableView->setItemDelegateForColumn(fileFieldIndex, fileDelegate);
580
581
581
}
582
}
582
-
 
-
 
583
sql_mogel->setFilesFields(filesFieldsToModel);// ïåðåäàåì ìîäåëè ñâÿçàííûé ñïèñîê ñ íîìåðàìè è èìåíàìè ñòîëáöîâ, õðàíÿùèõ ôàéëû
583
584
584
585
585
586
586
587
587
for (int i=0; i < dateFieldList.count(); i++){ // äëÿ âñåõ ïîëåé ñ òèïîì "DATA"
588
for (int i=0; i < dateFieldList.count(); i++){ // äëÿ âñåõ ïîëåé ñ òèïîì "DATA"