mirror of
https://github.com/f4exb/sdrangel.git
synced 2024-11-25 09:18:54 -05:00
Web API: added Qt version in the instance summary
This commit is contained in:
parent
a459982fa7
commit
2784a026d6
@ -1050,12 +1050,16 @@ margin-bottom: 20px;
|
||||
"description" : "Summarized information about logical devices from hardware devices attached to this SDRangel instance"
|
||||
};
|
||||
defs.InstanceSummaryResponse = {
|
||||
"required" : [ "devicesetlist", "version" ],
|
||||
"required" : [ "devicesetlist", "qtVersion", "version" ],
|
||||
"properties" : {
|
||||
"version" : {
|
||||
"type" : "string",
|
||||
"description" : "Current software version"
|
||||
},
|
||||
"qtVersion" : {
|
||||
"type" : "string",
|
||||
"description" : "Qt version with which the software was compiled"
|
||||
},
|
||||
"logging" : {
|
||||
"$ref" : "#/definitions/LoggingInfo"
|
||||
},
|
||||
@ -14085,7 +14089,7 @@ except ApiException as e:
|
||||
</div>
|
||||
<div id="generator">
|
||||
<div class="content">
|
||||
Generated 2017-12-18T01:56:22.008+01:00
|
||||
Generated 2017-12-18T13:11:28.683+01:00
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -72,6 +72,7 @@ int WebAPIAdapterGUI::instanceSummary(
|
||||
{
|
||||
|
||||
*response.getVersion() = qApp->applicationVersion();
|
||||
*response.getQtVersion() = QString(QT_VERSION_STR);
|
||||
|
||||
SWGSDRangel::SWGLoggingInfo *logging = response.getLogging();
|
||||
logging->init();
|
||||
|
@ -50,6 +50,7 @@ int WebAPIAdapterSrv::instanceSummary(
|
||||
{
|
||||
|
||||
*response.getVersion() = QCoreApplication::instance()->applicationVersion();
|
||||
*response.getQtVersion() = QString(QT_VERSION_STR);
|
||||
|
||||
SWGSDRangel::SWGLoggingInfo *logging = response.getLogging();
|
||||
logging->init();
|
||||
|
@ -936,11 +936,15 @@ definitions:
|
||||
description: "Summarized information about this SDRangel instance"
|
||||
required:
|
||||
- version
|
||||
- qtVersion
|
||||
- devicesetlist
|
||||
properties:
|
||||
version:
|
||||
description: "Current software version"
|
||||
type: string
|
||||
qtVersion:
|
||||
description: "Qt version with which the software was compiled"
|
||||
type: string
|
||||
logging:
|
||||
$ref: "#/definitions/LoggingInfo"
|
||||
devicesetlist:
|
||||
|
@ -1050,12 +1050,16 @@ margin-bottom: 20px;
|
||||
"description" : "Summarized information about logical devices from hardware devices attached to this SDRangel instance"
|
||||
};
|
||||
defs.InstanceSummaryResponse = {
|
||||
"required" : [ "devicesetlist", "version" ],
|
||||
"required" : [ "devicesetlist", "qtVersion", "version" ],
|
||||
"properties" : {
|
||||
"version" : {
|
||||
"type" : "string",
|
||||
"description" : "Current software version"
|
||||
},
|
||||
"qtVersion" : {
|
||||
"type" : "string",
|
||||
"description" : "Qt version with which the software was compiled"
|
||||
},
|
||||
"logging" : {
|
||||
"$ref" : "#/definitions/LoggingInfo"
|
||||
},
|
||||
@ -14085,7 +14089,7 @@ except ApiException as e:
|
||||
</div>
|
||||
<div id="generator">
|
||||
<div class="content">
|
||||
Generated 2017-12-18T01:56:22.008+01:00
|
||||
Generated 2017-12-18T13:11:28.683+01:00
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -38,6 +38,7 @@ SWGInstanceSummaryResponse::~SWGInstanceSummaryResponse() {
|
||||
void
|
||||
SWGInstanceSummaryResponse::init() {
|
||||
version = new QString("");
|
||||
qt_version = new QString("");
|
||||
logging = new SWGLoggingInfo();
|
||||
devicesetlist = new SWGDeviceSetList();
|
||||
}
|
||||
@ -49,6 +50,10 @@ SWGInstanceSummaryResponse::cleanup() {
|
||||
delete version;
|
||||
}
|
||||
|
||||
if(qt_version != nullptr) {
|
||||
delete qt_version;
|
||||
}
|
||||
|
||||
if(logging != nullptr) {
|
||||
delete logging;
|
||||
}
|
||||
@ -70,6 +75,7 @@ SWGInstanceSummaryResponse::fromJson(QString &json) {
|
||||
void
|
||||
SWGInstanceSummaryResponse::fromJsonObject(QJsonObject &pJson) {
|
||||
::SWGSDRangel::setValue(&version, pJson["version"], "QString", "QString");
|
||||
::SWGSDRangel::setValue(&qt_version, pJson["qtVersion"], "QString", "QString");
|
||||
::SWGSDRangel::setValue(&logging, pJson["logging"], "SWGLoggingInfo", "SWGLoggingInfo");
|
||||
::SWGSDRangel::setValue(&devicesetlist, pJson["devicesetlist"], "SWGDeviceSetList", "SWGDeviceSetList");
|
||||
}
|
||||
@ -90,6 +96,8 @@ SWGInstanceSummaryResponse::asJsonObject() {
|
||||
|
||||
toJsonValue(QString("version"), version, obj, QString("QString"));
|
||||
|
||||
toJsonValue(QString("qtVersion"), qt_version, obj, QString("QString"));
|
||||
|
||||
toJsonValue(QString("logging"), logging, obj, QString("SWGLoggingInfo"));
|
||||
|
||||
toJsonValue(QString("devicesetlist"), devicesetlist, obj, QString("SWGDeviceSetList"));
|
||||
@ -106,6 +114,15 @@ SWGInstanceSummaryResponse::setVersion(QString* version) {
|
||||
this->version = version;
|
||||
}
|
||||
|
||||
QString*
|
||||
SWGInstanceSummaryResponse::getQtVersion() {
|
||||
return qt_version;
|
||||
}
|
||||
void
|
||||
SWGInstanceSummaryResponse::setQtVersion(QString* qt_version) {
|
||||
this->qt_version = qt_version;
|
||||
}
|
||||
|
||||
SWGLoggingInfo*
|
||||
SWGInstanceSummaryResponse::getLogging() {
|
||||
return logging;
|
||||
|
@ -47,6 +47,9 @@ public:
|
||||
QString* getVersion();
|
||||
void setVersion(QString* version);
|
||||
|
||||
QString* getQtVersion();
|
||||
void setQtVersion(QString* qt_version);
|
||||
|
||||
SWGLoggingInfo* getLogging();
|
||||
void setLogging(SWGLoggingInfo* logging);
|
||||
|
||||
@ -56,6 +59,7 @@ public:
|
||||
|
||||
private:
|
||||
QString* version;
|
||||
QString* qt_version;
|
||||
SWGLoggingInfo* logging;
|
||||
SWGDeviceSetList* devicesetlist;
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user