From 90107e670e4fb7415ce3629dc672ea0325b181f3 Mon Sep 17 00:00:00 2001 From: APTX Date: Tue, 24 Jul 2012 01:28:22 +0200 Subject: [PATCH] Import the new data from MyList exports --- localmylist/mylistexportparsetask.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) 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(); -- 2.52.0