-
-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathcloudlogmanager.h
87 lines (77 loc) · 2.13 KB
/
cloudlogmanager.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
#ifndef CLOUDLOGMANAGER_H
#define CLOUDLOGMANAGER_H
#include <QNetworkAccessManager>
#include <QNetworkReply>
#include <QSqlQuery>
#include <iostream>
#include <QJsonDocument>
#include <QJsonObject>
#include <QDomDocument>
#include <QRegularExpression>
#include <QSqlError>
#include "qsomodel.h"
#include "adiftools.h"
class cloudlogManager : public QObject
{
Q_OBJECT
public:
cloudlogManager(qsoModel *model);
private slots:
void callbackCloudLog(QNetworkReply *rep);
public slots:
void uploadToCloudLog(QString ssl, QString url, QString key, QString station_id);
void resetMarkedQSOs();
void deleteUploadedQsos();
void deleteQsos();
void testApiKey(QString ssl, QString url, QString key);
signals:
void uploadSucessfull(double progress);
void uploadFailed(const QString &error);
void apiKeyOk();
void apiKeyRo();
void apiKeyInvalid();
private:
adifTools adif;
QNetworkAccessManager *manager;
QSqlQuery selectQuery;
QString url;
QString key;
QString station_id;
QString ssl;
qsoModel *model;
int number;
int done;
QString currentIdInUpload;
void uploadQSO(QString url,
QString ssl,
QString key,
QString station_id,
QString call,
QString name,
QString mode,
QString freq,
QString date,
QString time,
QString recv,
QString sent,
QString ctry,
QString grid,
QString qqth,
QString comm,
QString ctss,
QString ctsr,
QString sota,
QString sots,
QString wwff,
QString wwfs,
QString pota,
QString pots,
QString satn,
QString satm,
QString propmode,
QString rxfreq,
QString loca
);
void uploadNext();
};
#endif // CLOUDLOGMANAGER_H