From: APTX Date: Mon, 23 Jul 2012 23:28:22 +0000 (+0200) Subject: Import the new data from MyList exports X-Git-Url: https://gitweb.aptx.org/?a=commitdiff_plain;h=90107e670e4fb7415ce3629dc672ea0325b181f3;p=localmylist.git Import the new data from MyList exports --- diff --git a/localmylist/mylistexportparsetask.cpp b/localmylist/mylistexportparsetask.cpp index 6317260..daf6f70 100644 --- a/localmylist/mylistexportparsetask.cpp +++ b/localmylist/mylistexportparsetask.cpp @@ -265,6 +265,10 @@ qDebug() << "Updating Anime" << current.aid; current.endDate = a.endDate; if (!a.type.isEmpty()) current.type = a.type; + if (a.totalEpisodeCount) + current.totalEpisodeCount = a.totalEpisodeCount; + if (a.highestEpno) + current.highestEpno = a.highestEpno; }else{qDebug() << "No update required" << current.aid;} current.entryUpdate = QDateTime::currentDateTime(); @@ -317,7 +321,14 @@ void MyListExportParseTask::readEpisode() e.anidbUpdate = QDateTime::fromString(readElementText(), dateTimeFormat); } else if (name() == "EpNo") { - e.epno = readElementText().toInt(); + QString epno = readElementText(); + if (epno.length() && !epno[0].isNumber()) + { + // For some reason, the Trailer type is only in epno... + e.type = epno.left(1); + epno = epno.mid(1); + } + e.epno = epno.toInt(); } else if (name() == "EpNameRomaji") { e.titleRomaji = readElementText();