forked from jeena/FeedTheMonkey
added post stuff
This commit is contained in:
parent
7dbf05e2e1
commit
6146758f59
4 changed files with 29 additions and 17 deletions
|
@ -39,10 +39,9 @@ void TinyTinyRSSLogin::reply()
|
|||
|
||||
if (reply) {
|
||||
if (reply->error() == QNetworkReply::NoError) {
|
||||
QJsonDocument jdoc = QJsonDocument::fromBinaryData(reply->readAll());
|
||||
qDebug() << jdoc;
|
||||
//mSessionId = json.toVariant().toMap().value("session_id").toString();
|
||||
//qDebug() << "sessionId: " << mSessionId;
|
||||
QString jsonString = QString(reply->readAll());
|
||||
QJsonDocument json = QJsonDocument::fromJson(jsonString.toUtf8());
|
||||
mSessionId = json.object().value("content").toObject().value("session_id").toString();
|
||||
emit sessionIdChanged(mSessionId);
|
||||
} else {
|
||||
int httpStatus = reply->attribute(QNetworkRequest::HttpStatusCodeAttribute).toInt();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue