From 6cd96dcc09eeba073fa5988fe2e3f2aead6e659b Mon Sep 17 00:00:00 2001 From: krivoshein Date: Tue, 3 Jun 2025 15:31:28 +0300 Subject: [PATCH 1/2] =?UTF-8?q?=D0=A0=D0=B0=D1=81=D1=81=D1=8B=D0=BB=D0=BA?= =?UTF-8?q?=D0=B0=20=D0=B2=D1=81=D0=B5=D0=BC=20=D0=93=D0=A3=D0=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ServerLMS/Systems/processingsystem.cpp | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) diff --git a/ServerLMS/Systems/processingsystem.cpp b/ServerLMS/Systems/processingsystem.cpp index 8bc25fa..d612b1d 100644 --- a/ServerLMS/Systems/processingsystem.cpp +++ b/ServerLMS/Systems/processingsystem.cpp @@ -262,8 +262,9 @@ void ProcessingSystem::processingClientQueryToDB(ClientHandler *client, ClientQu { if(int id_new = providerDBLMS->newTaskAMM(*(TaskAmmFim*)data, id)) { - //Отправка списка задач AMM клиенту GUI - sendListTasksAMMofTraineetoClient(client, id); + //Отправка списка задач AMM всем клиентам GUI + //sendListTasksAMMofTraineetoClient(client, id); + emit sigStatusTasksAMMofTraineeChanged(id); //Отправка списка задач AMM клиенту Юнити if(ClientHandler* clientUnity = getUnityClientById(id)) @@ -277,8 +278,9 @@ void ProcessingSystem::processingClientQueryToDB(ClientHandler *client, ClientQu { if(int id_new = providerDBLMS->newTaskFIM(*(TaskAmmFim*)data, id)) { - //Отправка списка задач FIM клиенту GUI - sendListTasksFIMofTraineetoClient(client, id); + //Отправка списка задач FIM всем клиентам GUI + //sendListTasksFIMofTraineetoClient(client, id); + emit sigStatusTasksFIMofTraineeChanged(id); //Отправка списка задач FIM клиенту Юнити if(ClientHandler* clientUnity = getUnityClientById(id)) @@ -306,8 +308,9 @@ void ProcessingSystem::processingClientQueryToDB(ClientHandler *client, ClientQu { if(int id_trainee = providerDBLMS->delTaskAMM(id)) { - //Отправка списка задач AMM клиенту GUI - sendListTasksAMMofTraineetoClient(client, id_trainee); + //Отправка списка задач AMM всем клиентам GUI + //sendListTasksAMMofTraineetoClient(client, id_trainee); + emit sigStatusTasksAMMofTraineeChanged(id_trainee); //Отправка списка задач AMM клиенту Юнити if(ClientHandler* clientUnity = getUnityClientById(id_trainee)) @@ -322,7 +325,8 @@ void ProcessingSystem::processingClientQueryToDB(ClientHandler *client, ClientQu if(int id_trainee = providerDBLMS->delTaskFIM(id)) { //Отправка списка задач FIM клиенту GUI - sendListTasksFIMofTraineetoClient(client, id_trainee); + //sendListTasksFIMofTraineetoClient(client, id_trainee); + emit sigStatusTasksFIMofTraineeChanged(id_trainee); //Отправка списка задач FIM клиенту Юнити if(ClientHandler* clientUnity = getUnityClientById(id_trainee)) @@ -346,7 +350,7 @@ void ProcessingSystem::processingClientQueryToDB(ClientHandler *client, ClientQu case TypeQueryToDB::TYPE_QUERY_SET_REPORT_TASK_FIM_TO_TRAINEE: { TaskAmmFim* task = (TaskAmmFim*)data; - if(task->status == "completed") + if(task->status == /*"checkup"*/"completed") if(int id_report = providerDBLMS->replaceReportFIM(*task)) { @@ -359,8 +363,9 @@ void ProcessingSystem::processingClientQueryToDB(ClientHandler *client, ClientQu QString* status = (QString*)data; if(int id_trainee = providerDBLMS->changeStatusTaskFIM(id, *status)) { - //Отправка списка задач FIM клиенту GUI - sendListTasksFIMofTraineetoClient(client, id_trainee); + //Отправка списка задач FIM всем клиентам GUI + //sendListTasksFIMofTraineetoClient(client, id_trainee); + emit sigStatusTasksFIMofTraineeChanged(id_trainee); //Отправка списка задач FIM клиенту Юнити if(ClientHandler* clientUnity = getUnityClientById(id_trainee)) From 4b0c127eecedfedb04f6b6774bf0a9f7481bde54 Mon Sep 17 00:00:00 2001 From: krivoshein Date: Tue, 3 Jun 2025 15:33:34 +0300 Subject: [PATCH 2/2] checkup --- ServerLMS/Systems/processingsystem.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ServerLMS/Systems/processingsystem.cpp b/ServerLMS/Systems/processingsystem.cpp index d612b1d..d22db51 100644 --- a/ServerLMS/Systems/processingsystem.cpp +++ b/ServerLMS/Systems/processingsystem.cpp @@ -350,7 +350,7 @@ void ProcessingSystem::processingClientQueryToDB(ClientHandler *client, ClientQu case TypeQueryToDB::TYPE_QUERY_SET_REPORT_TASK_FIM_TO_TRAINEE: { TaskAmmFim* task = (TaskAmmFim*)data; - if(task->status == /*"checkup"*/"completed") + if(task->status == "checkup") if(int id_report = providerDBLMS->replaceReportFIM(*task)) {