diff options
Diffstat (limited to 'app/Model/Swimlane.php')
-rw-r--r-- | app/Model/Swimlane.php | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/app/Model/Swimlane.php b/app/Model/Swimlane.php index c9c080af..069f14b6 100644 --- a/app/Model/Swimlane.php +++ b/app/Model/Swimlane.php @@ -157,6 +157,27 @@ class Swimlane extends Base } /** + * Get list of all swimlanes + * + * @access public + * @param integer $project_id Project id + * @return array + */ + public function getSwimlanesList($project_id) + { + $swimlanes = $this->db->table(self::TABLE) + ->eq('project_id', $project_id) + ->orderBy('position', 'asc') + ->listing('id', 'name'); + + $swimlanes[0] = $this->db->table(Project::TABLE) + ->eq('id', $project_id) + ->findOneColumn('default_swimlane'); + + return $swimlanes; + } + + /** * Add a new swimlane * * @access public |