diff --git a/GUIdataBaseLMS/CMakeLists.txt b/GUIdataBaseLMS/CMakeLists.txt index 5eeb9c7..f9847fb 100644 --- a/GUIdataBaseLMS/CMakeLists.txt +++ b/GUIdataBaseLMS/CMakeLists.txt @@ -7,7 +7,7 @@ main.cpp mainwindow.cpp mainwindow.h mainwindow.ui -testDBpgSQL.qrc +GUIdataBaseLMS.qrc ) target_link_libraries(GUIdataBaseLMS PRIVATE Qt5::Widgets) diff --git a/GUIdataBaseLMS/testDBpgSQL.qrc b/GUIdataBaseLMS/GUIdataBaseLMS.qrc similarity index 100% rename from GUIdataBaseLMS/testDBpgSQL.qrc rename to GUIdataBaseLMS/GUIdataBaseLMS.qrc diff --git a/GUIdataBaseLMS/StaticData/authData.xml b/GUIdataBaseLMS/StaticData/authData.xml deleted file mode 100644 index 69f75cd..0000000 --- a/GUIdataBaseLMS/StaticData/authData.xml +++ /dev/null @@ -1,2 +0,0 @@ - - \ No newline at end of file diff --git a/GUIdataBaseLMS/StaticData/settings.xml b/GUIdataBaseLMS/StaticData/settings.xml deleted file mode 100644 index 9aafbf5..0000000 --- a/GUIdataBaseLMS/StaticData/settings.xml +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/GUIdataBaseLMS/StaticData/temp.xml b/GUIdataBaseLMS/StaticData/temp.xml deleted file mode 100644 index 40e39ea..0000000 --- a/GUIdataBaseLMS/StaticData/temp.xml +++ /dev/null @@ -1,2 +0,0 @@ - - diff --git a/GUIdataBaseLMS/mainwindow.cpp b/GUIdataBaseLMS/mainwindow.cpp index 8aa61d9..099d963 100644 --- a/GUIdataBaseLMS/mainwindow.cpp +++ b/GUIdataBaseLMS/mainwindow.cpp @@ -14,7 +14,7 @@ MainWindow::MainWindow(QWidget *parent) instructorsAndTraineesWidget = new InstructorsAndTraineesWidget(this); - connect(instructorsAndTraineesWidget,&InstructorsAndTraineesWidget::signal_LanguageChanged,this,&MainWindow::slot_LanguageChanged); + connect(instructorsAndTraineesWidget, &InstructorsAndTraineesWidget::signal_LanguageChanged, this, &MainWindow::slot_LanguageChanged); ui->horizontalLayout->addWidget(instructorsAndTraineesWidget); @@ -22,16 +22,8 @@ MainWindow::MainWindow(QWidget *parent) this->showNormal(); //this->showMaximized(); - if(instructorsAndTraineesWidget->getLanguage() == "ENG") - { - qtLanguageTranslator.load(QString("translations/GUIdataBaseLMS_") + "en_EN", "."); - qApp->installTranslator(&qtLanguageTranslator); - } - else - { - qtLanguageTranslator.load(QString("translations/GUIdataBaseLMS_") + "ru_RU", "."); - qApp->installTranslator(&qtLanguageTranslator); - } + qtLanguageTranslator.load(QString("translations/GUIdataBaseLMS_") + instructorsAndTraineesWidget->getLanguage(), "."); + qApp->installTranslator(&qtLanguageTranslator); } MainWindow::~MainWindow() diff --git a/GUIdataBaseLMS/mainwindow.ui b/GUIdataBaseLMS/mainwindow.ui index 0d66ace..31303b8 100644 --- a/GUIdataBaseLMS/mainwindow.ui +++ b/GUIdataBaseLMS/mainwindow.ui @@ -10,11 +10,16 @@ 600 + + + Tahoma + + Learning management system (LMS) - + :/resources/lms.png:/resources/lms.png @@ -42,7 +47,7 @@ - + diff --git a/GUIdataBaseLMS/translations/GUIdataBaseLMS_ru_RU.ts b/GUIdataBaseLMS/translations/GUIdataBaseLMS_ru_RU.ts index 9fe98cb..a29e418 100644 --- a/GUIdataBaseLMS/translations/GUIdataBaseLMS_ru_RU.ts +++ b/GUIdataBaseLMS/translations/GUIdataBaseLMS_ru_RU.ts @@ -4,7 +4,7 @@ MainWindow - + Learning management system (LMS) Система управления обучением (СУО) diff --git a/InstructorsAndTrainees/CMakeLists.txt b/InstructorsAndTrainees/CMakeLists.txt index de03d59..3063048 100644 --- a/InstructorsAndTrainees/CMakeLists.txt +++ b/InstructorsAndTrainees/CMakeLists.txt @@ -93,9 +93,7 @@ add_library(InstructorsAndTrainees SHARED tasks/dialogchecktask.cpp tasks/dialogchecktask.h tasks/dialogchecktask.ui - #tasks/tasksAmmFim.cpp - #tasks/tasksAmmFim.h - widgets/newversionwidget.cpp + widgets/newversionwidget.cpp widgets/newversionwidget.h widgets/newversionwidget.ui widgets/versionselectwidget.cpp diff --git a/InstructorsAndTrainees/dialogsettings.cpp b/InstructorsAndTrainees/dialogsettings.cpp index 63574e8..cd87ae7 100644 --- a/InstructorsAndTrainees/dialogsettings.cpp +++ b/InstructorsAndTrainees/dialogsettings.cpp @@ -58,12 +58,6 @@ DialogSettings::DialogSettings(ConnectorToServer* connectorToServer, bool instru if(connectorToServer) if(connectorToServer->getIsConnected()) { - /* - ui->editAddress->setEnabled(false); - ui->editPort->setEnabled(false); - ui->checkAutoStart->setEnabled(false); - */ - if(instructorIsLogged) ui->btnSetVersion->setEnabled(true); } @@ -73,14 +67,6 @@ DialogSettings::DialogSettings(ConnectorToServer* connectorToServer, bool instru ui->btnSave->setEnabled(false); flSettingsServerChanged = false; - - /* - if(settings->Language == "ENG") - qtLanguageTranslator.load(QString("translations/InstructorsAndTraineesWidget_") + "en_EN", "."); - else - qtLanguageTranslator.load(QString("translations/InstructorsAndTraineesWidget_") + "ru_RU", "."); - qApp->installTranslator(&qtLanguageTranslator); - */ } DialogSettings::~DialogSettings() @@ -103,11 +89,6 @@ void DialogSettings::changeEvent(QEvent *event) } } -void DialogSettings::on_cmbLanguage_currentIndexChanged(const QString &arg1) -{ - -} - void DialogSettings::on_btnUpdateStyle_clicked() { emit signal_UpdateStyleSheet(); @@ -207,22 +188,9 @@ void DialogSettings::on_btnSave_clicked() saveSettings(); - /* - QString language; - - if(settings->Language == "ENG") - language = QString("en_EN"); - else - language = QString("ru_RU"); - - emit signal_LanguageChanged(language); - */ - this->accept(); } - - void DialogSettings::on_btnSetVersion_clicked() { if(connectorToServer) @@ -247,11 +215,6 @@ void DialogSettings::on_editPort_textChanged(const QString &arg1) flSettingsServerChanged = true; } -void DialogSettings::on_DialogSettings_rejected() -{ - -} - void DialogSettings::on_DialogSettings_accepted() { QString language; diff --git a/InstructorsAndTrainees/dialogsettings.h b/InstructorsAndTrainees/dialogsettings.h index dad39cd..b77839c 100644 --- a/InstructorsAndTrainees/dialogsettings.h +++ b/InstructorsAndTrainees/dialogsettings.h @@ -35,21 +35,12 @@ signals: void signal_UpdateStyleSheet(); private slots: - void on_cmbLanguage_currentIndexChanged(const QString &arg1); void on_btnUpdateStyle_clicked(); - void on_btnSave_clicked(); - - void on_DialogSettings_rejected(); - void on_btnSetVersion_clicked(); - void on_cmbLanguage_currentIndexChanged(int index); - void on_editAddress_textChanged(const QString &arg1); - void on_editPort_textChanged(const QString &arg1); - void on_DialogSettings_accepted(); private: diff --git a/InstructorsAndTrainees/dialogsettings.ui b/InstructorsAndTrainees/dialogsettings.ui index a4837a2..e10a6bb 100644 --- a/InstructorsAndTrainees/dialogsettings.ui +++ b/InstructorsAndTrainees/dialogsettings.ui @@ -46,7 +46,7 @@ - + Language diff --git a/InstructorsAndTrainees/instructors/editorinstructors.cpp b/InstructorsAndTrainees/instructors/editorinstructors.cpp index dd8fb02..cda5dd2 100644 --- a/InstructorsAndTrainees/instructors/editorinstructors.cpp +++ b/InstructorsAndTrainees/instructors/editorinstructors.cpp @@ -9,6 +9,10 @@ EditorInstructors::EditorInstructors(ConnectorToServer* connectorToServer, bool { ui->setupUi(this); + ui->btnDeleteInstructor->setEnabled(false); + ui->btnToOrFromArchive->setEnabled(false); + ui->btnEdit->setEnabled(false); + connect(treeWidget, &QTreeWidget::currentItemChanged, this, &EditorInstructors::on_treeWidget_currentItemChanged); ui->verticalLayout_1->addWidget(treeWidget); diff --git a/InstructorsAndTrainees/instructors/viewerinstructors.cpp b/InstructorsAndTrainees/instructors/viewerinstructors.cpp index 6b28b32..0990f3e 100644 --- a/InstructorsAndTrainees/instructors/viewerinstructors.cpp +++ b/InstructorsAndTrainees/instructors/viewerinstructors.cpp @@ -88,7 +88,7 @@ void ViewerInstructors::on_treeWidget_itemClicked(QTreeWidgetItem *item, int col lastCurrentID = newCurrentID; - Q_EMIT signal_instructorSelected(login); + Q_EMIT signal_instructorSelected(newCurrentID); } } } diff --git a/InstructorsAndTrainees/instructors/viewerinstructors.h b/InstructorsAndTrainees/instructors/viewerinstructors.h index 145b07e..ec7e43f 100644 --- a/InstructorsAndTrainees/instructors/viewerinstructors.h +++ b/InstructorsAndTrainees/instructors/viewerinstructors.h @@ -37,7 +37,7 @@ public slots: Q_SIGNALS: //сигнал о выборе инструктора - void signal_instructorSelected(QString login); + void signal_instructorSelected(int id_instructor); private: void updateButtons() override; diff --git a/InstructorsAndTrainees/instructorsandtraineeswidget.cpp b/InstructorsAndTrainees/instructorsandtraineeswidget.cpp index de44a81..7f15a9f 100644 --- a/InstructorsAndTrainees/instructorsandtraineeswidget.cpp +++ b/InstructorsAndTrainees/instructorsandtraineeswidget.cpp @@ -5,6 +5,11 @@ #include "dialogauthorizationinstructor.h" #include "dialogsettings.h" + +const QString InstructorsAndTraineesWidget::languageENG = "en_EN"; +const QString InstructorsAndTraineesWidget::languageRUS = "ru_RU"; + + InstructorsAndTraineesWidget::InstructorsAndTraineesWidget(QWidget *parent) : QWidget(parent), connectorToServer(nullptr), @@ -15,18 +20,13 @@ InstructorsAndTraineesWidget::InstructorsAndTraineesWidget(QWidget *parent) : adminMode(false), loginInstructorLoggedInLocal(QStringLiteral("")), nameInstructorLoggedInLocal(QStringLiteral("")), - language("ENG"), + idInstructorLoggedInLocal("0"), + language(languageENG), ui(new Ui::InstructorsAndTraineesWidget) { ui->setupUi(this); - ui->btnSettings->setObjectName("btnSettings"); - ui->widget_Control->setObjectName("widgetTop"); - ui->groupBox_Trainees->setObjectName("groupBox_Trainees"); - - #ifndef PROJECT_TYPE_DEBUG - //ui->btnUpdateStyleSheet->setVisible(false); - #endif + ui->widget_Control->setObjectName("widgetControl"); registerMetaType(); @@ -37,8 +37,8 @@ InstructorsAndTraineesWidget::InstructorsAndTraineesWidget(QWidget *parent) : setLanguageInterfase(); connectorToServer = new ConnectorToServer(this); - connect(connectorToServer,&ConnectorToServer::sigLoginResult,this,&InstructorsAndTraineesWidget::slot_checkLoginResult); - connect(connectorToServer,&ConnectorToServer::sigDeLoginResult,this,&InstructorsAndTraineesWidget::slot_checkDeLoginResult); + connect(connectorToServer, &ConnectorToServer::sigLoginResult, this, &InstructorsAndTraineesWidget::slot_checkLoginResult); + connect(connectorToServer, &ConnectorToServer::sigDeLoginResult, this, &InstructorsAndTraineesWidget::slot_checkDeLoginResult); messangerController = new MessangerController(connectorToServer, this); @@ -49,12 +49,11 @@ InstructorsAndTraineesWidget::InstructorsAndTraineesWidget(QWidget *parent) : connect(viewerInstructors, &ViewerInstructors::signal_BlockAutorization, this, &InstructorsAndTraineesWidget::signal_BlockAutorization); connect(viewerTrainees, &ViewerTrainees::signal_BlockAutorization, this, &InstructorsAndTraineesWidget::signal_BlockAutorization); - connect(connectorToServer,&ConnectorToServer::signal_ConnectedToServer,this,&InstructorsAndTraineesWidget::slot_ConnectedToServer); + connect(connectorToServer, &ConnectorToServer::signal_ConnectedToServer, this, &InstructorsAndTraineesWidget::slot_ConnectedToServer); connect(viewerTrainees, &ViewerTrainees::signal_traineeSelected, this, &InstructorsAndTraineesWidget::slot_traineeSelected); connect(viewerInstructors, &ViewerInstructors::signal_instructorSelected, this, &InstructorsAndTraineesWidget::slot_instructorSelected); - viewerTrainees->clearSelection(); viewerInstructors->clearSelection(); @@ -62,7 +61,7 @@ InstructorsAndTraineesWidget::InstructorsAndTraineesWidget(QWidget *parent) : ui->verticalLayout_Trainees->addWidget(viewerTrainees); ui->verticalLayout_Instructors->addWidget(viewerInstructors); - ui->groupBox_Messenger->setMinimumHeight(500); + ui->groupBox_Messenger->setMinimumHeight(900); ui->groupBox_Messenger->setMaximumWidth(500); ui->groupBox_Messenger->setMinimumWidth(500); @@ -94,6 +93,11 @@ InstructorsAndTraineesWidget::~InstructorsAndTraineesWidget() delete ui; } +QString InstructorsAndTraineesWidget::getLanguage() +{ + return language; +} + void InstructorsAndTraineesWidget::changeEvent(QEvent *event) { // В случае получения события изменения языка приложения @@ -114,11 +118,6 @@ void InstructorsAndTraineesWidget::updateMyStyleSheet() this->setStyleSheet(styleSheet); } -QString InstructorsAndTraineesWidget::getLanguage() -{ - return language; -} - QString InstructorsAndTraineesWidget::loadStyleSheet() { QString fileName = "./resources/css/styleSheetMain.css"; @@ -177,6 +176,7 @@ void InstructorsAndTraineesWidget::slot_checkLoginResult(ServerAuthorization *se updateLabelLoggedInInstructor(serverAuth->Login, serverAuth->ClientName); connectorToServer->setLoginName(nameInstructorLoggedInLocal); + messangerController->setGUIclientId(serverAuth->Id); connectorToServer->sendQueryTasksXML("fim"); @@ -252,33 +252,33 @@ void InstructorsAndTraineesWidget::slot_ConnectedToServer(bool state) updateLabelLoggedInInstructor(loginInstructorLoggedInLocal, nameInstructorLoggedInLocal); updateLabelServer(); - QMessageBox::warning(this, tr("Warning!"), tr("The server is disabled")); + QMessageBox::warning(this, tr("Warning!"), tr("The server is not available")); } } -void InstructorsAndTraineesWidget::slot_traineeSelected(QString login) +void InstructorsAndTraineesWidget::slot_traineeSelected(int id_trainee) { viewerInstructors->clearSelection(); - /* Messanger*/ + /*Messanger*/ messangerController->deleteWidget(messangerWidget); - if(login != "") + if(id_trainee) { - Trainee trainee = connectorToServer->getTrainee(connectorToServer->getIdTraineeByLogin(login)); + Trainee trainee = connectorToServer->getTrainee(id_trainee); if(trainee.getID()) messangerWidget = messangerController->newWidget(this, &trainee, ui->verticalLayout_Messenger); } } -void InstructorsAndTraineesWidget::slot_instructorSelected(QString login) +void InstructorsAndTraineesWidget::slot_instructorSelected(int id_instructor) { viewerTrainees->clearSelection(); - /* Messanger*/ + /*Messanger*/ messangerController->deleteWidget(messangerWidget); - if(login != "" && login != loginInstructorLoggedInLocal) + if(id_instructor && id_instructor != idInstructorLoggedInLocal.toInt()) { - Instructor instructor = connectorToServer->getInstructor(connectorToServer->getIdInstructorByLogin(login)); + Instructor instructor = connectorToServer->getInstructor(id_instructor); if(instructor.getID()) messangerWidget = messangerController->newWidget(this, &instructor, ui->verticalLayout_Messenger); } @@ -407,13 +407,13 @@ void InstructorsAndTraineesWidget::setLanguageInterfase() if(settings.Language == "ENG") { - qtLanguageTranslator.load(QString("translations/InstructorsAndTraineesWidget_") + "en_EN", "."); - language = "en_EN"; + qtLanguageTranslator.load(QString("translations/InstructorsAndTraineesWidget_") + languageENG, "."); + language = languageENG; } else { - qtLanguageTranslator.load(QString("translations/InstructorsAndTraineesWidget_") + "ru_RU", "."); - language = "ru_RU"; + qtLanguageTranslator.load(QString("translations/InstructorsAndTraineesWidget_") + languageRUS, "."); + language = languageRUS; } qApp->installTranslator(&qtLanguageTranslator); diff --git a/InstructorsAndTrainees/instructorsandtraineeswidget.h b/InstructorsAndTrainees/instructorsandtraineeswidget.h index 96dcab0..9b0f15f 100644 --- a/InstructorsAndTrainees/instructorsandtraineeswidget.h +++ b/InstructorsAndTrainees/instructorsandtraineeswidget.h @@ -24,14 +24,18 @@ public: explicit InstructorsAndTraineesWidget(QWidget *parent = nullptr); ~InstructorsAndTraineesWidget(); -private: - void changeEvent(QEvent * event) override; +public: + static const QString languageENG; + static const QString languageRUS; public: - void updateMyStyleSheet(); QString getLanguage(); private: + void changeEvent(QEvent * event) override; + +private: + void updateMyStyleSheet(); QString loadStyleSheet(); public Q_SLOTS: @@ -40,7 +44,6 @@ public Q_SLOTS: //Слот обработки смены стиля void slot_UpdateStyleSheet(); - //Слот обработки результата авторизации void slot_checkLoginResult(ServerAuthorization * serverAuth); //Слот обработки результата деавторизации @@ -48,8 +51,8 @@ public Q_SLOTS: //Слот обработки результата подключения к серверу void slot_ConnectedToServer(bool state); - void slot_traineeSelected(QString login); - void slot_instructorSelected(QString login); + void slot_traineeSelected(int id_trainee); + void slot_instructorSelected(int id_instructor); Q_SIGNALS: //сигнал смены языка diff --git a/InstructorsAndTrainees/instructorsandtraineeswidget.ui b/InstructorsAndTrainees/instructorsandtraineeswidget.ui index 287b6df..f2552b8 100644 --- a/InstructorsAndTrainees/instructorsandtraineeswidget.ui +++ b/InstructorsAndTrainees/instructorsandtraineeswidget.ui @@ -108,7 +108,7 @@ - Editor Trainees + Trainee editor @@ -134,7 +134,7 @@ - Editor Instructors + Instructor editor @@ -258,7 +258,7 @@ - Messenger + Chat diff --git a/InstructorsAndTrainees/messanger/messangerwidget.ui b/InstructorsAndTrainees/messanger/messangerwidget.ui index 7f1338f..992ac38 100644 --- a/InstructorsAndTrainees/messanger/messangerwidget.ui +++ b/InstructorsAndTrainees/messanger/messangerwidget.ui @@ -66,7 +66,7 @@ - + 0 0 @@ -74,13 +74,13 @@ 0 - 54 + 0 16777215 - 54 + 16777215 @@ -90,7 +90,7 @@ - + 0 0 @@ -104,7 +104,7 @@ 1000 - 54 + 1000 diff --git a/InstructorsAndTrainees/resources.qrc b/InstructorsAndTrainees/resources.qrc index b9fa69d..d7c0f33 100644 --- a/InstructorsAndTrainees/resources.qrc +++ b/InstructorsAndTrainees/resources.qrc @@ -1,6 +1,5 @@ - resources/css/styleSheetMain.css resources/icons/addInstructor.png resources/icons/addTrainee.png resources/icons/admin.png @@ -27,7 +26,6 @@ resources/icons/instructorArchive.png resources/icons/instructorFromArchive.png resources/icons/login-user.png - resources/icons/messengerPrint.png resources/icons/newGroup.png resources/icons/rectGray.png resources/icons/rectGreen.png @@ -37,7 +35,6 @@ resources/icons/traineeFromArchive.png resources/icons/vline.png resources/icons/sign.png - resources/icons/task.png resources/icons/procedure.png resources/icons/malfunction.png resources/icons/762.gif diff --git a/InstructorsAndTrainees/resources/icons/DB-instructors.png b/InstructorsAndTrainees/resources/icons/DB-instructors.png index c1cdab5..8996b78 100644 Binary files a/InstructorsAndTrainees/resources/icons/DB-instructors.png and b/InstructorsAndTrainees/resources/icons/DB-instructors.png differ diff --git a/InstructorsAndTrainees/resources/icons/DB-trainees.png b/InstructorsAndTrainees/resources/icons/DB-trainees.png index 9688ebf..73d9276 100644 Binary files a/InstructorsAndTrainees/resources/icons/DB-trainees.png and b/InstructorsAndTrainees/resources/icons/DB-trainees.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/DB-instructors.png b/InstructorsAndTrainees/resources/icons/PNG32/DB-instructors.png new file mode 100644 index 0000000..8996b78 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/DB-instructors.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/DB-trainees.png b/InstructorsAndTrainees/resources/icons/PNG32/DB-trainees.png new file mode 100644 index 0000000..73d9276 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/DB-trainees.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/addInstructor.png b/InstructorsAndTrainees/resources/icons/PNG32/addInstructor.png new file mode 100644 index 0000000..5fd6fab Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/addInstructor.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/addTrainee.png b/InstructorsAndTrainees/resources/icons/PNG32/addTrainee.png new file mode 100644 index 0000000..a50008d Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/addTrainee.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/admin.png b/InstructorsAndTrainees/resources/icons/PNG32/admin.png new file mode 100644 index 0000000..558f0ac Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/admin.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/archive.png b/InstructorsAndTrainees/resources/icons/PNG32/archive.png new file mode 100644 index 0000000..b39b27e Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/archive.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/assignTask.png b/InstructorsAndTrainees/resources/icons/PNG32/assignTask.png new file mode 100644 index 0000000..ae8b318 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/assignTask.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/check.png b/InstructorsAndTrainees/resources/icons/PNG32/check.png new file mode 100644 index 0000000..f787975 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/check.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/chekNo.png b/InstructorsAndTrainees/resources/icons/PNG32/chekNo.png new file mode 100644 index 0000000..ce6a024 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/chekNo.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/chekYes.png b/InstructorsAndTrainees/resources/icons/PNG32/chekYes.png new file mode 100644 index 0000000..9a873d8 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/chekYes.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/circleGray.png b/InstructorsAndTrainees/resources/icons/PNG32/circleGray.png new file mode 100644 index 0000000..74c2897 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/circleGray.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/circleGreen.png b/InstructorsAndTrainees/resources/icons/PNG32/circleGreen.png new file mode 100644 index 0000000..62281b1 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/circleGreen.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/circleRed.png b/InstructorsAndTrainees/resources/icons/PNG32/circleRed.png new file mode 100644 index 0000000..9f4f1cb Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/circleRed.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/circleYellow.png b/InstructorsAndTrainees/resources/icons/PNG32/circleYellow.png new file mode 100644 index 0000000..8387806 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/circleYellow.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/connectDB.png b/InstructorsAndTrainees/resources/icons/PNG32/connectDB.png new file mode 100644 index 0000000..5c08aa7 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/connectDB.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/delete.png b/InstructorsAndTrainees/resources/icons/PNG32/delete.png new file mode 100644 index 0000000..12329f3 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/delete.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/deleteGroup.png b/InstructorsAndTrainees/resources/icons/PNG32/deleteGroup.png new file mode 100644 index 0000000..4452b08 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/deleteGroup.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/deleteInstructor.png b/InstructorsAndTrainees/resources/icons/PNG32/deleteInstructor.png new file mode 100644 index 0000000..c70395c Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/deleteInstructor.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/deleteTrainee.png b/InstructorsAndTrainees/resources/icons/PNG32/deleteTrainee.png new file mode 100644 index 0000000..dd93bf5 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/deleteTrainee.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/docTasks.png b/InstructorsAndTrainees/resources/icons/PNG32/docTasks.png new file mode 100644 index 0000000..305643b Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/docTasks.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/edit.png b/InstructorsAndTrainees/resources/icons/PNG32/edit.png new file mode 100644 index 0000000..6ac18f9 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/edit.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/editorDB.png b/InstructorsAndTrainees/resources/icons/PNG32/editorDB.png new file mode 100644 index 0000000..bb4ab4e Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/editorDB.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/filter.png b/InstructorsAndTrainees/resources/icons/PNG32/filter.png new file mode 100644 index 0000000..0efea9e Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/filter.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/group.png b/InstructorsAndTrainees/resources/icons/PNG32/group.png new file mode 100644 index 0000000..3da48ed Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/group.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/instructor.png b/InstructorsAndTrainees/resources/icons/PNG32/instructor.png new file mode 100644 index 0000000..a4e53b4 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/instructor.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/instructorAdmin.png b/InstructorsAndTrainees/resources/icons/PNG32/instructorAdmin.png new file mode 100644 index 0000000..e66570e Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/instructorAdmin.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/instructorArchive.png b/InstructorsAndTrainees/resources/icons/PNG32/instructorArchive.png new file mode 100644 index 0000000..9628923 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/instructorArchive.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/instructorFromArchive.png b/InstructorsAndTrainees/resources/icons/PNG32/instructorFromArchive.png new file mode 100644 index 0000000..8d43280 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/instructorFromArchive.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/lms.png b/InstructorsAndTrainees/resources/icons/PNG32/lms.png new file mode 100644 index 0000000..242868e Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/lms.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/login-user.png b/InstructorsAndTrainees/resources/icons/PNG32/login-user.png new file mode 100644 index 0000000..05b2207 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/login-user.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/malfunction.png b/InstructorsAndTrainees/resources/icons/PNG32/malfunction.png new file mode 100644 index 0000000..6f8e275 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/malfunction.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/newGroup.png b/InstructorsAndTrainees/resources/icons/PNG32/newGroup.png new file mode 100644 index 0000000..213f790 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/newGroup.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/rectGray.png b/InstructorsAndTrainees/resources/icons/PNG32/rectGray.png new file mode 100644 index 0000000..3ec08f9 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/rectGray.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/rectGreen.png b/InstructorsAndTrainees/resources/icons/PNG32/rectGreen.png new file mode 100644 index 0000000..2d14d43 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/rectGreen.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/sendMsg.png b/InstructorsAndTrainees/resources/icons/PNG32/sendMsg.png new file mode 100644 index 0000000..1d3c646 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/sendMsg.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/settings.png b/InstructorsAndTrainees/resources/icons/PNG32/settings.png new file mode 100644 index 0000000..07376fe Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/settings.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/sign.png b/InstructorsAndTrainees/resources/icons/PNG32/sign.png new file mode 100644 index 0000000..62aafba Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/sign.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/style.png b/InstructorsAndTrainees/resources/icons/PNG32/style.png new file mode 100644 index 0000000..fabf25f Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/style.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/task.png b/InstructorsAndTrainees/resources/icons/PNG32/task.png new file mode 100644 index 0000000..db4f605 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/task.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/trainee.png b/InstructorsAndTrainees/resources/icons/PNG32/trainee.png new file mode 100644 index 0000000..59cad37 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/trainee.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/traineeArchive.png b/InstructorsAndTrainees/resources/icons/PNG32/traineeArchive.png new file mode 100644 index 0000000..2c50f59 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/traineeArchive.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/traineeFromArchive.png b/InstructorsAndTrainees/resources/icons/PNG32/traineeFromArchive.png new file mode 100644 index 0000000..b63f7a6 Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/traineeFromArchive.png differ diff --git a/InstructorsAndTrainees/resources/icons/PNG32/updateVersion.png b/InstructorsAndTrainees/resources/icons/PNG32/updateVersion.png new file mode 100644 index 0000000..1e4963d Binary files /dev/null and b/InstructorsAndTrainees/resources/icons/PNG32/updateVersion.png differ diff --git a/InstructorsAndTrainees/resources/icons/addInstructor.png b/InstructorsAndTrainees/resources/icons/addInstructor.png index 9436c63..5fd6fab 100644 Binary files a/InstructorsAndTrainees/resources/icons/addInstructor.png and b/InstructorsAndTrainees/resources/icons/addInstructor.png differ diff --git a/InstructorsAndTrainees/resources/icons/addTrainee.png b/InstructorsAndTrainees/resources/icons/addTrainee.png index 7693478..a50008d 100644 Binary files a/InstructorsAndTrainees/resources/icons/addTrainee.png and b/InstructorsAndTrainees/resources/icons/addTrainee.png differ diff --git a/InstructorsAndTrainees/resources/icons/admin.png b/InstructorsAndTrainees/resources/icons/admin.png index 66959ba..558f0ac 100644 Binary files a/InstructorsAndTrainees/resources/icons/admin.png and b/InstructorsAndTrainees/resources/icons/admin.png differ diff --git a/InstructorsAndTrainees/resources/icons/archive.png b/InstructorsAndTrainees/resources/icons/archive.png index 0b98e02..b39b27e 100644 Binary files a/InstructorsAndTrainees/resources/icons/archive.png and b/InstructorsAndTrainees/resources/icons/archive.png differ diff --git a/InstructorsAndTrainees/resources/icons/assignTask.png b/InstructorsAndTrainees/resources/icons/assignTask.png index cd87789..ae8b318 100644 Binary files a/InstructorsAndTrainees/resources/icons/assignTask.png and b/InstructorsAndTrainees/resources/icons/assignTask.png differ diff --git a/InstructorsAndTrainees/resources/icons/check.png b/InstructorsAndTrainees/resources/icons/check.png index 3163b36..f787975 100644 Binary files a/InstructorsAndTrainees/resources/icons/check.png and b/InstructorsAndTrainees/resources/icons/check.png differ diff --git a/InstructorsAndTrainees/resources/icons/chekNo.png b/InstructorsAndTrainees/resources/icons/chekNo.png index 85940d2..ce6a024 100644 Binary files a/InstructorsAndTrainees/resources/icons/chekNo.png and b/InstructorsAndTrainees/resources/icons/chekNo.png differ diff --git a/InstructorsAndTrainees/resources/icons/chekYes.png b/InstructorsAndTrainees/resources/icons/chekYes.png index 05c86d1..9a873d8 100644 Binary files a/InstructorsAndTrainees/resources/icons/chekYes.png and b/InstructorsAndTrainees/resources/icons/chekYes.png differ diff --git a/InstructorsAndTrainees/resources/icons/circleGray.png b/InstructorsAndTrainees/resources/icons/circleGray.png index c2cf426..74c2897 100644 Binary files a/InstructorsAndTrainees/resources/icons/circleGray.png and b/InstructorsAndTrainees/resources/icons/circleGray.png differ diff --git a/InstructorsAndTrainees/resources/icons/circleGreen.png b/InstructorsAndTrainees/resources/icons/circleGreen.png index bcbce3d..62281b1 100644 Binary files a/InstructorsAndTrainees/resources/icons/circleGreen.png and b/InstructorsAndTrainees/resources/icons/circleGreen.png differ diff --git a/InstructorsAndTrainees/resources/icons/circleRed.png b/InstructorsAndTrainees/resources/icons/circleRed.png index 9be2b42..9f4f1cb 100644 Binary files a/InstructorsAndTrainees/resources/icons/circleRed.png and b/InstructorsAndTrainees/resources/icons/circleRed.png differ diff --git a/InstructorsAndTrainees/resources/icons/circleYellow.png b/InstructorsAndTrainees/resources/icons/circleYellow.png index 3ad6b3b..8387806 100644 Binary files a/InstructorsAndTrainees/resources/icons/circleYellow.png and b/InstructorsAndTrainees/resources/icons/circleYellow.png differ diff --git a/InstructorsAndTrainees/resources/icons/connectDB.png b/InstructorsAndTrainees/resources/icons/connectDB.png index 76f8737..5c08aa7 100644 Binary files a/InstructorsAndTrainees/resources/icons/connectDB.png and b/InstructorsAndTrainees/resources/icons/connectDB.png differ diff --git a/InstructorsAndTrainees/resources/icons/delete.png b/InstructorsAndTrainees/resources/icons/delete.png index 1abb5de..12329f3 100644 Binary files a/InstructorsAndTrainees/resources/icons/delete.png and b/InstructorsAndTrainees/resources/icons/delete.png differ diff --git a/InstructorsAndTrainees/resources/icons/deleteGroup.png b/InstructorsAndTrainees/resources/icons/deleteGroup.png index a8cb2b9..4452b08 100644 Binary files a/InstructorsAndTrainees/resources/icons/deleteGroup.png and b/InstructorsAndTrainees/resources/icons/deleteGroup.png differ diff --git a/InstructorsAndTrainees/resources/icons/deleteInstructor.png b/InstructorsAndTrainees/resources/icons/deleteInstructor.png index 99c6196..c70395c 100644 Binary files a/InstructorsAndTrainees/resources/icons/deleteInstructor.png and b/InstructorsAndTrainees/resources/icons/deleteInstructor.png differ diff --git a/InstructorsAndTrainees/resources/icons/deleteTrainee.png b/InstructorsAndTrainees/resources/icons/deleteTrainee.png index fd2c6dd..dd93bf5 100644 Binary files a/InstructorsAndTrainees/resources/icons/deleteTrainee.png and b/InstructorsAndTrainees/resources/icons/deleteTrainee.png differ diff --git a/InstructorsAndTrainees/resources/icons/docTasks.png b/InstructorsAndTrainees/resources/icons/docTasks.png index 6c9248d..305643b 100644 Binary files a/InstructorsAndTrainees/resources/icons/docTasks.png and b/InstructorsAndTrainees/resources/icons/docTasks.png differ diff --git a/InstructorsAndTrainees/resources/icons/edit.png b/InstructorsAndTrainees/resources/icons/edit.png index bc05807..6ac18f9 100644 Binary files a/InstructorsAndTrainees/resources/icons/edit.png and b/InstructorsAndTrainees/resources/icons/edit.png differ diff --git a/InstructorsAndTrainees/resources/icons/editorDB.png b/InstructorsAndTrainees/resources/icons/editorDB.png index c701ab6..bb4ab4e 100644 Binary files a/InstructorsAndTrainees/resources/icons/editorDB.png and b/InstructorsAndTrainees/resources/icons/editorDB.png differ diff --git a/InstructorsAndTrainees/resources/icons/filter.png b/InstructorsAndTrainees/resources/icons/filter.png index 7f4e679..0efea9e 100644 Binary files a/InstructorsAndTrainees/resources/icons/filter.png and b/InstructorsAndTrainees/resources/icons/filter.png differ diff --git a/InstructorsAndTrainees/resources/icons/group.png b/InstructorsAndTrainees/resources/icons/group.png index 01e0d9e..3da48ed 100644 Binary files a/InstructorsAndTrainees/resources/icons/group.png and b/InstructorsAndTrainees/resources/icons/group.png differ diff --git a/InstructorsAndTrainees/resources/icons/instructor.png b/InstructorsAndTrainees/resources/icons/instructor.png index cc448f2..a4e53b4 100644 Binary files a/InstructorsAndTrainees/resources/icons/instructor.png and b/InstructorsAndTrainees/resources/icons/instructor.png differ diff --git a/InstructorsAndTrainees/resources/icons/instructorAdmin.png b/InstructorsAndTrainees/resources/icons/instructorAdmin.png index c9d18ff..e66570e 100644 Binary files a/InstructorsAndTrainees/resources/icons/instructorAdmin.png and b/InstructorsAndTrainees/resources/icons/instructorAdmin.png differ diff --git a/InstructorsAndTrainees/resources/icons/instructorArchive.png b/InstructorsAndTrainees/resources/icons/instructorArchive.png index 3f0cb65..9628923 100644 Binary files a/InstructorsAndTrainees/resources/icons/instructorArchive.png and b/InstructorsAndTrainees/resources/icons/instructorArchive.png differ diff --git a/InstructorsAndTrainees/resources/icons/instructorFromArchive.png b/InstructorsAndTrainees/resources/icons/instructorFromArchive.png index f861ebf..8d43280 100644 Binary files a/InstructorsAndTrainees/resources/icons/instructorFromArchive.png and b/InstructorsAndTrainees/resources/icons/instructorFromArchive.png differ diff --git a/InstructorsAndTrainees/resources/icons/lms.png b/InstructorsAndTrainees/resources/icons/lms.png index c3c244e..242868e 100644 Binary files a/InstructorsAndTrainees/resources/icons/lms.png and b/InstructorsAndTrainees/resources/icons/lms.png differ diff --git a/InstructorsAndTrainees/resources/icons/login-user.png b/InstructorsAndTrainees/resources/icons/login-user.png index 68b3674..05b2207 100644 Binary files a/InstructorsAndTrainees/resources/icons/login-user.png and b/InstructorsAndTrainees/resources/icons/login-user.png differ diff --git a/InstructorsAndTrainees/resources/icons/messengerPrint.png b/InstructorsAndTrainees/resources/icons/messengerPrint.png deleted file mode 100644 index d6b8bd9..0000000 Binary files a/InstructorsAndTrainees/resources/icons/messengerPrint.png and /dev/null differ diff --git a/InstructorsAndTrainees/resources/icons/newGroup.png b/InstructorsAndTrainees/resources/icons/newGroup.png index 9fa9a5a..213f790 100644 Binary files a/InstructorsAndTrainees/resources/icons/newGroup.png and b/InstructorsAndTrainees/resources/icons/newGroup.png differ diff --git a/InstructorsAndTrainees/resources/icons/rectGray.png b/InstructorsAndTrainees/resources/icons/rectGray.png index 85940d2..3ec08f9 100644 Binary files a/InstructorsAndTrainees/resources/icons/rectGray.png and b/InstructorsAndTrainees/resources/icons/rectGray.png differ diff --git a/InstructorsAndTrainees/resources/icons/rectGreen.png b/InstructorsAndTrainees/resources/icons/rectGreen.png index ad00eb8..2d14d43 100644 Binary files a/InstructorsAndTrainees/resources/icons/rectGreen.png and b/InstructorsAndTrainees/resources/icons/rectGreen.png differ diff --git a/InstructorsAndTrainees/resources/icons/sendMsg.png b/InstructorsAndTrainees/resources/icons/sendMsg.png index 783f67b..1d3c646 100644 Binary files a/InstructorsAndTrainees/resources/icons/sendMsg.png and b/InstructorsAndTrainees/resources/icons/sendMsg.png differ diff --git a/InstructorsAndTrainees/resources/icons/settings.png b/InstructorsAndTrainees/resources/icons/settings.png index 91dfee9..07376fe 100644 Binary files a/InstructorsAndTrainees/resources/icons/settings.png and b/InstructorsAndTrainees/resources/icons/settings.png differ diff --git a/InstructorsAndTrainees/resources/icons/sign.png b/InstructorsAndTrainees/resources/icons/sign.png index 842ee2d..62aafba 100644 Binary files a/InstructorsAndTrainees/resources/icons/sign.png and b/InstructorsAndTrainees/resources/icons/sign.png differ diff --git a/InstructorsAndTrainees/resources/icons/style.png b/InstructorsAndTrainees/resources/icons/style.png index 05e9621..fabf25f 100644 Binary files a/InstructorsAndTrainees/resources/icons/style.png and b/InstructorsAndTrainees/resources/icons/style.png differ diff --git a/InstructorsAndTrainees/resources/icons/task.png b/InstructorsAndTrainees/resources/icons/task.png index 5a4ae16..db4f605 100644 Binary files a/InstructorsAndTrainees/resources/icons/task.png and b/InstructorsAndTrainees/resources/icons/task.png differ diff --git a/InstructorsAndTrainees/resources/icons/trainee.png b/InstructorsAndTrainees/resources/icons/trainee.png index 18d434e..59cad37 100644 Binary files a/InstructorsAndTrainees/resources/icons/trainee.png and b/InstructorsAndTrainees/resources/icons/trainee.png differ diff --git a/InstructorsAndTrainees/resources/icons/traineeArchive.png b/InstructorsAndTrainees/resources/icons/traineeArchive.png index 91ffb87..2c50f59 100644 Binary files a/InstructorsAndTrainees/resources/icons/traineeArchive.png and b/InstructorsAndTrainees/resources/icons/traineeArchive.png differ diff --git a/InstructorsAndTrainees/resources/icons/traineeFromArchive.png b/InstructorsAndTrainees/resources/icons/traineeFromArchive.png index 9ce07dd..b63f7a6 100644 Binary files a/InstructorsAndTrainees/resources/icons/traineeFromArchive.png and b/InstructorsAndTrainees/resources/icons/traineeFromArchive.png differ diff --git a/InstructorsAndTrainees/resources/icons/updateVersion.png b/InstructorsAndTrainees/resources/icons/updateVersion.png index f6c46fb..1e4963d 100644 Binary files a/InstructorsAndTrainees/resources/icons/updateVersion.png and b/InstructorsAndTrainees/resources/icons/updateVersion.png differ diff --git a/InstructorsAndTrainees/tasks/ammtaskswidget.cpp b/InstructorsAndTrainees/tasks/ammtaskswidget.cpp index 5cb27c1..14af6e4 100644 --- a/InstructorsAndTrainees/tasks/ammtaskswidget.cpp +++ b/InstructorsAndTrainees/tasks/ammtaskswidget.cpp @@ -14,7 +14,6 @@ AMMtasksWidget::AMMtasksWidget(ConnectorToServer* connectorToServer, TypeListTre connectorToServer(connectorToServer), treeWidget(nullptr), type(type), - loginTraineeSelected(""), idTraineeSelected(0), threadPreparation(nullptr), taskTreePreparation(nullptr), @@ -101,7 +100,6 @@ void AMMtasksWidget::deactivate() ui->btnAssignTask->setEnabled(false); ui->btnOnlyActive->setEnabled(false); treeWidget->clear(); - loginTraineeSelected = ""; idTraineeSelected = 0; } @@ -177,11 +175,11 @@ void AMMtasksWidget::slot_NeedUpdateUI() loadTasksAMM(); } -void AMMtasksWidget::slot_traineeSelected(QString login) +void AMMtasksWidget::slot_traineeSelected(int id_trainee) { qDebug() << "AMMtasksWidget::slot_traineeSelected thread ID " << QThread::currentThreadId(); - loginTraineeSelected = login; - idTraineeSelected = connectorToServer->getIdTraineeByLogin(loginTraineeSelected); + + idTraineeSelected = id_trainee; if(type == TypeListTreeAMMFIM::listForTrainee) { @@ -276,10 +274,8 @@ void AMMtasksWidget::assignTaskAMMtoTrainee() if(taskNew.getID()) { - int trainee_id = connectorToServer->getIdTraineeByLogin(loginTraineeSelected); - emit signal_AssignedTask(); - connectorToServer->sendQueryToDB(TypeQueryToDB::TYPE_QUERY_ASSIGN_TASK_AMM_TO_TRAINEE, trainee_id, &taskNew); + connectorToServer->sendQueryToDB(TypeQueryToDB::TYPE_QUERY_ASSIGN_TASK_AMM_TO_TRAINEE, idTraineeSelected, &taskNew); } } diff --git a/InstructorsAndTrainees/tasks/ammtaskswidget.h b/InstructorsAndTrainees/tasks/ammtaskswidget.h index a8c1113..cdd7283 100644 --- a/InstructorsAndTrainees/tasks/ammtaskswidget.h +++ b/InstructorsAndTrainees/tasks/ammtaskswidget.h @@ -41,7 +41,7 @@ public Q_SLOTS: //Слот обработки сигнала необходимости обновления интерфейса void slot_NeedUpdateUI(); //слот обработки сигнала о выборе обучаемого - void slot_traineeSelected(QString login); + void slot_traineeSelected(int id_trainee); void slot_UpdateTasksAMMforTrainee(int trainee_id); @@ -70,7 +70,6 @@ private: QTreeWidget* treeWidget; TypeListTreeAMMFIM type; - QString loginTraineeSelected; int idTraineeSelected; QThread* threadPreparation; diff --git a/InstructorsAndTrainees/tasks/fimtaskswidget.cpp b/InstructorsAndTrainees/tasks/fimtaskswidget.cpp index 74c1a07..e13d405 100644 --- a/InstructorsAndTrainees/tasks/fimtaskswidget.cpp +++ b/InstructorsAndTrainees/tasks/fimtaskswidget.cpp @@ -15,7 +15,6 @@ FIMtasksWidget::FIMtasksWidget(ConnectorToServer* connectorToServer, TypeListTre connectorToServer(connectorToServer), treeWidget(nullptr), type(type), - loginTraineeSelected(""), idTraineeSelected(0), threadPreparation(nullptr), taskTreePreparation(nullptr), @@ -103,7 +102,6 @@ void FIMtasksWidget::deactivate() { ui->btnAssignTask->setEnabled(false); treeWidget->clear(); - loginTraineeSelected = ""; idTraineeSelected = 0; } @@ -204,11 +202,11 @@ void FIMtasksWidget::slot_NeedUpdateUI() loadTasksFIM(); } -void FIMtasksWidget::slot_traineeSelected(QString login) +void FIMtasksWidget::slot_traineeSelected(int id_trainee) { qDebug() << "FIMtasksWidget::slot_traineeSelected thread ID " << QThread::currentThreadId(); - loginTraineeSelected = login; - idTraineeSelected = connectorToServer->getIdTraineeByLogin(loginTraineeSelected); + + idTraineeSelected = id_trainee; if(type == TypeListTreeAMMFIM::listForTrainee) { @@ -306,8 +304,6 @@ void FIMtasksWidget::assignTaskFIMtoTrainee() if(task.getID()) { - int trainee_id = connectorToServer->getIdTraineeByLogin(loginTraineeSelected); - TaskAmmFim taskNew; taskNew.title = task.title; @@ -324,7 +320,7 @@ void FIMtasksWidget::assignTaskFIMtoTrainee() } emit signal_AssignedTask(); - connectorToServer->sendQueryToDB(TypeQueryToDB::TYPE_QUERY_ASSIGN_TASK_FIM_TO_TRAINEE, trainee_id, &taskNew); + connectorToServer->sendQueryToDB(TypeQueryToDB::TYPE_QUERY_ASSIGN_TASK_FIM_TO_TRAINEE, idTraineeSelected, &taskNew); updateTaskItem(current); } diff --git a/InstructorsAndTrainees/tasks/fimtaskswidget.h b/InstructorsAndTrainees/tasks/fimtaskswidget.h index 8e70f25..f8f1d06 100644 --- a/InstructorsAndTrainees/tasks/fimtaskswidget.h +++ b/InstructorsAndTrainees/tasks/fimtaskswidget.h @@ -42,7 +42,7 @@ public Q_SLOTS: //Слот обработки сигнала необходимости обновления интерфейса void slot_NeedUpdateUI(); //слот обработки сигнала о выборе обучаемого - void slot_traineeSelected(QString login); + void slot_traineeSelected(int id_trainee); void slot_UpdateTasksFIMforTrainee(int trainee_id); @@ -72,7 +72,6 @@ private: QTreeWidget* treeWidget; TypeListTreeAMMFIM type; - QString loginTraineeSelected; int idTraineeSelected; QThread* threadPreparation; diff --git a/InstructorsAndTrainees/trainees/personalcardtrainee.cpp b/InstructorsAndTrainees/trainees/personalcardtrainee.cpp index 70c6115..0c1fef8 100644 --- a/InstructorsAndTrainees/trainees/personalcardtrainee.cpp +++ b/InstructorsAndTrainees/trainees/personalcardtrainee.cpp @@ -28,8 +28,8 @@ PersonalCardTrainee::PersonalCardTrainee(ConnectorToServer* connectorToServer, M connect(connectorToServer, &ConnectorToServer::signal_UpdateDB, this, &PersonalCardTrainee::slot_NeedUpdateUI); - fimTasksWidget_personal->slot_traineeSelected(connectorToServer->getTrainee(id_trainee).getLogin()); - ammTasksWidget_personal->slot_traineeSelected(connectorToServer->getTrainee(id_trainee).getLogin()); + fimTasksWidget_personal->slot_traineeSelected(id_trainee); + ammTasksWidget_personal->slot_traineeSelected(id_trainee); ui->verticalLayout_AMMpersonal->addWidget(ammTasksWidget_personal); ui->verticalLayout_FIMpersonal->addWidget(fimTasksWidget_personal); diff --git a/InstructorsAndTrainees/trainees/personalcardtrainee.ui b/InstructorsAndTrainees/trainees/personalcardtrainee.ui index 2ec22b9..c65b532 100644 --- a/InstructorsAndTrainees/trainees/personalcardtrainee.ui +++ b/InstructorsAndTrainees/trainees/personalcardtrainee.ui @@ -165,7 +165,7 @@ - Messenger + Chat diff --git a/InstructorsAndTrainees/trainees/viewertrainees.cpp b/InstructorsAndTrainees/trainees/viewertrainees.cpp index 713d7f4..480a5ac 100644 --- a/InstructorsAndTrainees/trainees/viewertrainees.cpp +++ b/InstructorsAndTrainees/trainees/viewertrainees.cpp @@ -165,7 +165,7 @@ void ViewerTrainees::on_treeWidget_itemClicked(QTreeWidgetItem *item, int column lastCurrentID = newCurrentID; - Q_EMIT signal_traineeSelected(login); + Q_EMIT signal_traineeSelected(newCurrentID); } } else @@ -178,7 +178,7 @@ void ViewerTrainees::on_treeWidget_itemClicked(QTreeWidgetItem *item, int column typeObject = TypeObject::objGroup; QString login = ""; - Q_EMIT signal_traineeSelected(login); + Q_EMIT signal_traineeSelected(0); } } diff --git a/InstructorsAndTrainees/trainees/viewertrainees.h b/InstructorsAndTrainees/trainees/viewertrainees.h index cc79066..ceeca9e 100644 --- a/InstructorsAndTrainees/trainees/viewertrainees.h +++ b/InstructorsAndTrainees/trainees/viewertrainees.h @@ -41,7 +41,7 @@ private Q_SLOTS: Q_SIGNALS: //сигнал о выборе обучаемого - void signal_traineeSelected(QString login); + void signal_traineeSelected(int id_trainee); private: void updateButtons() override; diff --git a/InstructorsAndTrainees/translations/InstructorsAndTraineesWidget_ru_RU.qm b/InstructorsAndTrainees/translations/InstructorsAndTraineesWidget_ru_RU.qm index 85daa08..046b5a2 100644 Binary files a/InstructorsAndTrainees/translations/InstructorsAndTraineesWidget_ru_RU.qm and b/InstructorsAndTrainees/translations/InstructorsAndTraineesWidget_ru_RU.qm differ diff --git a/InstructorsAndTrainees/translations/InstructorsAndTraineesWidget_ru_RU.ts b/InstructorsAndTrainees/translations/InstructorsAndTraineesWidget_ru_RU.ts index 7b9a1ee..84f4f80 100644 --- a/InstructorsAndTrainees/translations/InstructorsAndTraineesWidget_ru_RU.ts +++ b/InstructorsAndTrainees/translations/InstructorsAndTraineesWidget_ru_RU.ts @@ -9,77 +9,69 @@ Форма - + Assign Назначить - + Аvailable Доступные - + Delete Удалить + Task AMM Задача AMM + DM code DM код + - ID ID - + + - Status Статус - - PM/DM - PM/DM - - - - Code - Код - - - + Attention! Внимание! - + The deletion will be irrevocable. Delete it anyway? Удаление будет безвозвратным. Всё равно удалить? - + Status Task Статус задачи - + New task Новая задача - + Assign this task? Назначить эту задачу? @@ -278,8 +270,8 @@ The status will be set: DialogSettings - Learning management system - Settings - Система управления обучением - Настройки + Settings + Настройки @@ -599,66 +591,62 @@ The changes will not be accepted. Форма - + Assign Назначить - + Check Проверить - + Delete Удалить + Task FIM Задача FIM + - ID ID + - Status Статус - - Title - Заголовок - - - + Attention! Внимание! - + The deletion will be irrevocable. Delete it anyway? Удаление будет безвозвратным. Всё равно удалить? - + Check Task Проверка задачи - + New task Новая задача - + Assign this task? Назначить эту задачу? @@ -671,112 +659,107 @@ Delete it anyway? Форма - + Connection Подключение - + Authorization Авторизация - + + Trainee editor + Редактор обучаемых + + + + Instructor editor + Редактор инструкторов + + + + Chat + Чат + + + Server: Сервер: - - Logged in Instructor: - Вошедший в систему инструктор: + + Instructor: + Инструктор: - - ChangeVersion - Изменение версии - - - - Editor Trainees - Редактор Обучаемых - - - - Editor Instructors - Редактор Инструкторов - - - + Settings Настройки - + Trainees Обучаемые - - Messenger - Мессенджер - - - + Instructors Инструкторы - - - - + + + + none нет - - + + Attention! Внимание! - + The file could not be opened Файл не может быть открыт - + Instructor deauthorization Деавторизация инструктора - + Error! Ошибка! - + Warning! Внимание! - - The server is disabled - Сервер отключен + + The server is not available + Сервер не доступен - + Server settings have been changed. Please reconnect to the server. Настройки сервера изменены. Выполните переподключение к серверу. - - + + Instructor authorization Авторизация инструктора - + Invalid login or password! Неправильный логин или пароль! @@ -786,14 +769,12 @@ Delete it anyway? - yes да - no нет @@ -855,6 +836,16 @@ Delete it anyway? Tab 2 + + + Trainee + Обучаемый + + + + Instructor + Инструктор + MsgWidget @@ -868,6 +859,11 @@ Delete it anyway? TextLabel + + + --:-- + --:-- + NewVersionWidget @@ -968,33 +964,33 @@ Delete it anyway? - Messenger - Мессенджер + Chat + Чат - + Tasks Задачи - + AMM - - + + List Перечень - - + + Attached Назначенные - + FIM @@ -1062,13 +1058,11 @@ Delete it anyway? TraineesView - yes да - no нет @@ -1222,7 +1216,7 @@ Delete it anyway? Редактор инструкторов - + Editor of instructors Редактор инструкторов @@ -1235,17 +1229,17 @@ Delete it anyway? Обучаемые - + Editor of Trainees Редактор обучаемых - + Editor of trainees Редактор обучаемых - + Personal card trainee Персональная карта обучаемого