diff options
author | Frédéric Guillot <fred@kanboard.net> | 2014-05-21 22:33:57 -0400 |
---|---|---|
committer | Frédéric Guillot <fred@kanboard.net> | 2014-05-21 22:33:57 -0400 |
commit | a750b8ab2a0cb715da6fd9025a7ec8375db68a4d (patch) | |
tree | 5d5cdac1830336baf93b057e93cd2c1c56f405de /models/action.php | |
parent | 57e40671af56ae49eda467d9d5949bf9707020ee (diff) |
Add categories for projects and tasks
Diffstat (limited to 'models/action.php')
-rw-r--r-- | models/action.php | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/models/action.php b/models/action.php index a0236eff..c8cbf3b1 100644 --- a/models/action.php +++ b/models/action.php @@ -44,6 +44,7 @@ class Action extends Base 'TaskAssignCurrentUser' => t('Assign the task to the person who does the action'), 'TaskDuplicateAnotherProject' => t('Duplicate the task to another project'), 'TaskAssignColorUser' => t('Assign a color to a specific user'), + 'TaskAssignColorCategory' => t('Assign a color to a specific category'), ); } @@ -62,6 +63,7 @@ class Action extends Base Task::EVENT_CREATE => t('Task creation'), Task::EVENT_OPEN => t('Open a closed task'), Task::EVENT_CLOSE => t('Closing a task'), + Task::EVENT_CREATE_UPDATE => t('Task creation or modification'), ); } @@ -239,6 +241,10 @@ class Action extends Base require_once __DIR__.'/../actions/task_assign_color_user.php'; $className = '\Action\TaskAssignColorUser'; return new $className($project_id, new Task($this->db, $this->event)); + case 'TaskAssignColorCategory': + require_once __DIR__.'/../actions/task_assign_color_category.php'; + $className = '\Action\TaskAssignColorCategory'; + return new $className($project_id, new Task($this->db, $this->event)); default: throw new \LogicException('Action not found: '.$name); } |