Changeset 49c5ad3


Ignore:
Timestamp:
01/22/10 15:11:38 (12 years ago)
Author:
pavelpa <pavelpa@…>
Branches:
master, qt5
Children:
e7340e1
Parents:
5992909
Message:

fixed problem with storing conference ID to AppSettings?

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/gui/mainwindow.cpp

    r5992909 r49c5ad3  
    178178    ImportScheduleDialog dialog(mSqlEngine,this);
    179179    dialog.exec();
    180    
    181     if(Conference::getAll().count())
    182     {
     180
     181    QList<Conference> confs = Conference::getAll();
     182    if(!confs.count()) // no conference(s) in the DB
     183    {
     184        AppSettings::setConfId(0); // no conference in the DB
     185    }
     186    else
     187    {
     188        if(AppSettings::confId() == 0)
     189            AppSettings::setConfId(confs[0].id());
     190
    183191        // 'dayNavigator' emits signal 'dateChanged' after setting valid START:END dates
    184192        QDate aStartDate = Conference::getById(AppSettings::confId()).start();
Note: See TracChangeset for help on using the changeset viewer.