Merge branch 'sprint/master_zhouxudong_15338' into 'master'
* Fix bug #15338. See merge request easycorp/zentaopms!3140
This commit is contained in:
@@ -565,7 +565,7 @@ class task extends control
|
||||
if($this->post->names)
|
||||
{
|
||||
$allChanges = $this->task->batchUpdate();
|
||||
if(dao::isError()) return $this->send(array('result' => 'fail', 'message' => dao::getError()));
|
||||
if(dao::isError()) return print(js::error(dao::getError()));
|
||||
|
||||
if(!empty($allChanges))
|
||||
{
|
||||
|
||||
@@ -1194,6 +1194,12 @@ class taskModel extends model
|
||||
$task->consumed = $oldTask->consumed;
|
||||
$task->parent = $oldTask->parent;
|
||||
|
||||
if(strpos(',doing,pause,', $task->status) and empty($teams) and empty($task->left))
|
||||
{
|
||||
dao::$errors[] = sprintf($this->lang->task->error->leftEmptyAB, zget($this->lang->task->statusList, $task->status));
|
||||
return false;
|
||||
}
|
||||
|
||||
if(empty($task->closedReason))
|
||||
{
|
||||
if($oldTask->status == 'done') $task->closedReason = 'done';
|
||||
|
||||
Reference in New Issue
Block a user