Changeset 5293ef0 in confclerk_git


Ignore:
Timestamp:
09/25/12 20:31:03 (10 years ago)
Author:
gregor herrmann <gregoa@…>
Branches:
master, qt5
Children:
4403ab4
Parents:
14c46c7
Message:

Remove unsed (and removed from db) 'days' column fro xml parser and all sql parts.

Location:
src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • src/mvc/conference.cpp

    r14c46c7 r5293ef0  
    2929    << QSqlField("start", QVariant::DateTime)
    3030    << QSqlField("end", QVariant::DateTime)
    31     << QSqlField("days", QVariant::Int)
    3231    << QSqlField("day_change", QVariant::Int)
    3332    << QSqlField("timeslot_duration", QVariant::Int)
  • src/mvc/conference.h

    r14c46c7 r5293ef0  
    4646    QDate start() const { return value("start").toDate(); }
    4747    QDate end() const { return value("end").toDate(); }
    48     int days() const { return value("days").toInt(); }
    4948    int dayChange() const { return value("day_change").toInt(); } // in seconds from 00:00
    5049    int timeslotDuration() const { return value("timeslot_duration").toInt(); } // in seconds
  • src/sql/schedulexmlparser.cpp

    r14c46c7 r5293ef0  
    6262            conference["start"] = conferenceElement.firstChildElement("start").text(); // date
    6363            conference["end"] = conferenceElement.firstChildElement("end").text(); // date
    64             conference["days"] = conferenceElement.firstChildElement("days").text(); // int
    6564            conference["day_change"] = conferenceElement.firstChildElement("day_change").text(); // time
    6665            conference["timeslot_duration"] = conferenceElement.firstChildElement("timeslot_duration").text(); // time
  • src/sql/sqlengine.cpp

    r14c46c7 r5293ef0  
    131131    if (conferenceId <= 0) // insert conference
    132132    {
    133         query.prepare("INSERT INTO CONFERENCE (title,url,subtitle,venue,city,start,end,days,"
     133        query.prepare("INSERT INTO CONFERENCE (title,url,subtitle,venue,city,start,end,"
    134134                                                "day_change,timeslot_duration,active) "
    135                         " VALUES (:title,:url,:subtitle,:venue,:city,:start,:end,:days,"
     135                        " VALUES (:title,:url,:subtitle,:venue,:city,:start,:end,"
    136136                                                ":day_change,:timeslot_duration,:active)");
    137         foreach (QString prop_name, (QList<QString>() << "title" << "url" << "subtitle" << "venue" << "city" << "days")) {
     137        foreach (QString prop_name, (QList<QString>() << "title" << "url" << "subtitle" << "venue" << "city")) {
    138138            query.bindValue(QString(":") + prop_name, aConference[prop_name]);
    139139        }
     
    148148    else // update conference
    149149    {
    150         query.prepare("UPDATE CONFERENCE set title=:title, url=:url, subtitle=:subtitle, venue=:venue, city=:city, start=:start, end=:end, days=:days,"
     150        query.prepare("UPDATE CONFERENCE set title=:title, url=:url, subtitle=:subtitle, venue=:venue, city=:city, start=:start, end=:end,"
    151151                                            "day_change=:day_change, timeslot_duration=:timeslot_duration, active=:active "
    152152                      "WHERE id=:id");
    153         foreach (QString prop_name, (QList<QString>() << "title" << "url" << "subtitle" << "venue" << "city" << "days")) {
     153        foreach (QString prop_name, (QList<QString>() << "title" << "url" << "subtitle" << "venue" << "city")) {
    154154            query.bindValue(QString(":") + prop_name, aConference[prop_name]);
    155155        }
Note: See TracChangeset for help on using the changeset viewer.