summaryrefslogtreecommitdiff
path: root/app/Model
diff options
context:
space:
mode:
authorFrédéric Guillot <fred@kanboard.net>2014-05-27 11:40:07 -0400
committerFrédéric Guillot <fred@kanboard.net>2014-05-27 11:40:07 -0400
commitc482e704697301a982e3c989ac795e0f4c2e899a (patch)
treeaaeba920ba4218792afac198e6b43ea619ff5a53 /app/Model
parent73944ae3687525eb7fafa0a0de2b919b51974542 (diff)
Add a new automatic action: assign a category based on a defined color
Diffstat (limited to 'app/Model')
-rw-r--r--app/Model/Action.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/app/Model/Action.php b/app/Model/Action.php
index 7cd917e9..0e3aee71 100644
--- a/app/Model/Action.php
+++ b/app/Model/Action.php
@@ -42,7 +42,8 @@ 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'),
+ 'TaskAssignColorCategory' => t('Assign automatically a color based on a category'),
+ 'TaskAssignCategoryColor' => t('Assign automatically a category based on a color'),
);
}
@@ -237,6 +238,9 @@ class Action extends Base
case 'TaskAssignColorCategory':
$className = '\Action\TaskAssignColorCategory';
return new $className($project_id, new Task($this->db, $this->event));
+ case 'TaskAssignCategoryColor':
+ $className = '\Action\TaskAssignCategoryColor';
+ return new $className($project_id, new Task($this->db, $this->event));
default:
throw new LogicException('Action not found: '.$name);
}