notifyController убрал

This commit is contained in:
2025-11-30 19:28:08 +03:00
parent fb493aca9f
commit d129fbded0
20 changed files with 82 additions and 206 deletions

View File

@@ -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)