summaryrefslogtreecommitdiff
path: root/app/Api/Procedure/SwimlaneProcedure.php
diff options
context:
space:
mode:
authorFrederic Guillot <fred@kanboard.net>2017-02-18 09:42:01 -0500
committerFrederic Guillot <fred@kanboard.net>2017-02-18 09:42:01 -0500
commitde128dbad860478496a0d655b5eb5c1005ebbabe (patch)
tree7fee510e901273472731e8e843981268c593ec40 /app/Api/Procedure/SwimlaneProcedure.php
parent0430a09c069134622c0161dc2fb9ba3718a73c0d (diff)
Remove default swimlane
Diffstat (limited to 'app/Api/Procedure/SwimlaneProcedure.php')
-rw-r--r--app/Api/Procedure/SwimlaneProcedure.php11
1 files changed, 3 insertions, 8 deletions
diff --git a/app/Api/Procedure/SwimlaneProcedure.php b/app/Api/Procedure/SwimlaneProcedure.php
index 9b7d181d..25b1efb0 100644
--- a/app/Api/Procedure/SwimlaneProcedure.php
+++ b/app/Api/Procedure/SwimlaneProcedure.php
@@ -3,6 +3,7 @@
namespace Kanboard\Api\Procedure;
use Kanboard\Api\Authorization\ProjectAuthorization;
+use Kanboard\Model\SwimlaneModel;
/**
* Swimlane API controller
@@ -15,7 +16,7 @@ class SwimlaneProcedure extends BaseProcedure
public function getActiveSwimlanes($project_id)
{
ProjectAuthorization::getInstance($this->container)->check($this->getClassName(), 'getActiveSwimlanes', $project_id);
- return $this->swimlaneModel->getSwimlanes($project_id);
+ return $this->swimlaneModel->getAllByStatus($project_id, SwimlaneModel::ACTIVE);
}
public function getAllSwimlanes($project_id)
@@ -42,16 +43,10 @@ class SwimlaneProcedure extends BaseProcedure
return $this->swimlaneModel->getById($swimlane_id);
}
- public function getDefaultSwimlane($project_id)
- {
- ProjectAuthorization::getInstance($this->container)->check($this->getClassName(), 'getDefaultSwimlane', $project_id);
- return $this->swimlaneModel->getDefault($project_id);
- }
-
public function addSwimlane($project_id, $name, $description = '')
{
ProjectAuthorization::getInstance($this->container)->check($this->getClassName(), 'addSwimlane', $project_id);
- return $this->swimlaneModel->create(array('project_id' => $project_id, 'name' => $name, 'description' => $description));
+ return $this->swimlaneModel->create($project_id, $name, $description);
}
public function updateSwimlane($swimlane_id, $name, $description = null)