Removed rauc/opkg-versions. Added fetching of apism-version.
This commit is contained in:
parent
a84f495d43
commit
12ffa71455
28
worker.cpp
28
worker.cpp
@ -57,8 +57,6 @@ Worker::Worker(hwinf *hw,
|
|||||||
, m_osVersion(getOsVersion())
|
, m_osVersion(getOsVersion())
|
||||||
, m_atbqtVersion(getATBQTVersion())
|
, m_atbqtVersion(getATBQTVersion())
|
||||||
, m_cpuSerial(getCPUSerial())
|
, m_cpuSerial(getCPUSerial())
|
||||||
, m_raucVersion(getRaucVersion())
|
|
||||||
, m_opkgVersion(getOpkgVersion())
|
|
||||||
, m_pluginVersionATBDeciceController(getPluginVersion("/opt/app/ATBAPP/plugins/libATBDeviceControllerPlugin.so"))
|
, m_pluginVersionATBDeciceController(getPluginVersion("/opt/app/ATBAPP/plugins/libATBDeviceControllerPlugin.so"))
|
||||||
, m_pluginVersionIngenicoISelf(getPluginVersion("/opt/app/ATBAPP/plugins/libIngenicoISelf_CCPlugin.so"))
|
, m_pluginVersionIngenicoISelf(getPluginVersion("/opt/app/ATBAPP/plugins/libIngenicoISelf_CCPlugin.so"))
|
||||||
, m_pluginVersionMobilisisCalc(getPluginVersion("/opt/app/ATBAPP/plugins/libMOBILISIS_CalculatePricePlugin.so"))
|
, m_pluginVersionMobilisisCalc(getPluginVersion("/opt/app/ATBAPP/plugins/libMOBILISIS_CalculatePricePlugin.so"))
|
||||||
@ -76,6 +74,16 @@ Worker::Worker(hwinf *hw,
|
|||||||
|
|
||||||
QDir::setCurrent(m_workingDirectory);
|
QDir::setCurrent(m_workingDirectory);
|
||||||
|
|
||||||
|
// restart apism to make sure it is running ?
|
||||||
|
// Command c("systemctl restart apism");
|
||||||
|
// if (c.execute("/tmp")) {
|
||||||
|
// QThread::sleep(10); // give APISM some time to reconnect
|
||||||
|
// }
|
||||||
|
|
||||||
|
if (std::optional<QString> v = getApismVersion()) {
|
||||||
|
m_apismVersion = v.value();
|
||||||
|
}
|
||||||
|
|
||||||
qInfo() << "CURRENT TIME ..............." << QDateTime::currentDateTime().toString(Qt::ISODate);
|
qInfo() << "CURRENT TIME ..............." << QDateTime::currentDateTime().toString(Qt::ISODate);
|
||||||
qInfo() << "OS VERSION ................." << m_osVersion;
|
qInfo() << "OS VERSION ................." << m_osVersion;
|
||||||
qInfo() << "ATBQT VERSION .............." << m_atbqtVersion;
|
qInfo() << "ATBQT VERSION .............." << m_atbqtVersion;
|
||||||
@ -88,6 +96,7 @@ Worker::Worker(hwinf *hw,
|
|||||||
qInfo() << "ZONE_NR ...................." << m_zoneNr;
|
qInfo() << "ZONE_NR ...................." << m_zoneNr;
|
||||||
qInfo() << "BRANCH_NAME ................" << m_branchName;
|
qInfo() << "BRANCH_NAME ................" << m_branchName;
|
||||||
qInfo() << "WORKING_DIRECTORY .........." << m_workingDirectory;
|
qInfo() << "WORKING_DIRECTORY .........." << m_workingDirectory;
|
||||||
|
qInfo() << "APISM VERSION .............." << m_apismVersion;
|
||||||
|
|
||||||
this->moveToThread(&m_workerThread);
|
this->moveToThread(&m_workerThread);
|
||||||
m_workerThread.start();
|
m_workerThread.start();
|
||||||
@ -141,20 +150,8 @@ void Worker::update() {
|
|||||||
|
|
||||||
void Worker::privateUpdate() {
|
void Worker::privateUpdate() {
|
||||||
m_updateProcessRunning = true;
|
m_updateProcessRunning = true;
|
||||||
|
|
||||||
bool sentIsmasLastVersionNotification = false;
|
bool sentIsmasLastVersionNotification = false;
|
||||||
|
|
||||||
//emit appendText("\nRestart APISM ...");
|
|
||||||
//startProgressLoop();
|
|
||||||
//Command c("systemctl restart apism");
|
|
||||||
//if (c.execute("/tmp")) {
|
|
||||||
// QThread::sleep(10); // give APISM some time to reconnect
|
|
||||||
// stopProgressLoop();
|
|
||||||
// emit replaceLast("Restart APISM ...", UPDATE_STEP_DONE);
|
|
||||||
//} else {
|
|
||||||
// stopProgressLoop();
|
|
||||||
// emit replaceLast("Restart APISM ...", UPDATE_STEP_FAIL);
|
|
||||||
//}
|
|
||||||
|
|
||||||
emit disableExit();
|
emit disableExit();
|
||||||
|
|
||||||
@ -1212,8 +1209,7 @@ PSAInstalled Worker::getPSAInstalled() {
|
|||||||
psaInstalled.dc.gitLastCommit = "N/A";
|
psaInstalled.dc.gitLastCommit = "N/A";
|
||||||
psaInstalled.dc.size = -1;
|
psaInstalled.dc.size = -1;
|
||||||
|
|
||||||
psaInstalled.sw.raucVersion = m_raucVersion;
|
psaInstalled.sw.apismVersion = m_apismVersion;
|
||||||
psaInstalled.sw.opkgVersion = m_opkgVersion;
|
|
||||||
psaInstalled.sw.atbQTVersion = m_atbqtVersion;
|
psaInstalled.sw.atbQTVersion = m_atbqtVersion;
|
||||||
|
|
||||||
psaInstalled.pluginVersion.deviceController = m_pluginVersionATBDeciceController;
|
psaInstalled.pluginVersion.deviceController = m_pluginVersionATBDeciceController;
|
||||||
|
Loading…
Reference in New Issue
Block a user