Changeset View
Changeset View
Standalone View
Standalone View
src/calendar/freebusyqueryjob.cpp
Show First 20 Lines • Show All 87 Lines • ▼ Show 20 Line(s) | 87 | { QStringLiteral("items"), | |||
---|---|---|---|---|---|
88 | QVariantList({ | 88 | QVariantList({ | ||
89 | QVariantMap({ { QStringLiteral("id"), d->id } }) | 89 | QVariantMap({ { QStringLiteral("id"), d->id } }) | ||
90 | }) | 90 | }) | ||
91 | }}); | 91 | }}); | ||
92 | QJsonDocument document = QJsonDocument::fromVariant(requestData); | 92 | QJsonDocument document = QJsonDocument::fromVariant(requestData); | ||
93 | const QByteArray json = document.toJson(QJsonDocument::Compact); | 93 | const QByteArray json = document.toJson(QJsonDocument::Compact); | ||
94 | 94 | | |||
95 | QNetworkRequest request(CalendarService::freeBusyQueryUrl()); | 95 | QNetworkRequest request(CalendarService::freeBusyQueryUrl()); | ||
96 | request.setRawHeader("Authorization", "Bearer " + account()->accessToken().toLatin1()); | | |||
97 | request.setRawHeader("GData-Version", CalendarService::APIVersion().toLatin1()); | 96 | request.setRawHeader("GData-Version", CalendarService::APIVersion().toLatin1()); | ||
98 | enqueueRequest(request, json, QStringLiteral("application/json")); | 97 | enqueueRequest(request, json, QStringLiteral("application/json")); | ||
99 | } | 98 | } | ||
100 | 99 | | |||
101 | void FreeBusyQueryJob::dispatchRequest(QNetworkAccessManager *accessManager, | 100 | void FreeBusyQueryJob::dispatchRequest(QNetworkAccessManager *accessManager, | ||
102 | const QNetworkRequest &request, | 101 | const QNetworkRequest &request, | ||
103 | const QByteArray &data, | 102 | const QByteArray &data, | ||
104 | const QString &contentType) | 103 | const QString &contentType) | ||
Show All 38 Lines |