mirror of
https://gitea.msk.dinamika-avia.ru/Constanta-Design/RRJServer.git
synced 2026-03-27 19:45:43 +03:00
refact 0
This commit is contained in:
@@ -13,6 +13,8 @@ DialogCheckDB::DialogCheckDB(ProviderDBLMS* providerDBLMS, QWidget *parent) :
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
ui->btnRepare->setObjectName("btnRepare");
|
||||
|
||||
ui->btnRepare->setEnabled(false);
|
||||
|
||||
check();
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>150</width>
|
||||
<width>170</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
@@ -44,6 +44,19 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="lblDriverResIco">
|
||||
<property name="sizePolicy">
|
||||
@@ -86,7 +99,7 @@
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>150</width>
|
||||
<width>170</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
@@ -102,6 +115,19 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="lblUserResIco">
|
||||
<property name="sizePolicy">
|
||||
@@ -144,7 +170,7 @@
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>150</width>
|
||||
<width>170</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
@@ -160,6 +186,19 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_3">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="lblDBResIco">
|
||||
<property name="sizePolicy">
|
||||
@@ -190,21 +229,21 @@
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_Ctrl">
|
||||
<item>
|
||||
<widget class="QToolButton" name="toolButton">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>...</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QToolButton" name="btnRepare">
|
||||
<property name="minimumSize">
|
||||
|
||||
@@ -14,6 +14,7 @@ DialogSettingsTray::DialogSettingsTray(ProviderDBLMS* providerDBLMS, QWidget *pa
|
||||
ui->setupUi(this);
|
||||
|
||||
ui->btnSave->setObjectName("btnSave");
|
||||
ui->btnCheckDB->setObjectName("btnCheckDB");
|
||||
|
||||
/* Создаем строку для регулярного выражения */
|
||||
QString ipRange = "(?:[0-1]?[0-9]?[0-9]|2[0-4][0-9]|25[0-5])";
|
||||
@@ -54,6 +55,7 @@ DialogSettingsTray::DialogSettingsTray(ProviderDBLMS* providerDBLMS, QWidget *pa
|
||||
}
|
||||
|
||||
ui->btnSave->setEnabled(false);
|
||||
ui->btnCheckDB->setEnabled(true);
|
||||
flSettingsServerChanged = false;
|
||||
}
|
||||
|
||||
@@ -179,6 +181,8 @@ void DialogSettingsTray::on_btnSave_clicked()
|
||||
|
||||
saveSettings();
|
||||
|
||||
ui->btnCheckDB->setEnabled(true);
|
||||
|
||||
this->accept();
|
||||
}
|
||||
|
||||
@@ -202,30 +206,35 @@ void DialogSettingsTray::on_DialogSettingsTray_accepted()
|
||||
void DialogSettingsTray::on_editNameDB_textChanged(const QString &arg1)
|
||||
{
|
||||
ui->btnSave->setEnabled(true);
|
||||
ui->btnCheckDB->setEnabled(false);
|
||||
flSettingsServerChanged = true;
|
||||
}
|
||||
|
||||
void DialogSettingsTray::on_editHostName_textChanged(const QString &arg1)
|
||||
{
|
||||
ui->btnSave->setEnabled(true);
|
||||
ui->btnCheckDB->setEnabled(false);
|
||||
flSettingsServerChanged = true;
|
||||
}
|
||||
|
||||
void DialogSettingsTray::on_editPort_textChanged(const QString &arg1)
|
||||
{
|
||||
ui->btnSave->setEnabled(true);
|
||||
ui->btnCheckDB->setEnabled(false);
|
||||
flSettingsServerChanged = true;
|
||||
}
|
||||
|
||||
void DialogSettingsTray::on_editUserName_textChanged(const QString &arg1)
|
||||
{
|
||||
ui->btnSave->setEnabled(true);
|
||||
ui->btnCheckDB->setEnabled(false);
|
||||
flSettingsServerChanged = true;
|
||||
}
|
||||
|
||||
void DialogSettingsTray::on_editPassword_textChanged(const QString &arg1)
|
||||
{
|
||||
ui->btnSave->setEnabled(true);
|
||||
ui->btnCheckDB->setEnabled(false);
|
||||
flSettingsServerChanged = true;
|
||||
}
|
||||
|
||||
|
||||
@@ -181,6 +181,19 @@
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_Check">
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QToolButton" name="btnCheckDB">
|
||||
<property name="minimumSize">
|
||||
@@ -190,7 +203,7 @@
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Check DB</string>
|
||||
<string>Check</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="ServerLMS.qrc">
|
||||
|
||||
@@ -9,7 +9,7 @@ MultiThreadServer::MultiThreadServer(ServerLMSWidget *widget,UpdateController *u
|
||||
updateController(updateController),
|
||||
dataParser(dataParser),
|
||||
stateServer(stoped),
|
||||
stateBlockAutorization(unblocked)
|
||||
stateBlockAutorization(blocked)
|
||||
{
|
||||
clientsMap = new QMap<int,ClientHandler*>;
|
||||
}
|
||||
|
||||
@@ -33,6 +33,10 @@ public:
|
||||
{
|
||||
return stateBlockAutorization;
|
||||
}
|
||||
EStateServer getStateServer()
|
||||
{
|
||||
return stateServer;
|
||||
}
|
||||
signals:
|
||||
void sigInitClient(int descriptor, ServerLMSWidget *serverWidget,
|
||||
UpdateController *updateController, DataParser *dataParser);
|
||||
|
||||
@@ -40,7 +40,7 @@ ServerLMSWidget::ServerLMSWidget(QWidget *parent) :
|
||||
|
||||
updateMyStyleSheet();
|
||||
|
||||
setLanguageInterfase();
|
||||
setLanguageInterfase();
|
||||
}
|
||||
|
||||
ServerLMSWidget::~ServerLMSWidget()
|
||||
@@ -49,7 +49,6 @@ ServerLMSWidget::~ServerLMSWidget()
|
||||
{
|
||||
server->stopServer();
|
||||
|
||||
//updateThread->exit();
|
||||
updateThread->quit();
|
||||
updateThread->wait();
|
||||
delete updateThread;
|
||||
@@ -64,7 +63,6 @@ ServerLMSWidget::~ServerLMSWidget()
|
||||
|
||||
delete mutex;
|
||||
|
||||
//loggerThread->exit();
|
||||
loggerThread->quit();
|
||||
loggerThread->wait();
|
||||
delete loggerThread;
|
||||
@@ -82,20 +80,7 @@ void ServerLMSWidget::changeEvent(QEvent *event)
|
||||
{
|
||||
ui->retranslateUi(this); // переведём окно заново
|
||||
|
||||
if(providerDBLMS->DBisConnected())
|
||||
{
|
||||
//Настройки БД
|
||||
DataBaseSettings dbSettings = providerDBLMS->getDBSettings();
|
||||
QString strDBsettings = QString("%1 (%2) %3 : %4").arg(dbSettings.dbName,
|
||||
dbSettings.dbType,
|
||||
dbSettings.dbHostName,
|
||||
QString::number(dbSettings.dbPort));
|
||||
ui->lblDBsettings->setText(strDBsettings);
|
||||
}
|
||||
else
|
||||
{
|
||||
ui->lblDBsettings->setText("");
|
||||
}
|
||||
updateStateServer();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -161,9 +146,11 @@ void ServerLMSWidget::on_btnStartServer_clicked()
|
||||
|
||||
ui->btnStartServer->setEnabled(false);
|
||||
ui->btnStopServer->setEnabled(true);
|
||||
ui->lblOnOff->setPixmap(QPixmap(QStringLiteral(":/resources/icons/switchOn.png")));
|
||||
slot_BlockAutorization(false);
|
||||
|
||||
emit signal_Tray_ShowMessage(tr("Server is started!"));
|
||||
}
|
||||
updateStateServer();
|
||||
}
|
||||
|
||||
void ServerLMSWidget::on_btnStopServer_clicked()
|
||||
@@ -172,9 +159,11 @@ void ServerLMSWidget::on_btnStopServer_clicked()
|
||||
{
|
||||
ui->btnStopServer->setEnabled(false);
|
||||
ui->btnStartServer->setEnabled(true);
|
||||
ui->lblOnOff->setPixmap(QPixmap(QStringLiteral(":/resources/icons/switchOff.png")));
|
||||
slot_BlockAutorization(true);
|
||||
|
||||
emit signal_Tray_ShowMessage(tr("Server is stoped!"));
|
||||
}
|
||||
updateStateServer();
|
||||
}
|
||||
|
||||
void ServerLMSWidget::on_btnSettings_clicked()
|
||||
@@ -200,8 +189,7 @@ void ServerLMSWidget::on_btnSettings_clicked()
|
||||
|
||||
providerDBLMS->DisConnectionFromDB();
|
||||
|
||||
ui->lblDBsettings->setText("");
|
||||
ui->lblDBisConnected->setPixmap(QPixmap(QStringLiteral(":/resources/icons/circleGreen.png")));
|
||||
updateStateServer();
|
||||
|
||||
QMessageBox::warning(this, tr("Warning!"), tr("Database settings have been changed.\nThe server will be restarted."));
|
||||
|
||||
@@ -313,19 +301,19 @@ void ServerLMSWidget::startInitialization()
|
||||
ui->btnStartServer->setEnabled(true);
|
||||
|
||||
flStartInitialization = true;
|
||||
|
||||
updateStateServer();
|
||||
}
|
||||
|
||||
void ServerLMSWidget::tryConnectionToDB()
|
||||
{
|
||||
if(! providerDBLMS->ConnectionToDB())
|
||||
{
|
||||
ui->lblDBsettings->setText("");
|
||||
ui->lblDBisConnected->setPixmap(QPixmap(QStringLiteral(":/resources/icons/circleGray.png")));
|
||||
ui->btnStopServer->setEnabled(false);
|
||||
ui->btnStartServer->setEnabled(false);
|
||||
//QMessageBox::critical(this, tr("Error!"), tr("Database connection error!"));
|
||||
|
||||
emit signal_Tray_ShowMessage(tr("Database connection error!"), QSystemTrayIcon::Critical);
|
||||
|
||||
emit signal_Menu_ShowWindow();
|
||||
|
||||
QMessageBox::critical(this, tr("Error!"), tr("Database connection error!"));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -337,11 +325,60 @@ void ServerLMSWidget::tryConnectionToDB()
|
||||
dbSettings.dbType,
|
||||
dbSettings.dbHostName,
|
||||
QString::number(dbSettings.dbPort));
|
||||
ui->lblDBsettings->setText(strDBsettings);
|
||||
ui->lblDBisConnected->setPixmap(QPixmap(QStringLiteral(":/resources/icons/circleGreen.png")));
|
||||
|
||||
emit signal_Tray_ShowMessage(tr("Database connection OK!") + "\n" + strDBsettings);
|
||||
|
||||
on_btnStartServer_clicked();
|
||||
}
|
||||
|
||||
updateStateServer();
|
||||
}
|
||||
|
||||
void ServerLMSWidget::updateStateServer()
|
||||
{
|
||||
if(server)
|
||||
{
|
||||
if(server->getStateServer() == EStateServer::started)
|
||||
{
|
||||
ui->lblOnOffText->setText(tr("started"));
|
||||
ui->lblOnOff->setPixmap(QPixmap(QStringLiteral(":/resources/icons/circleGreen.png")));
|
||||
}
|
||||
else
|
||||
{
|
||||
ui->lblOnOffText->setText(tr("stoped"));
|
||||
ui->lblOnOff->setPixmap(QPixmap(QStringLiteral(":/resources/icons/circleGray.png")));
|
||||
}
|
||||
|
||||
if(server->getStateBlockAutorization() == EStateBlockAutorization::unblocked)
|
||||
{
|
||||
ui->lblBlockAuth->setPixmap(QPixmap(QStringLiteral(":/resources/icons/open.png")));
|
||||
}
|
||||
else
|
||||
{
|
||||
ui->lblBlockAuth->setPixmap(QPixmap(QStringLiteral(":/resources/icons/lock.png")));
|
||||
}
|
||||
}
|
||||
|
||||
if(providerDBLMS)
|
||||
{
|
||||
if(providerDBLMS->DBisConnected())
|
||||
{
|
||||
//Настройки БД
|
||||
DataBaseSettings dbSettings = providerDBLMS->getDBSettings();
|
||||
QString strDBsettings = tr("connected") + QString(" [%1 (%2) %3 : %4]").arg(dbSettings.dbName,
|
||||
dbSettings.dbType,
|
||||
dbSettings.dbHostName,
|
||||
QString::number(dbSettings.dbPort));
|
||||
ui->lblDBsettings->setText(strDBsettings);
|
||||
ui->lblDBisConnected->setPixmap(QPixmap(QStringLiteral(":/resources/icons/circleGreen.png")));
|
||||
}
|
||||
else
|
||||
{
|
||||
ui->lblDBsettings->setText(tr("not connected"));
|
||||
ui->lblDBisConnected->setPixmap(QPixmap(QStringLiteral(":/resources/icons/circleGray.png")));
|
||||
|
||||
ui->btnStopServer->setEnabled(false);
|
||||
ui->btnStartServer->setEnabled(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -68,6 +68,9 @@ signals:
|
||||
//сигнал вывода сообщения из трея
|
||||
void signal_Tray_ShowMessage(QString textMsg, QSystemTrayIcon::MessageIcon iconMsg = QSystemTrayIcon::Information);
|
||||
|
||||
void signal_Menu_ShowWindow();
|
||||
void signal_Menu_HideWindow();
|
||||
|
||||
void sigRecognize();
|
||||
void sigCalculateFullHash();
|
||||
void sigUpdateController(CommonClientHandler* commonClientHandler,DataParser *dataParser,AssetsManager *assetManager);
|
||||
@@ -121,6 +124,8 @@ private:
|
||||
|
||||
void tryConnectionToDB();
|
||||
|
||||
void updateStateServer();
|
||||
|
||||
private:
|
||||
Ui::ServerLMSWidget *ui;
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>800</width>
|
||||
<width>1000</width>
|
||||
<height>600</height>
|
||||
</rect>
|
||||
</property>
|
||||
@@ -23,7 +23,7 @@
|
||||
<item row="0" column="0">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_Main">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_State">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_Ctrl">
|
||||
<item>
|
||||
<widget class="QToolButton" name="btnStartServer">
|
||||
<property name="minimumSize">
|
||||
@@ -106,25 +106,6 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="lblOnOff">
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="ServerLMS.qrc">:/resources/icons/switchOff.png</pixmap>
|
||||
</property>
|
||||
<property name="scaledContents">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_1">
|
||||
<property name="orientation">
|
||||
@@ -222,79 +203,11 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_DBsettings">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_State">
|
||||
<item>
|
||||
<widget class="QLabel" name="lblDBisConnected">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="../InstructorsAndTrainees/InstructorsAndTrainees.qrc">:/resources/icons/circleGray.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_DataBase">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Maximum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Data base: </string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="lblDBsettings">
|
||||
<property name="text">
|
||||
<string>...</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_Block">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_OnOff">
|
||||
<item>
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>Authorization</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="lblBlockAuth">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<widget class="QLabel" name="lblOnOff">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
@@ -311,13 +224,140 @@
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="ServerLMS.qrc">:/resources/icons/open.png</pixmap>
|
||||
<pixmap resource="../InstructorsAndTrainees/InstructorsAndTrainees.qrc">:/resources/icons/circleGray.png</pixmap>
|
||||
</property>
|
||||
<property name="scaledContents">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_Server">
|
||||
<property name="text">
|
||||
<string>Server: </string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="lblOnOffText">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>150</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>100</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>...</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_DBsettings">
|
||||
<item>
|
||||
<widget class="QLabel" name="lblDBisConnected">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="../InstructorsAndTrainees/InstructorsAndTrainees.qrc">:/resources/icons/circleGray.png</pixmap>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="label_DataBase">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Maximum" vsizetype="Preferred">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Data base: </string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="lblDBsettings">
|
||||
<property name="text">
|
||||
<string>...</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_Block">
|
||||
<item>
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>Authorization</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="lblBlockAuth">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="pixmap">
|
||||
<pixmap resource="ServerLMS.qrc">:/resources/icons/open.png</pixmap>
|
||||
</property>
|
||||
<property name="scaledContents">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
|
||||
Binary file not shown.
@@ -9,6 +9,86 @@
|
||||
<translation>ООО Константа-Дизайн</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>DialogCheckDB</name>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.ui" line="14"/>
|
||||
<location filename="../dialogcheckdb.ui" line="152"/>
|
||||
<source>Database</source>
|
||||
<translation>База данных</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.ui" line="36"/>
|
||||
<source>Driver PostgreSQL</source>
|
||||
<translation>Драйвер PostgreSQL</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.ui" line="43"/>
|
||||
<location filename="../dialogcheckdb.ui" line="101"/>
|
||||
<location filename="../dialogcheckdb.ui" line="159"/>
|
||||
<location filename="../dialogcheckdb.ui" line="204"/>
|
||||
<source>...</source>
|
||||
<translation></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.ui" line="94"/>
|
||||
<source>User</source>
|
||||
<translation>Пользователь</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.ui" line="217"/>
|
||||
<source>Repare</source>
|
||||
<translation>Восстановить</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.cpp" line="35"/>
|
||||
<source>Installed</source>
|
||||
<translation>Установлен</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.cpp" line="40"/>
|
||||
<source>Not installed</source>
|
||||
<translation>Не установлен</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.cpp" line="47"/>
|
||||
<location filename="../dialogcheckdb.cpp" line="59"/>
|
||||
<source>Exist</source>
|
||||
<translation>Существует</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.cpp" line="52"/>
|
||||
<location filename="../dialogcheckdb.cpp" line="64"/>
|
||||
<source>Not exist</source>
|
||||
<translation>Не существует</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.cpp" line="78"/>
|
||||
<source>Warning!</source>
|
||||
<translation>Внимание!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.cpp" line="78"/>
|
||||
<source>Install PostgreSQL.</source>
|
||||
<translation>Установите PostgreSQL.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.cpp" line="86"/>
|
||||
<location filename="../dialogcheckdb.cpp" line="95"/>
|
||||
<source>Error!</source>
|
||||
<translation>Ошибка!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.cpp" line="86"/>
|
||||
<source>Failed to create user!</source>
|
||||
<translation>Ошибка создания пользователя!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogcheckdb.cpp" line="95"/>
|
||||
<source>Failed to create Database!</source>
|
||||
<translation>Ошибка создания Базы данных!</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>DialogSettingsTray</name>
|
||||
<message>
|
||||
@@ -57,7 +137,12 @@
|
||||
<translation>Пароль</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogsettingstray.ui" line="211"/>
|
||||
<location filename="../dialogsettingstray.ui" line="193"/>
|
||||
<source>Check DB</source>
|
||||
<translation>Проверить БД</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../dialogsettingstray.ui" line="241"/>
|
||||
<source>Save</source>
|
||||
<translation>Сохранить</translation>
|
||||
</message>
|
||||
@@ -70,32 +155,38 @@
|
||||
<translation>Форма</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="207"/>
|
||||
<location filename="../serverlmswidget.ui" line="188"/>
|
||||
<source>Logger</source>
|
||||
<translation>Логгер</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="172"/>
|
||||
<location filename="../serverlmswidget.ui" line="153"/>
|
||||
<source>Clients</source>
|
||||
<translation>Клиенты</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="150"/>
|
||||
<location filename="../serverlmswidget.ui" line="131"/>
|
||||
<source>Settings</source>
|
||||
<translation>Настройки</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="235"/>
|
||||
<location filename="../serverlmswidget.ui" line="237"/>
|
||||
<source>Server: </source>
|
||||
<translation>Сервер: </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="295"/>
|
||||
<source>Data base: </source>
|
||||
<translation>База данных: </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="242"/>
|
||||
<location filename="../serverlmswidget.ui" line="256"/>
|
||||
<location filename="../serverlmswidget.ui" line="302"/>
|
||||
<source>...</source>
|
||||
<translation></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="264"/>
|
||||
<location filename="../serverlmswidget.ui" line="324"/>
|
||||
<source>Authorization</source>
|
||||
<translation>Авторизация</translation>
|
||||
</message>
|
||||
@@ -110,32 +201,68 @@
|
||||
<translation>Остановить</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="201"/>
|
||||
<location filename="../serverlmswidget.cpp" line="250"/>
|
||||
<location filename="../serverlmswidget.cpp" line="151"/>
|
||||
<source>Server is started!</source>
|
||||
<translation>Сервер запущен!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="164"/>
|
||||
<source>Server is stoped!</source>
|
||||
<translation>Сервер остановлен!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="194"/>
|
||||
<location filename="../serverlmswidget.cpp" line="243"/>
|
||||
<source>Warning!</source>
|
||||
<translation>Внимание!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="201"/>
|
||||
<location filename="../serverlmswidget.cpp" line="194"/>
|
||||
<source>Database settings have been changed.
|
||||
The server will be restarted.</source>
|
||||
<translation>Настройки Базы Данных были изменены.
|
||||
Сервер будет перезапущен.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="250"/>
|
||||
<location filename="../serverlmswidget.cpp" line="243"/>
|
||||
<source>The file could not be opened </source>
|
||||
<translation>Файл не может быть открыт </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="320"/>
|
||||
<location filename="../serverlmswidget.cpp" line="312"/>
|
||||
<location filename="../serverlmswidget.cpp" line="316"/>
|
||||
<source>Database connection error!</source>
|
||||
<translation>Ошибка подключения Базы данных!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="316"/>
|
||||
<source>Error!</source>
|
||||
<translation>Ошибка!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="320"/>
|
||||
<source>Database connection error</source>
|
||||
<translation>Ошибка подключения к Базе Данных</translation>
|
||||
<location filename="../serverlmswidget.cpp" line="329"/>
|
||||
<source>Database connection OK!</source>
|
||||
<translation>База данных подключена!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="343"/>
|
||||
<source>started</source>
|
||||
<translation>запущен</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="348"/>
|
||||
<source>stoped</source>
|
||||
<translation>остановлен</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="368"/>
|
||||
<source>connected</source>
|
||||
<translation>подключена</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="377"/>
|
||||
<source>not connected</source>
|
||||
<translation>не подключена</translation>
|
||||
</message>
|
||||
</context>
|
||||
</TS>
|
||||
|
||||
Reference in New Issue
Block a user