Server settings are read from QSettings and applied if they are changed.

This commit is contained in:
2026-02-03 11:17:26 +01:00
parent d4ff1ffb61
commit 6adf18caeb
5 changed files with 37 additions and 5 deletions

View File

@ -13,7 +13,6 @@ ServerCommunicator::ServerCommunicator(QObject* parent)
m_netManager.setAutoDeleteReplies(true);
m_restManager = std::make_shared<QRestAccessManager>(&m_netManager);
m_serviceApi = std::make_shared<QNetworkRequestFactory>();
setUrl(baseUrl);
}
bool ServerCommunicator::sslSupported() {
@ -96,3 +95,12 @@ void ServerCommunicator::deleteItem(const QString& id) {
reply->deleteLater();
});
}
void ServerCommunicator::setServerConfiguration(const QString url,
const QString email,
const QString password) {
setUrl(url);
m_email = email;
m_password = password;
}