summaryrefslogtreecommitdiff
path: root/app/Controller/TaskMovePositionController.php
diff options
context:
space:
mode:
authorFrederic Guillot <fred@kanboard.net>2016-10-05 20:37:51 -0400
committerFrederic Guillot <fred@kanboard.net>2016-10-05 20:37:51 -0400
commit4cc856344f0105fe893c384eeec6b14036321651 (patch)
treef06c16a17be06421861b524db59764aef527261c /app/Controller/TaskMovePositionController.php
parent9159be81ec48dafa4ce0302418e5fcd2a95d734c (diff)
Do not show closed tasks in task move position form
Diffstat (limited to 'app/Controller/TaskMovePositionController.php')
-rw-r--r--app/Controller/TaskMovePositionController.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/app/Controller/TaskMovePositionController.php b/app/Controller/TaskMovePositionController.php
index 1a8eee45..a655ca0a 100644
--- a/app/Controller/TaskMovePositionController.php
+++ b/app/Controller/TaskMovePositionController.php
@@ -4,6 +4,7 @@ namespace Kanboard\Controller;
use Kanboard\Core\Controller\AccessForbiddenException;
use Kanboard\Formatter\BoardFormatter;
+use Kanboard\Model\TaskModel;
/**
* Class TaskMovePositionController
@@ -21,7 +22,10 @@ class TaskMovePositionController extends BaseController
'task' => $task,
'board' => BoardFormatter::getInstance($this->container)
->withProjectId($task['project_id'])
- ->withQuery($this->taskFinderModel->getExtendedQuery())
+ ->withQuery($this->taskFinderModel->getExtendedQuery()
+ ->eq(TaskModel::TABLE.'.is_active', TaskModel::STATUS_OPEN)
+ ->neq(TaskModel::TABLE.'.id', $task['id'])
+ )
->format()
)));
}