diff options
Diffstat (limited to 'app/Model/Project.php')
-rw-r--r-- | app/Model/Project.php | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/app/Model/Project.php b/app/Model/Project.php index 6e3c2326..9843a54c 100644 --- a/app/Model/Project.php +++ b/app/Model/Project.php @@ -201,7 +201,7 @@ class Project extends Base * Get all projects with all its data for a given status * * @access public - * @param integer $status Proejct status: self::ACTIVE or self:INACTIVE + * @param integer $status Project status: self::ACTIVE or self:INACTIVE * @return array */ public function getAllByStatus($status) @@ -245,6 +245,19 @@ class Project extends Base } /** + * Get Priority range from a project + * + * @access public + * @param array $project + * @return array + */ + public function getPriorities(array $project) + { + $range = range($project['priority_start'], $project['priority_end']); + return array_combine($range, $range); + } + + /** * Gather some task metrics for a given project * * @access public |