mirror of
https://gitea.msk.dinamika-avia.ru/Constanta-Design/RRJServer.git
synced 2026-03-28 19:55:48 +03:00
notifyController убрал
This commit is contained in:
@@ -22,7 +22,6 @@ AMMtasksWidget::AMMtasksWidget(ConnectorToServer* connectorToServer, TypeListTre
|
||||
waitAnimationWidget(nullptr),
|
||||
dlgCheckerTask(nullptr),
|
||||
dlgListSubProc(nullptr),
|
||||
specialMessageBox(nullptr),
|
||||
flOnlyActive(false),
|
||||
lastCurrentID(0)
|
||||
{
|
||||
@@ -157,8 +156,6 @@ void AMMtasksWidget::closeChildDlg()
|
||||
dlgCheckerTask->close();
|
||||
if(dlgListSubProc)
|
||||
dlgListSubProc->close();
|
||||
if(specialMessageBox)
|
||||
specialMessageBox->close();
|
||||
}
|
||||
|
||||
void AMMtasksWidget::changeEvent(QEvent *event)
|
||||
@@ -329,16 +326,10 @@ void AMMtasksWidget::slot_UpdateSubProcForDMCode(QString dmCode)
|
||||
lastSelectedTask.listSubProc.clear();
|
||||
dlgListSubProc->getListCheckedSubProc(&lastSelectedTask.listSubProc);
|
||||
|
||||
specialMessageBox = new SpecMsgBox(this, SpecMsgBox::TypeSpecMsgBox::warningYesNo, tr("Assign this task?"));
|
||||
if(specialMessageBox->exec() == QDialog::Accepted)
|
||||
if(SpecMsgBox::WarningYesNo(this, tr("Assign this task?")) == QDialog::Accepted)
|
||||
{
|
||||
connectorToServer->sendQueryToDB(TypeQueryToDB::TYPE_QUERY_ASSIGN_TASK_AMM_TO_TRAINEE, idTraineeSelected, &lastSelectedTask);
|
||||
}
|
||||
if(specialMessageBox)
|
||||
{
|
||||
delete specialMessageBox;
|
||||
specialMessageBox = nullptr;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case QDialog::Rejected:
|
||||
@@ -357,16 +348,10 @@ void AMMtasksWidget::slot_UpdateSubProcForDMCode(QString dmCode)
|
||||
{
|
||||
lastSelectedTask.listSubProc.clear();
|
||||
|
||||
specialMessageBox = new SpecMsgBox(this, SpecMsgBox::TypeSpecMsgBox::warningYesNo, tr("Assign this task?"));
|
||||
if(specialMessageBox->exec() == QDialog::Accepted)
|
||||
if(SpecMsgBox::WarningYesNo(this, tr("Assign this task?")) == QDialog::Accepted)
|
||||
{
|
||||
connectorToServer->sendQueryToDB(TypeQueryToDB::TYPE_QUERY_ASSIGN_TASK_AMM_TO_TRAINEE, idTraineeSelected, &lastSelectedTask);
|
||||
}
|
||||
if(specialMessageBox)
|
||||
{
|
||||
delete specialMessageBox;
|
||||
specialMessageBox = nullptr;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -520,18 +505,11 @@ void AMMtasksWidget::on_btnDelete_clicked()
|
||||
|
||||
int id = treeItemCurrent->text(ColumnsTreeAMM::clmnAMM_ID).toInt();
|
||||
|
||||
specialMessageBox = new SpecMsgBox(this, SpecMsgBox::TypeSpecMsgBox::warningYesNo, tr("The deletion will be irrevocable.\nDelete it anyway?"));
|
||||
|
||||
if(specialMessageBox->exec() == QDialog::Accepted)
|
||||
if(SpecMsgBox::WarningYesNo(this, tr("The deletion will be irrevocable.\nDelete it anyway?")) == QDialog::Accepted)
|
||||
{
|
||||
waitAnimationWidget->showWithPlay();
|
||||
connectorToServer->sendQueryToDB(TypeQueryToDB::TYPE_QUERY_DEL_TASK_AMM_TO_TRAINEE, id);
|
||||
}
|
||||
if(specialMessageBox)
|
||||
{
|
||||
delete specialMessageBox;
|
||||
specialMessageBox = nullptr;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -103,8 +103,6 @@ private:
|
||||
|
||||
DialogListSubProc* dlgListSubProc;
|
||||
|
||||
SpecMsgBox* specialMessageBox;
|
||||
|
||||
bool flOnlyActive; //AMM
|
||||
|
||||
int lastCurrentID;
|
||||
|
||||
@@ -8,7 +8,6 @@ CheckerTask::CheckerTask(ConnectorToServer* connectorToServer, QString type, QWi
|
||||
ui(new Ui::CheckerTask),
|
||||
connectorToServer(connectorToServer),
|
||||
fimTasksWidget(nullptr),
|
||||
specialMessageBox(nullptr),
|
||||
flChanged(false),
|
||||
id_task(0),
|
||||
type("fim")
|
||||
@@ -49,19 +48,13 @@ CheckerTask::~CheckerTask()
|
||||
delete fimTasksWidget;
|
||||
fimTasksWidget = nullptr;
|
||||
}
|
||||
if(specialMessageBox)
|
||||
{
|
||||
delete specialMessageBox;
|
||||
specialMessageBox = nullptr;
|
||||
}
|
||||
|
||||
delete ui;
|
||||
}
|
||||
|
||||
void CheckerTask::closeEvent(QCloseEvent *event)
|
||||
{
|
||||
if(specialMessageBox)
|
||||
specialMessageBox->close();
|
||||
|
||||
}
|
||||
|
||||
void CheckerTask::setTask(TaskAmmFim* task)
|
||||
@@ -183,18 +176,12 @@ void CheckerTask::on_btnWrong_clicked()
|
||||
msgString = tr("Change task status?\nThe status will be set:\n'new'");
|
||||
}
|
||||
|
||||
specialMessageBox = new SpecMsgBox(this, SpecMsgBox::TypeSpecMsgBox::warningYesNo, msgString);
|
||||
if(specialMessageBox->exec() == QDialog::Accepted)
|
||||
if(SpecMsgBox::WarningYesNo(this, msgString) == QDialog::Accepted)
|
||||
{
|
||||
connectorToServer->sendQueryToDB(typeQuery, id_task, (void*)&status);
|
||||
this->parentWidget()->close();
|
||||
flChanged = true;
|
||||
}
|
||||
if(specialMessageBox)
|
||||
{
|
||||
delete specialMessageBox;
|
||||
specialMessageBox = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
void CheckerTask::on_btnRight_clicked()
|
||||
@@ -216,16 +203,10 @@ void CheckerTask::on_btnRight_clicked()
|
||||
msgString = tr("Change task status?\nThe status will be set:\n'completed'");
|
||||
}
|
||||
|
||||
specialMessageBox = new SpecMsgBox(this, SpecMsgBox::TypeSpecMsgBox::warningYesNo, msgString);
|
||||
if(specialMessageBox->exec() == QDialog::Accepted)
|
||||
if(SpecMsgBox::WarningYesNo(this, msgString) == QDialog::Accepted)
|
||||
{
|
||||
connectorToServer->sendQueryToDB(typeQuery, id_task, (void*)&status);
|
||||
this->parentWidget()->close();
|
||||
flChanged = true;
|
||||
}
|
||||
if(specialMessageBox)
|
||||
{
|
||||
delete specialMessageBox;
|
||||
specialMessageBox = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -48,8 +48,6 @@ private:
|
||||
ConnectorToServer* connectorToServer;
|
||||
FIMtasksWidget* fimTasksWidget;
|
||||
|
||||
SpecMsgBox* specialMessageBox;
|
||||
|
||||
bool flChanged;
|
||||
int id_task;
|
||||
QString type;
|
||||
|
||||
@@ -22,7 +22,6 @@ FIMtasksWidget::FIMtasksWidget(ConnectorToServer* connectorToServer, TypeListTre
|
||||
taskTreePreparation(nullptr),
|
||||
waitAnimationWidget(nullptr),
|
||||
dlgCheckerTask(nullptr),
|
||||
specialMessageBox(nullptr),
|
||||
userName(""),
|
||||
lastCurrentID(0)
|
||||
{
|
||||
@@ -103,8 +102,6 @@ FIMtasksWidget::~FIMtasksWidget()
|
||||
|
||||
if(dlgCheckerTask)
|
||||
dlgCheckerTask->close();
|
||||
if(specialMessageBox)
|
||||
specialMessageBox->close();
|
||||
|
||||
delete ui;
|
||||
}
|
||||
@@ -140,8 +137,6 @@ void FIMtasksWidget::closeChildDlg()
|
||||
{
|
||||
if(dlgCheckerTask)
|
||||
dlgCheckerTask->close();
|
||||
if(specialMessageBox)
|
||||
specialMessageBox->close();
|
||||
}
|
||||
|
||||
void FIMtasksWidget::changeEvent(QEvent *event)
|
||||
@@ -401,17 +396,11 @@ void FIMtasksWidget::on_btnDelete_clicked()
|
||||
|
||||
int id = treeItemCurrent->text(ColumnsTreeFIM::clmnFIM_ID).toInt();
|
||||
|
||||
specialMessageBox = new SpecMsgBox(this, SpecMsgBox::TypeSpecMsgBox::warningYesNo, tr("The deletion will be irrevocable.\nDelete it anyway?"));
|
||||
if(specialMessageBox->exec() == QDialog::Accepted)
|
||||
if(SpecMsgBox::WarningYesNo(this, tr("The deletion will be irrevocable.\nDelete it anyway?")) == QDialog::Accepted)
|
||||
{
|
||||
waitAnimationWidget->showWithPlay();
|
||||
connectorToServer->sendQueryToDB(TypeQueryToDB::TYPE_QUERY_DEL_TASK_FIM_TO_TRAINEE, id);
|
||||
}
|
||||
if(specialMessageBox)
|
||||
{
|
||||
delete specialMessageBox;
|
||||
specialMessageBox = nullptr;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -451,14 +440,8 @@ void FIMtasksWidget::on_btnCheck_clicked()
|
||||
|
||||
void FIMtasksWidget::on_btnAssignTask_clicked()
|
||||
{
|
||||
specialMessageBox = new SpecMsgBox(this, SpecMsgBox::TypeSpecMsgBox::warningYesNo, tr("Assign this task?"));
|
||||
if(specialMessageBox->exec() == QDialog::Accepted)
|
||||
if(SpecMsgBox::WarningYesNo(this, tr("Assign this task?")) == QDialog::Accepted)
|
||||
assignTaskFIMtoTrainee();
|
||||
if(specialMessageBox)
|
||||
{
|
||||
delete specialMessageBox;
|
||||
specialMessageBox = nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
void FIMtasksWidget::updateTaskItem(QTreeWidgetItem *itemTask)
|
||||
|
||||
@@ -92,8 +92,6 @@ private:
|
||||
|
||||
DialogChekerTask* dlgCheckerTask;
|
||||
|
||||
SpecMsgBox* specialMessageBox;
|
||||
|
||||
QString userName; //FIM
|
||||
|
||||
int lastCurrentID;
|
||||
|
||||
Reference in New Issue
Block a user