Close all subtasks when a task is closed

This commit is contained in:
Frederic Guillot
2015-06-20 16:50:52 -04:00
parent a409bf3ff4
commit b6b733b22f
5 changed files with 61 additions and 2 deletions

View File

@@ -62,6 +62,7 @@ class TaskStatus extends Base
*/
public function close($task_id)
{
$this->subtask->closeAll($task_id);
return $this->changeStatus($task_id, Task::STATUS_CLOSED, time(), Task::EVENT_CLOSE);
}
@@ -113,7 +114,7 @@ class TaskStatus extends Base
}
/**
* Check the status of task
* Check the status of a task
*
* @access private
* @param integer $task_id Task id