mirror of
https://gitea.msk.dinamika-avia.ru/Constanta-Design/RRJServer.git
synced 2026-03-27 19:45:43 +03:00
refact
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
|
||||
#include <QDialog>
|
||||
#include "instructor.h"
|
||||
#include "ui_dialogeditinstructor.h"
|
||||
//#include "ui_dialogeditinstructor.h"
|
||||
|
||||
namespace Ui {
|
||||
class DialogEditInstructor;
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
#include <QMessageBox>
|
||||
#include "editorinstructors.h"
|
||||
#include "dialogeditinstructor.h"
|
||||
#include "specialmessagebox.h"
|
||||
#include "ui_editorinstructors.h"
|
||||
|
||||
EditorInstructors::EditorInstructors(ConnectorToServer* connectorToServer, bool adminMode, QWidget *parent) :
|
||||
InstructorsView(connectorToServer, CommonView::TypeView::control, parent),
|
||||
ui(new Ui::EditorInstructors)
|
||||
ui(new Ui::EditorInstructors),
|
||||
dlgEditInstructor(nullptr)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
@@ -34,12 +34,20 @@ EditorInstructors::EditorInstructors(ConnectorToServer* connectorToServer, bool
|
||||
|
||||
EditorInstructors::~EditorInstructors()
|
||||
{
|
||||
if(dlgEditInstructor)
|
||||
{
|
||||
dlgEditInstructor->close();
|
||||
delete dlgEditInstructor;
|
||||
dlgEditInstructor = nullptr;
|
||||
}
|
||||
|
||||
delete ui;
|
||||
}
|
||||
|
||||
void EditorInstructors::closeEvent(QCloseEvent *event)
|
||||
{
|
||||
|
||||
if(dlgEditInstructor)
|
||||
dlgEditInstructor->close();
|
||||
}
|
||||
|
||||
void EditorInstructors::on_btnNewInstructor_clicked()
|
||||
@@ -292,22 +300,25 @@ bool EditorInstructors::verifyInstructor(Instructor instructor)
|
||||
|
||||
bool EditorInstructors::editInstructor(Instructor instructor, Instructor* instructor_edit)
|
||||
{
|
||||
DialogEditInstructor dlg(adminMode, this);
|
||||
dlg.setWindowFlags(dlg.windowFlags() & ~Qt::WindowContextHelpButtonHint);
|
||||
dlgEditInstructor = new DialogEditInstructor(adminMode, this);
|
||||
dlgEditInstructor->setWindowFlags(dlgEditInstructor->windowFlags() & ~Qt::WindowContextHelpButtonHint);
|
||||
|
||||
dlg.setInstructor(instructor);
|
||||
dlgEditInstructor->setInstructor(instructor);
|
||||
|
||||
while (true)
|
||||
bool flStop = false;
|
||||
bool res = false;
|
||||
|
||||
while (!flStop)
|
||||
{
|
||||
switch( dlg.exec() )
|
||||
switch( dlgEditInstructor->exec() )
|
||||
{
|
||||
case QDialog::Accepted:
|
||||
{
|
||||
*instructor_edit = dlg.getInstructor();
|
||||
*instructor_edit = dlgEditInstructor->getInstructor();
|
||||
|
||||
if(! verifyInstructor(*instructor_edit))
|
||||
{
|
||||
dlg.setInstructor(*instructor_edit);
|
||||
dlgEditInstructor->setInstructor(*instructor_edit);
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -318,14 +329,28 @@ bool EditorInstructors::editInstructor(Instructor instructor, Instructor* instru
|
||||
instructor_edit->setNeedSetPassword(false);
|
||||
}
|
||||
|
||||
return true;
|
||||
flStop = true;
|
||||
res = true;
|
||||
break;
|
||||
}
|
||||
case QDialog::Rejected:
|
||||
return false;
|
||||
flStop = true;
|
||||
res = false;
|
||||
break;
|
||||
default:
|
||||
return false;
|
||||
flStop = true;
|
||||
res = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if(dlgEditInstructor)
|
||||
{
|
||||
delete dlgEditInstructor;
|
||||
dlgEditInstructor = nullptr;
|
||||
}
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -4,6 +4,9 @@
|
||||
#include <QDialog>
|
||||
#include <QTreeWidget>
|
||||
#include "instructorsview.h"
|
||||
#include "dialogeditinstructor.h"
|
||||
|
||||
class DialogEditInstructor;
|
||||
|
||||
namespace Ui {
|
||||
class EditorInstructors;
|
||||
@@ -35,8 +38,10 @@ private:
|
||||
|
||||
bool editInstructor(Instructor instructor, Instructor* instructor_edit);
|
||||
|
||||
private:
|
||||
private:
|
||||
Ui::EditorInstructors *ui;
|
||||
|
||||
DialogEditInstructor* dlgEditInstructor;
|
||||
};
|
||||
|
||||
#endif // DIALOGINSTRUCTORS_H
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
<string>New instructor</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../resources.qrc">
|
||||
<iconset resource="../InstructorsAndTrainees.qrc">
|
||||
<normaloff>:/resources/icons/addInstructor.png</normaloff>:/resources/icons/addInstructor.png</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
@@ -89,7 +89,7 @@
|
||||
<string>Delete instructor</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../resources.qrc">
|
||||
<iconset resource="../InstructorsAndTrainees.qrc">
|
||||
<normaloff>:/resources/icons/deleteInstructor.png</normaloff>:/resources/icons/deleteInstructor.png</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
@@ -127,7 +127,7 @@
|
||||
<string>To archive</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../resources.qrc">
|
||||
<iconset resource="../InstructorsAndTrainees.qrc">
|
||||
<normaloff>:/resources/icons/instructorArchive.png</normaloff>:/resources/icons/instructorArchive.png</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
@@ -165,7 +165,7 @@
|
||||
<string>Edit</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../resources.qrc">
|
||||
<iconset resource="../InstructorsAndTrainees.qrc">
|
||||
<normaloff>:/resources/icons/edit.png</normaloff>:/resources/icons/edit.png</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
@@ -216,7 +216,7 @@
|
||||
<string>Show archive</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../resources.qrc">
|
||||
<iconset resource="../InstructorsAndTrainees.qrc">
|
||||
<normaloff>:/resources/icons/archive.png</normaloff>:/resources/icons/archive.png</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
@@ -240,7 +240,7 @@
|
||||
</layout>
|
||||
</widget>
|
||||
<resources>
|
||||
<include location="../resources.qrc"/>
|
||||
<include location="../InstructorsAndTrainees.qrc"/>
|
||||
</resources>
|
||||
<connections/>
|
||||
</ui>
|
||||
|
||||
@@ -25,7 +25,11 @@ ViewerInstructors::ViewerInstructors(ConnectorToServer* connectorToServer, QWidg
|
||||
ViewerInstructors::~ViewerInstructors()
|
||||
{
|
||||
if(dlgRedactor)
|
||||
{
|
||||
dlgRedactor->close();
|
||||
delete dlgRedactor;
|
||||
dlgRedactor = nullptr;
|
||||
}
|
||||
delete ui;
|
||||
}
|
||||
|
||||
@@ -38,7 +42,11 @@ void ViewerInstructors::setAuthComplited(bool authComplited)
|
||||
void ViewerInstructors::deactivate()
|
||||
{
|
||||
if(dlgRedactor)
|
||||
{
|
||||
dlgRedactor->close();
|
||||
delete dlgRedactor;
|
||||
dlgRedactor = nullptr;
|
||||
}
|
||||
|
||||
CommonView::deactivate();
|
||||
updateButtons();
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
<string>Editor of Instructors</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../resources.qrc">
|
||||
<iconset resource="../InstructorsAndTrainees.qrc">
|
||||
<normaloff>:/resources/icons/DB-instructors.png</normaloff>:/resources/icons/DB-instructors.png</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
@@ -67,7 +67,7 @@
|
||||
</layout>
|
||||
</widget>
|
||||
<resources>
|
||||
<include location="../resources.qrc"/>
|
||||
<include location="../InstructorsAndTrainees.qrc"/>
|
||||
</resources>
|
||||
<connections/>
|
||||
</ui>
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
#include "dialogeditgroup.h"
|
||||
#include "computersLocations.h"
|
||||
#include <QPushButton>
|
||||
#include <QRegExpValidator>
|
||||
#include "dialogeditgroup.h"
|
||||
#include "computersLocations.h"
|
||||
#include "ui_dialogeditgroup.h"
|
||||
|
||||
DialogEditGroup::DialogEditGroup(QWidget *parent) :
|
||||
QDialog(parent),
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
#define DIALOGEDITGROUP_H
|
||||
|
||||
#include <QDialog>
|
||||
#include "ui_dialogeditgroup.h"
|
||||
//#include "ui_dialogeditgroup.h"
|
||||
#include "computersLocations.h"
|
||||
#include "group.h"
|
||||
|
||||
|
||||
@@ -7,7 +7,9 @@
|
||||
|
||||
EditorTrainees::EditorTrainees(ConnectorToServer* connectorToServer, bool adminMode, QWidget *parent) :
|
||||
TraineesView(connectorToServer, CommonView::TypeView::control, parent),
|
||||
ui(new Ui::EditorTrainees)
|
||||
ui(new Ui::EditorTrainees),
|
||||
dlgEditTrainee(nullptr),
|
||||
dlgEditGroup(nullptr)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
@@ -38,12 +40,30 @@ EditorTrainees::EditorTrainees(ConnectorToServer* connectorToServer, bool adminM
|
||||
|
||||
EditorTrainees::~EditorTrainees()
|
||||
{
|
||||
if(dlgEditTrainee)
|
||||
{
|
||||
dlgEditTrainee->close();
|
||||
delete dlgEditTrainee;
|
||||
dlgEditTrainee = nullptr;
|
||||
}
|
||||
|
||||
if(dlgEditGroup)
|
||||
{
|
||||
dlgEditGroup->close();
|
||||
delete dlgEditGroup;
|
||||
dlgEditGroup = nullptr;
|
||||
}
|
||||
|
||||
delete ui;
|
||||
}
|
||||
|
||||
void EditorTrainees::closeEvent(QCloseEvent *event)
|
||||
{
|
||||
if(dlgEditTrainee)
|
||||
dlgEditTrainee->close();
|
||||
|
||||
if(dlgEditGroup)
|
||||
dlgEditGroup->close();
|
||||
}
|
||||
|
||||
void EditorTrainees::on_btnNewGroup_clicked()
|
||||
@@ -437,53 +457,73 @@ bool EditorTrainees::verifyTrainee(Trainee trainee)
|
||||
|
||||
bool EditorTrainees::editGroup(Group group, Group *group_edit)
|
||||
{
|
||||
DialogEditGroup dlg(this);
|
||||
dlg.setWindowFlags(dlg.windowFlags() & ~Qt::WindowContextHelpButtonHint);
|
||||
dlgEditGroup = new DialogEditGroup(this);
|
||||
dlgEditGroup->setWindowFlags(dlgEditGroup->windowFlags() & ~Qt::WindowContextHelpButtonHint);
|
||||
|
||||
dlg.setGroup(group);
|
||||
dlgEditGroup->setGroup(group);
|
||||
|
||||
while (true)
|
||||
bool flStop = false;
|
||||
bool res = false;
|
||||
|
||||
while (!flStop)
|
||||
{
|
||||
switch( dlg.exec() )
|
||||
switch( dlgEditGroup->exec() )
|
||||
{
|
||||
case QDialog::Accepted:
|
||||
{
|
||||
*group_edit = dlg.getGroup();
|
||||
*group_edit = dlgEditGroup->getGroup();
|
||||
|
||||
if(! verifyGroup(*group_edit))
|
||||
{
|
||||
dlg.setGroup(*group_edit);
|
||||
dlgEditGroup->setGroup(*group_edit);
|
||||
continue;
|
||||
}
|
||||
|
||||
return true;
|
||||
flStop = true;
|
||||
res = true;
|
||||
break;
|
||||
}
|
||||
case QDialog::Rejected:
|
||||
return false;
|
||||
flStop = true;
|
||||
res = false;
|
||||
break;
|
||||
default:
|
||||
return false;
|
||||
flStop = true;
|
||||
res = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if(dlgEditGroup)
|
||||
{
|
||||
delete dlgEditGroup;
|
||||
dlgEditGroup = nullptr;
|
||||
}
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
bool EditorTrainees::editTrainee(Trainee trainee, Trainee *trainee_edit)
|
||||
{
|
||||
DialogEditTrainee dlg(adminMode, this);
|
||||
dlg.setWindowFlags(dlg.windowFlags() & ~Qt::WindowContextHelpButtonHint);
|
||||
dlgEditTrainee = new DialogEditTrainee(adminMode, this);
|
||||
dlgEditTrainee->setWindowFlags(dlgEditTrainee->windowFlags() & ~Qt::WindowContextHelpButtonHint);
|
||||
|
||||
dlg.setTrainee(trainee);
|
||||
dlgEditTrainee->setTrainee(trainee);
|
||||
|
||||
while (true)
|
||||
bool flStop = false;
|
||||
bool res = false;
|
||||
|
||||
while (!flStop)
|
||||
{
|
||||
switch( dlg.exec() )
|
||||
switch( dlgEditTrainee->exec() )
|
||||
{
|
||||
case QDialog::Accepted:
|
||||
{
|
||||
*trainee_edit = dlg.getTrainee();
|
||||
*trainee_edit = dlgEditTrainee->getTrainee();
|
||||
|
||||
if(! verifyTrainee(*trainee_edit))
|
||||
{
|
||||
dlg.setTrainee(*trainee_edit);
|
||||
dlgEditTrainee->setTrainee(*trainee_edit);
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -494,14 +534,28 @@ bool EditorTrainees::editTrainee(Trainee trainee, Trainee *trainee_edit)
|
||||
trainee_edit->setNeedSetPassword(false);
|
||||
}
|
||||
|
||||
return true;
|
||||
flStop = true;
|
||||
res = true;
|
||||
break;
|
||||
}
|
||||
case QDialog::Rejected:
|
||||
return false;
|
||||
flStop = true;
|
||||
res = false;
|
||||
break;
|
||||
default:
|
||||
return false;
|
||||
flStop = true;
|
||||
res = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if(dlgEditTrainee)
|
||||
{
|
||||
delete dlgEditTrainee;
|
||||
dlgEditTrainee = nullptr;
|
||||
}
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -5,6 +5,8 @@
|
||||
#include <QTreeWidget>
|
||||
#include "traineesview.h"
|
||||
//#include "computersLocations.h"
|
||||
#include "dialogedittrainee.h"
|
||||
#include "dialogeditgroup.h"
|
||||
|
||||
namespace Ui {
|
||||
class EditorTrainees;
|
||||
@@ -43,6 +45,9 @@ private:
|
||||
|
||||
private:
|
||||
Ui::EditorTrainees *ui;
|
||||
|
||||
DialogEditTrainee* dlgEditTrainee;
|
||||
DialogEditGroup* dlgEditGroup;
|
||||
};
|
||||
|
||||
#endif // DIALOGTRAINEESGROUPS_H
|
||||
|
||||
@@ -49,7 +49,11 @@ ViewerTrainees::~ViewerTrainees()
|
||||
}
|
||||
|
||||
if(dlgRedactor)
|
||||
{
|
||||
dlgRedactor->close();
|
||||
delete dlgRedactor;
|
||||
dlgRedactor = nullptr;
|
||||
}
|
||||
|
||||
if(dlgCardTrainee)
|
||||
dlgCardTrainee->close();
|
||||
@@ -66,7 +70,11 @@ void ViewerTrainees::setAuthComplited(bool authComplited)
|
||||
void ViewerTrainees::deactivate()
|
||||
{
|
||||
if(dlgRedactor)
|
||||
{
|
||||
dlgRedactor->close();
|
||||
delete dlgRedactor;
|
||||
dlgRedactor = nullptr;
|
||||
}
|
||||
|
||||
if(dlgCardTrainee)
|
||||
dlgCardTrainee->close();
|
||||
|
||||
Binary file not shown.
@@ -971,7 +971,17 @@ Delete it anyway?</source>
|
||||
<translation>Сервер: </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.ui" line="424"/>
|
||||
<location filename="../instructorsandtraineeswidget.ui" line="386"/>
|
||||
<source>Version of materials: </source>
|
||||
<translation>Версия материалов: </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.ui" line="393"/>
|
||||
<source>...</source>
|
||||
<translation></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.ui" line="448"/>
|
||||
<source> Instructor: </source>
|
||||
<translation> Инструктор: </translation>
|
||||
</message>
|
||||
@@ -991,85 +1001,85 @@ Delete it anyway?</source>
|
||||
<translation>Инструкторы</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.ui" line="369"/>
|
||||
<location filename="../instructorsandtraineeswidget.ui" line="443"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="587"/>
|
||||
<location filename="../instructorsandtraineeswidget.ui" line="375"/>
|
||||
<location filename="../instructorsandtraineeswidget.ui" line="467"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="594"/>
|
||||
<source>none</source>
|
||||
<translation>нет</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="181"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="182"/>
|
||||
<source>The file could not be opened </source>
|
||||
<translation>Файл не может быть открыт </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="287"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="319"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="288"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="320"/>
|
||||
<source>Instructor authorization.</source>
|
||||
<translation>Авторизация инструктора.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="275"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="276"/>
|
||||
<source>Instructor deauthorization</source>
|
||||
<translation>Деавторизация инструктора</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="275"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="276"/>
|
||||
<source>Error!</source>
|
||||
<translation>Ошибка!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="287"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="288"/>
|
||||
<source>Server blocked!</source>
|
||||
<translation>Сервер заблокирован!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="304"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="305"/>
|
||||
<source>Database error!</source>
|
||||
<translation>Ошибка базы данных!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="308"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="309"/>
|
||||
<source>The user is archived!</source>
|
||||
<translation>Пользователь является архивным!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="312"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="313"/>
|
||||
<source>The user is already logged in!</source>
|
||||
<translation>Пользователь уже в сети!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="316"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="317"/>
|
||||
<source>Login or password error!</source>
|
||||
<translation>Ошибка логина или пароля!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="402"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="409"/>
|
||||
<source>The server is not available!</source>
|
||||
<translation>Сервер недоступен!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="599"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="606"/>
|
||||
<source>Connection attempt</source>
|
||||
<translation>Попытка соединения</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="606"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="613"/>
|
||||
<source>connected</source>
|
||||
<translation>подключен</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="609"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="616"/>
|
||||
<source>not connected</source>
|
||||
<translation>не подключен</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="650"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="657"/>
|
||||
<source>Server settings have been changed. Please reconnect to the server.</source>
|
||||
<translation>Настройки сервера изменены. Выполните переподключение к серверу.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="462"/>
|
||||
<location filename="../instructorsandtraineeswidget.cpp" line="469"/>
|
||||
<source>Instructor authorization</source>
|
||||
<translation>Авторизация инструктора</translation>
|
||||
</message>
|
||||
|
||||
@@ -17,7 +17,8 @@ public:
|
||||
this->name = name;
|
||||
this->address = address;
|
||||
this->port = port;
|
||||
this->fullName = "Name: " + name + " IP: " + address + " port : " + port + " login: " + login;
|
||||
//this->fullName = "Name: " + name + " IP: " + address + " port : " + port + " login: " + login;
|
||||
this->fullName = "IP: " + address + " port : " + port + " login: " + login;
|
||||
};
|
||||
~Client(){};
|
||||
|
||||
@@ -31,7 +32,8 @@ public:
|
||||
{
|
||||
this->login = login;
|
||||
isLoggedIn = true;
|
||||
fullName = "Name: " + name + " IP: " + address + " port : " + port + " login: " + login;
|
||||
//fullName = "Name: " + name + " IP: " + address + " port : " + port + " login: " + login;
|
||||
fullName = "IP: " + address + " port : " + port + " login: " + login;
|
||||
}
|
||||
QString getLogin()
|
||||
{
|
||||
|
||||
@@ -53,7 +53,22 @@ void Logger::setLogToFile(bool flag)
|
||||
|
||||
void Logger::handleLog(QString msg, LogLevel logLevel)
|
||||
{
|
||||
/*
|
||||
color: red; * Красный *
|
||||
color: green; * Зелёный *
|
||||
color: blue; * Синий *
|
||||
color: yellow; * Жёлтый *
|
||||
color: black; * Чёрный *
|
||||
color: white; * Белый *
|
||||
color: purple; * Фиолетовый *
|
||||
color: orange; * Оранжевый *
|
||||
color: pink; * Розовый *
|
||||
color: brown; * Коричневый *
|
||||
color: gray; * Серый *
|
||||
*/
|
||||
|
||||
QString level;
|
||||
QString colorLevel = "pink";
|
||||
|
||||
#ifndef PROJECT_TYPE_DEBUG
|
||||
if(logLevel == DEBUG)
|
||||
@@ -62,24 +77,44 @@ void Logger::handleLog(QString msg, LogLevel logLevel)
|
||||
|
||||
switch (logLevel)
|
||||
{
|
||||
case INFO: level = "INFO"; break;
|
||||
case WARNING: level = "WARNING"; break;
|
||||
case ERROR: level = "ERROR"; break;
|
||||
case CRITICAL: level = "CRITICAL"; break;
|
||||
case DEBUG: level = "DEBUG"; break;
|
||||
case INFO:
|
||||
level = "INFO";
|
||||
colorLevel = "green";
|
||||
break;
|
||||
|
||||
case WARNING:
|
||||
level = "WARNING";
|
||||
colorLevel = "yellow";
|
||||
break;
|
||||
|
||||
case ERROR:
|
||||
level = "ERROR";
|
||||
colorLevel = "red";
|
||||
break;
|
||||
|
||||
case CRITICAL:
|
||||
level = "CRITICAL";
|
||||
colorLevel = "purple";
|
||||
break;
|
||||
|
||||
case DEBUG:
|
||||
level = "DEBUG";
|
||||
colorLevel = "brown";
|
||||
break;
|
||||
}
|
||||
|
||||
QString timeStamp = QDateTime::currentDateTime().toString("hh:mm:ss");
|
||||
QString message = timeStamp + " " + level + " " + msg;
|
||||
|
||||
QString messageHTML = QString("<p><span style=\"color: blue;\">%1</span> <span style=\"color: %2;\">%3</span> <span style=\"color: black;\">%4</span></p>").
|
||||
arg(timeStamp, colorLevel, level, msg);
|
||||
|
||||
if (loggingType == LoggingType::WIDGET)
|
||||
{
|
||||
emit sigLogToWidget(message);
|
||||
emit sigLogToWidget(messageHTML);
|
||||
}
|
||||
else if(loggingType == LoggingType::CONSOLE)
|
||||
{
|
||||
qDebug() << message;
|
||||
qDebug() << messageHTML;
|
||||
}
|
||||
|
||||
if(isLogToFile)
|
||||
|
||||
@@ -32,6 +32,7 @@ ServerLMSWidget::ServerLMSWidget(QWidget *parent) :
|
||||
first (true),
|
||||
language(languageENG),
|
||||
errorCode(0),
|
||||
versionStr("..."),
|
||||
flStartInitialization(false)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
@@ -39,6 +40,9 @@ ServerLMSWidget::ServerLMSWidget(QWidget *parent) :
|
||||
qDebug() << "ServerLMSWidget init thread ID " << QThread::currentThreadId();
|
||||
|
||||
ui->widget_Control->setObjectName("widgetControl");
|
||||
ui->btnStopServer->setObjectName("btnStopServer");
|
||||
ui->btnStartServer->setObjectName("btnStartServer");
|
||||
ui->btnSettings->setObjectName("btnSettings");
|
||||
|
||||
registerMetaType();
|
||||
|
||||
@@ -125,7 +129,8 @@ void ServerLMSWidget::slot_UpdateListClients()
|
||||
|
||||
void ServerLMSWidget::slot_AddMessageToLog(QString message)
|
||||
{
|
||||
ui->loggerTextField->appendPlainText(message);
|
||||
//ui->loggerTextField->appendPlainText(message);
|
||||
ui->loggerTextField->appendHtml(message);
|
||||
}
|
||||
|
||||
void ServerLMSWidget::slot_ErrorPostgreSQL(QString text)
|
||||
@@ -170,6 +175,7 @@ void ServerLMSWidget::slot_startInitialization_step1()
|
||||
|
||||
void ServerLMSWidget::slot_setVersion(QString versionStr)
|
||||
{
|
||||
this->versionStr = versionStr;
|
||||
ui->lblVersionText->setText(versionStr);
|
||||
}
|
||||
|
||||
@@ -479,4 +485,6 @@ void ServerLMSWidget::updateStateServer()
|
||||
ui->btnStartServer->setEnabled(false);
|
||||
}
|
||||
}
|
||||
|
||||
ui->lblVersionText->setText(versionStr);
|
||||
}
|
||||
|
||||
@@ -173,6 +173,8 @@ private:
|
||||
QString language;
|
||||
int errorCode;
|
||||
|
||||
QString versionStr;
|
||||
|
||||
bool flStartInitialization;
|
||||
};
|
||||
|
||||
|
||||
@@ -6,10 +6,16 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1000</width>
|
||||
<width>1200</width>
|
||||
<height>600</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>1200</width>
|
||||
<height>600</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<family>Tahoma</family>
|
||||
@@ -45,14 +51,14 @@
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>80</width>
|
||||
<height>55</height>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="baseSize">
|
||||
<size>
|
||||
<width>80</width>
|
||||
<height>40</height>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="layoutDirection">
|
||||
@@ -86,14 +92,14 @@
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>80</width>
|
||||
<height>55</height>
|
||||
<width>16777215</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="baseSize">
|
||||
<size>
|
||||
<width>80</width>
|
||||
<height>40</height>
|
||||
<width>0</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="layoutDirection">
|
||||
@@ -262,13 +268,13 @@
|
||||
<widget class="QLabel" name="lblOnOffText">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>150</width>
|
||||
<width>100</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>150</width>
|
||||
<width>100</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
|
||||
@@ -18,6 +18,7 @@ DialogSettingsTray::DialogSettingsTray(ProviderDBLMS* providerDBLMS, QWidget *pa
|
||||
ui->btnSave->setObjectName("btnSave");
|
||||
ui->btnCheckDB->setObjectName("btnCheckDB");
|
||||
ui->btnUpdateDocs->setObjectName("btnUpdateDocs");
|
||||
ui->checkLocalhost->setObjectName("checkLocalhost");
|
||||
|
||||
/* Создаем строку для регулярного выражения */
|
||||
QString ipRange = "(?:[0-1]?[0-9]?[0-9]|2[0-4][0-9]|25[0-5])";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
<item row="0" column="0">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_DB">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_HostName">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_Local">
|
||||
<item>
|
||||
<widget class="QLabel" name="label_HostName">
|
||||
<widget class="QLabel" name="label_Local">
|
||||
<property name="text">
|
||||
<string>Host name</string>
|
||||
<string>Local</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@@ -94,7 +94,18 @@
|
||||
<item>
|
||||
<widget class="QCheckBox" name="checkLocalhost">
|
||||
<property name="text">
|
||||
<string>Localhost</string>
|
||||
<string/>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_HostName">
|
||||
<item>
|
||||
<widget class="QLabel" name="label_IP">
|
||||
<property name="text">
|
||||
<string>IP address</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
@@ -218,67 +229,11 @@
|
||||
</item>
|
||||
</layout>
|
||||
</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">
|
||||
<size>
|
||||
<width>58</width>
|
||||
<height>58</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Check</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../ServerLMS.qrc">
|
||||
<normaloff>:/resources/icons/checkDB.png</normaloff>:/resources/icons/checkDB.png</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolButtonStyle">
|
||||
<enum>Qt::ToolButtonTextUnderIcon</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</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_Save">
|
||||
<item>
|
||||
@@ -329,19 +284,19 @@
|
||||
<item row="0" column="0">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_Additional">
|
||||
<item>
|
||||
<widget class="QToolButton" name="btnUpdateDocs">
|
||||
<widget class="QToolButton" name="btnCheckDB">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>80</width>
|
||||
<width>58</width>
|
||||
<height>58</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Update Docs</string>
|
||||
<string>Check DB</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../../InstructorsAndTrainees/InstructorsAndTrainees.qrc">
|
||||
<normaloff>:/resources/icons/exchange.png</normaloff>:/resources/icons/exchange.png</iconset>
|
||||
<iconset resource="../ServerLMS.qrc">
|
||||
<normaloff>:/resources/icons/checkDB.png</normaloff>:/resources/icons/checkDB.png</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
<size>
|
||||
@@ -367,6 +322,32 @@
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QToolButton" name="btnUpdateDocs">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>80</width>
|
||||
<height>58</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Update Docs</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="../../InstructorsAndTrainees/InstructorsAndTrainees.qrc">
|
||||
<normaloff>:/resources/icons/exchange.png</normaloff>:/resources/icons/exchange.png</iconset>
|
||||
</property>
|
||||
<property name="iconSize">
|
||||
<size>
|
||||
<width>32</width>
|
||||
<height>32</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolButtonStyle">
|
||||
<enum>Qt::ToolButtonTextUnderIcon</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
|
||||
Binary file not shown.
@@ -4,7 +4,7 @@
|
||||
<context>
|
||||
<name>AssetsManager</name>
|
||||
<message>
|
||||
<location filename="../Systems/assetsmanager.cpp" line="290"/>
|
||||
<location filename="../Systems/assetsmanager.cpp" line="292"/>
|
||||
<source>LLC Constanta-Design</source>
|
||||
<translation>ООО Константа-Дизайн</translation>
|
||||
</message>
|
||||
@@ -168,8 +168,8 @@
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="288"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="340"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="345"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="338"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="343"/>
|
||||
<source>Error!</source>
|
||||
<translation>Ошибка!</translation>
|
||||
</message>
|
||||
@@ -184,35 +184,35 @@
|
||||
<translation>Авторизация суперпользователя PostgreSQL</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="340"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="345"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="338"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="343"/>
|
||||
<source>Error connecting to PostgreSQL!</source>
|
||||
<translation>Ошибка соединения с PostgreSQL!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="341"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="346"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="339"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="344"/>
|
||||
<source>Possible reasons:</source>
|
||||
<translation>Возможные причины:</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="342"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="347"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="340"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="345"/>
|
||||
<source>*superuser PostgreSQL login or password is incorrect;</source>
|
||||
<translation>*логин или пароль суперпользователя PostgreSQL некорректен;</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="343"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="341"/>
|
||||
<source>*Port is incorrect.</source>
|
||||
<translation>*Порт некорректен.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="348"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="346"/>
|
||||
<source>*Port is incorrect;</source>
|
||||
<translation>*Порт некорректен;</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="349"/>
|
||||
<location filename="../settings/dialogsettingstray.cpp" line="347"/>
|
||||
<source>*file 'pg_hba.conf' does not contain an entry for the IP address:</source>
|
||||
<translation>*файл 'pg_hba.conf не содержит записи доступа для IP адреса:</translation>
|
||||
</message>
|
||||
@@ -225,123 +225,129 @@
|
||||
<translation>Форма</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="188"/>
|
||||
<location filename="../serverlmswidget.ui" line="204"/>
|
||||
<source>Logger</source>
|
||||
<translation>Логгер</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="153"/>
|
||||
<location filename="../serverlmswidget.ui" line="169"/>
|
||||
<source>Clients</source>
|
||||
<translation>Клиенты</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="131"/>
|
||||
<location filename="../serverlmswidget.ui" line="142"/>
|
||||
<source>Settings</source>
|
||||
<translation>Настройки</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="237"/>
|
||||
<location filename="../serverlmswidget.ui" line="257"/>
|
||||
<source>Server: </source>
|
||||
<translation>Сервер: </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="295"/>
|
||||
<location filename="../serverlmswidget.ui" line="315"/>
|
||||
<source>Data base: </source>
|
||||
<translation>База данных: </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="256"/>
|
||||
<location filename="../serverlmswidget.ui" line="302"/>
|
||||
<location filename="../serverlmswidget.ui" line="276"/>
|
||||
<location filename="../serverlmswidget.ui" line="328"/>
|
||||
<location filename="../serverlmswidget.ui" line="365"/>
|
||||
<source>...</source>
|
||||
<translation></translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="324"/>
|
||||
<location filename="../serverlmswidget.ui" line="352"/>
|
||||
<source>Version of materials: </source>
|
||||
<translation>Версия материалов: </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="389"/>
|
||||
<source>Authorization</source>
|
||||
<translation>Авторизация</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="51"/>
|
||||
<location filename="../serverlmswidget.ui" line="62"/>
|
||||
<source>Start</source>
|
||||
<translation>Запустить</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.ui" line="92"/>
|
||||
<location filename="../serverlmswidget.ui" line="103"/>
|
||||
<source>Stop</source>
|
||||
<translation>Остановить</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="171"/>
|
||||
<location filename="../serverlmswidget.cpp" line="217"/>
|
||||
<source>Server is started!</source>
|
||||
<translation>Сервер запущен!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="184"/>
|
||||
<location filename="../serverlmswidget.cpp" line="230"/>
|
||||
<source>Server is stoped!</source>
|
||||
<translation>Сервер остановлен!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="223"/>
|
||||
<location filename="../serverlmswidget.cpp" line="272"/>
|
||||
<location filename="../serverlmswidget.cpp" line="269"/>
|
||||
<location filename="../serverlmswidget.cpp" line="332"/>
|
||||
<source>Warning!</source>
|
||||
<translation>Внимание!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="223"/>
|
||||
<location filename="../serverlmswidget.cpp" line="269"/>
|
||||
<source>Database settings have been changed.
|
||||
The server will be restarted.</source>
|
||||
<translation>Настройки Базы Данных были изменены.
|
||||
Сервер будет перезапущен.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="272"/>
|
||||
<location filename="../serverlmswidget.cpp" line="332"/>
|
||||
<source>The file could not be opened </source>
|
||||
<translation>Файл не может быть открыт </translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="351"/>
|
||||
<location filename="../serverlmswidget.cpp" line="355"/>
|
||||
<location filename="../serverlmswidget.cpp" line="406"/>
|
||||
<location filename="../serverlmswidget.cpp" line="410"/>
|
||||
<source>Database connection error!</source>
|
||||
<translation>Ошибка подключения Базы данных!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="194"/>
|
||||
<location filename="../serverlmswidget.cpp" line="355"/>
|
||||
<location filename="../serverlmswidget.cpp" line="240"/>
|
||||
<location filename="../serverlmswidget.cpp" line="410"/>
|
||||
<source>Error!</source>
|
||||
<translation>Ошибка!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="115"/>
|
||||
<location filename="../serverlmswidget.cpp" line="134"/>
|
||||
<source>Error PostgreSQL!</source>
|
||||
<translation>Ошибка PostgreSQL!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="194"/>
|
||||
<location filename="../serverlmswidget.cpp" line="240"/>
|
||||
<source>Settings file could not be opened:</source>
|
||||
<translation>Файл настроек не открыт:</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="370"/>
|
||||
<location filename="../serverlmswidget.cpp" line="427"/>
|
||||
<source>Database connection OK!</source>
|
||||
<translation>База данных подключена!</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="384"/>
|
||||
<location filename="../serverlmswidget.cpp" line="441"/>
|
||||
<source>started</source>
|
||||
<translation>запущен</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="389"/>
|
||||
<location filename="../serverlmswidget.cpp" line="446"/>
|
||||
<source>stoped</source>
|
||||
<translation>остановлен</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="409"/>
|
||||
<location filename="../serverlmswidget.cpp" line="466"/>
|
||||
<source>connected</source>
|
||||
<translation>подключена</translation>
|
||||
</message>
|
||||
<message>
|
||||
<location filename="../serverlmswidget.cpp" line="418"/>
|
||||
<location filename="../serverlmswidget.cpp" line="475"/>
|
||||
<source>not connected</source>
|
||||
<translation>не подключена</translation>
|
||||
</message>
|
||||
|
||||
@@ -16,6 +16,7 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||
action_Exit(nullptr)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
setWindowFlags(windowFlags() & ~Qt::WindowMinimizeButtonHint);
|
||||
|
||||
//Скрываем ненужные элементы окна
|
||||
ui->menubar->setVisible(false);
|
||||
|
||||
Reference in New Issue
Block a user