diff --git a/app/Template/task/dropdown.php b/app/Template/task/dropdown.php
index cc97d1a16..da2e7d7e1 100644
--- a/app/Template/task/dropdown.php
+++ b/app/Template/task/dropdown.php
@@ -1,6 +1,8 @@
+ = $this->hook->render('template:task:dropdown:before-actions', array('task' => $task)) ?>
+
projectRole->canUpdateTask($task)): ?>
projectRole->canChangeAssignee($task) && array_key_exists('owner_id', $task) && $task['owner_id'] != $this->user->getId()): ?>
-
@@ -19,33 +21,45 @@
-
= $this->modal->medium('plus', t('Add a sub-task'), 'SubtaskController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:dropdown:after-basic-actions', array('task' => $task)) ?>
+
-
= $this->modal->medium('code-fork', t('Add internal link'), 'TaskInternalLinkController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
-
= $this->modal->medium('external-link', t('Add external link'), 'TaskExternalLinkController', 'find', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:dropdown:after-add-links', array('task' => $task)) ?>
+
-
= $this->modal->small('comment-o', t('Add a comment'), 'CommentController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:dropdown:after-add-comment', array('task' => $task)) ?>
+
-
= $this->modal->medium('file', t('Attach a document'), 'TaskFileController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
-
= $this->modal->medium('camera', t('Add a screenshot'), 'TaskPopoverController', 'screenshot', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:dropdown:after-add-attachments', array('task' => $task)) ?>
+
-
= $this->modal->small('files-o', t('Duplicate'), 'TaskDuplicationController', 'duplicate', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
-
= $this->modal->small('clipboard', t('Duplicate to another project'), 'TaskDuplicationController', 'copy', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:dropdown:after-duplicate-task', array('task' => $task)) ?>
+
-
= $this->modal->small('clone', t('Move to another project'), 'TaskDuplicationController', 'move', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
-
= $this->modal->small('paper-plane', t('Send by email'), 'TaskMailController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:dropdown:after-send-mail', array('task' => $task)) ?>
+
projectRole->canRemoveTask($task)): ?>
-
= $this->modal->confirm('trash-o', t('Remove'), 'TaskSuppressionController', 'confirm', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
diff --git a/app/Template/task/sidebar.php b/app/Template/task/sidebar.php
index 265c6ef0e..8bb387d6d 100644
--- a/app/Template/task/sidebar.php
+++ b/app/Template/task/sidebar.php
@@ -29,6 +29,8 @@
= t('Actions') ?>
+ = $this->hook->render('template:task:sidebar:before-actions', array('task' => $task)) ?>
+
projectRole->canUpdateTask($task)): ?>
-
= $this->modal->large('edit', t('Edit the task'), 'TaskModificationController', 'edit', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
@@ -40,33 +42,45 @@
-
= $this->modal->medium('plus', t('Add a sub-task'), 'SubtaskController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:sidebar:after-basic-actions', array('task' => $task)) ?>
+
-
= $this->modal->medium('code-fork', t('Add internal link'), 'TaskInternalLinkController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
-
= $this->modal->medium('external-link', t('Add external link'), 'TaskExternalLinkController', 'find', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:sidebar:after-add-links', array('task' => $task)) ?>
+
-
= $this->modal->small('comment-o', t('Add a comment'), 'CommentController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:sidebar:after-add-comment', array('task' => $task)) ?>
+
-
= $this->modal->medium('file', t('Attach a document'), 'TaskFileController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
-
= $this->modal->medium('camera', t('Add a screenshot'), 'TaskFileController', 'screenshot', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:sidebar:after-add-attachments', array('task' => $task)) ?>
+
-
= $this->modal->small('files-o', t('Duplicate'), 'TaskDuplicationController', 'duplicate', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
-
= $this->modal->small('clipboard', t('Duplicate to another project'), 'TaskDuplicationController', 'copy', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:sidebar:after-duplicate-task', array('task' => $task)) ?>
+
-
= $this->modal->small('clone', t('Move to another project'), 'TaskDuplicationController', 'move', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
-
= $this->modal->small('paper-plane', t('Send by email'), 'TaskMailController', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>
+ = $this->hook->render('template:task:sidebar:after-send-mail', array('task' => $task)) ?>
+
projectRole->isSortableColumn($task['project_id'], $task['column_id'])): ?>
-
= $this->modal->small('arrows', t('Move position'), 'TaskMovePositionController', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>