* Modify task required item.

This commit is contained in:
xieqiyu
2023-11-21 10:32:37 +08:00
parent bcebe95d17
commit 8ebcd035b6
5 changed files with 41 additions and 40 deletions
+1
View File
@@ -765,6 +765,7 @@ class taskZen extends task
->setDefault('assignedTo', $oldTask->openedBy)
->get();
if(strpos(",{$this->config->task->finish->requiredFields},", ',comment,') !== false && empty($_POST['comment'])) dao::$errors['comment'] = sprintf($this->lang->error->notempty, $this->lang->comment);
if(!$this->post->currentConsumed && $oldTask->consumed == '0') dao::$errors['currentConsumed'][] = $this->lang->task->error->consumedEmpty;
if($task->realStarted > $task->finishedDate) dao::$errors['finishedDate'][] = $this->lang->task->error->finishedDateSmall;