- Timestamp:
- 04/15/10 14:01:48 (13 years ago)
- Branches:
- master, qt5
- Children:
- f5b68a4
- Parents:
- be9b645
- Location:
- src/mvc
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/mvc/conference.cpp
rbe9b645 rd06ae27 30 30 << QSqlField("day_change", QVariant::Int) 31 31 << QSqlField("timeslot_duration", QVariant::Int) 32 << QSqlField("active", QVariant::Bool)); 32 << QSqlField("active", QVariant::Bool) 33 << QSqlField("url", QVariant::String)); 33 34 34 35 QString const Conference::sTableName = QString("conference"); … … 58 59 activeConfs.append(query.record().value("id").toInt()); 59 60 61 qDebug() << __PRETTY_FUNCTION__ 62 << "activeConfs.count()" << activeConfs.count() 63 ; 64 60 65 if(activeConfs.count()==0) // no active DB 61 66 return 1; -
src/mvc/conference.h
rbe9b645 rd06ae27 49 49 int timeslotDuration() const { return value("timeslot_duration").toInt(); } // in seconds 50 50 bool isActive() const { return value("active").toBool(); } 51 QString getUrl() const 52 { 53 QVariant val = value("url"); 54 qDebug() << __PRETTY_FUNCTION__ << val; 55 if (val.isValid()) { 56 return val.toString(); 57 } else { 58 return QString(); 59 } 60 } 51 61 52 62 void setId(int id) { setValue("id", id); } … … 61 71 void setTimeslotDuration(int timeslotDuration) { setValue("timeslot_duration", timeslotDuration); } 62 72 void setActive(bool active) { setValue("active", (int)((active))); } 73 void setUrl(const QString& url) { setValue("url", url.isNull() ? QVariant() : url); } 63 74 }; 64 75
Note: See TracChangeset
for help on using the changeset viewer.