diff --git a/YACReaderLibrary/comic_vine/model/volumes_model.cpp b/YACReaderLibrary/comic_vine/model/volumes_model.cpp index ca47938f..90309041 100644 --- a/YACReaderLibrary/comic_vine/model/volumes_model.cpp +++ b/YACReaderLibrary/comic_vine/model/volumes_model.cpp @@ -38,8 +38,9 @@ void VolumesModel::load(const QString &json) QString publisher = resultsValue.property("publisher").property("name").toString(); QString url = resultsValue.property("image").property("medium_url").toString(); QString deck = resultsValue.property("deck").toString(); + QString id = resultsValue.property("id").toString(); QStringList & l = *(new QStringList); - l << name << year << numIssues << publisher << url << deck; + l << name << year << numIssues << publisher << url << deck << id; test = name.isEmpty() && year.isEmpty() && numIssues.isEmpty() && url.isEmpty(); if(numResults>0 && !test) _data.push_back(&l); diff --git a/YACReaderLibrary/comic_vine/model/volumes_model.h b/YACReaderLibrary/comic_vine/model/volumes_model.h index 5cb19320..98fa3e70 100644 --- a/YACReaderLibrary/comic_vine/model/volumes_model.h +++ b/YACReaderLibrary/comic_vine/model/volumes_model.h @@ -36,7 +36,8 @@ public: ISSUES, PUBLISHER, COVER_URL, - DECK + DECK, + ID }; }; diff --git a/YACReaderLibrary/comic_vine/select_volume.cpp b/YACReaderLibrary/comic_vine/select_volume.cpp index 3476a892..d5abb9c2 100644 --- a/YACReaderLibrary/comic_vine/select_volume.cpp +++ b/YACReaderLibrary/comic_vine/select_volume.cpp @@ -137,6 +137,7 @@ void SelectVolume::loadVolumeInfo(const QModelIndex & mi) QStringList * data = static_cast(mi.internalPointer()); QString coverURL = data->at(VolumesModel::COVER_URL); QString deck = data->at(VolumesModel::DECK); + QString id = data->at(VolumesModel::ID); //cover->setText(coverURL); detailLabel->setText(deck); @@ -146,6 +147,7 @@ void SelectVolume::loadVolumeInfo(const QModelIndex & mi) connect(search,SIGNAL(timeout()),this,SLOT(queryTimeOut())); //TODO connect(search,SIGNAL(finished()),search,SLOT(deleteLater())); search->get(); + } void SelectVolume::setCover(const QByteArray & data) @@ -162,3 +164,9 @@ void SelectVolume::setCover(const QByteArray & data) cover->update(); } + +void SelectVolume::setDescription(const QString &description) +{ + +} + diff --git a/YACReaderLibrary/comic_vine/select_volume.h b/YACReaderLibrary/comic_vine/select_volume.h index 585fcbfa..f6ec7733 100644 --- a/YACReaderLibrary/comic_vine/select_volume.h +++ b/YACReaderLibrary/comic_vine/select_volume.h @@ -18,6 +18,7 @@ public: public slots: void loadVolumeInfo(const QModelIndex & mi); void setCover(const QByteArray &); + void setDescription(const QString & description); private: QLabel * cover; QLabel * detailLabel;