diff options
Diffstat (limited to 'app/Model/Board.php')
-rw-r--r-- | app/Model/Board.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/app/Model/Board.php b/app/Model/Board.php index d5b83283..8dd68a80 100644 --- a/app/Model/Board.php +++ b/app/Model/Board.php @@ -178,7 +178,7 @@ class Board extends Base */ public function moveDown($project_id, $column_id) { - $columns = $this->db->table(self::TABLE)->eq('project_id', $project_id)->asc('position')->listing('id', 'position'); + $columns = $this->db->hashtable(self::TABLE)->eq('project_id', $project_id)->asc('position')->getAll('id', 'position'); $positions = array_flip($columns); if (isset($columns[$column_id]) && $columns[$column_id] < count($columns)) { @@ -207,7 +207,7 @@ class Board extends Base */ public function moveUp($project_id, $column_id) { - $columns = $this->db->table(self::TABLE)->eq('project_id', $project_id)->asc('position')->listing('id', 'position'); + $columns = $this->db->hashtable(self::TABLE)->eq('project_id', $project_id)->asc('position')->getAll('id', 'position'); $positions = array_flip($columns); if (isset($columns[$column_id]) && $columns[$column_id] > 1) { @@ -264,11 +264,11 @@ class Board extends Base public function getColumnStats($project_id, $prepend = false) { $listing = $this->db - ->table(Task::TABLE) + ->hashtable(Task::TABLE) ->eq('project_id', $project_id) ->eq('is_active', 1) ->groupBy('column_id') - ->listing('column_id', 'COUNT(*) AS total'); + ->getAll('column_id', 'COUNT(*) AS total'); return $prepend ? array(-1 => t('All columns')) + $listing : $listing; } @@ -295,7 +295,7 @@ class Board extends Base */ public function getColumnsList($project_id, $prepend = false) { - $listing = $this->db->table(self::TABLE)->eq('project_id', $project_id)->asc('position')->listing('id', 'title'); + $listing = $this->db->hashtable(self::TABLE)->eq('project_id', $project_id)->asc('position')->getAll('id', 'title'); return $prepend ? array(-1 => t('All columns')) + $listing : $listing; } |