diff --git a/Action/EmailTaskHistory.php b/Action/EmailTaskHistory.php index 788ba50..ab6d99c 100644 --- a/Action/EmailTaskHistory.php +++ b/Action/EmailTaskHistory.php @@ -4,6 +4,7 @@ use Kanboard\Model\TaskModel; use Kanboard\Model\CommentModel; +use Kanboard\Model\ProjectModel; use Kanboard\Model\UserMetadataModel; use Kanboard\Action\Base; diff --git a/Plugin.php b/Plugin.php index cac427d..76b9a50 100644 --- a/Plugin.php +++ b/Plugin.php @@ -16,6 +16,11 @@ public function initialize() $this->actionManager->register(new EmailTaskHistory($this->container)); + if (!file_exists('plugins/Subtaskdate')) { + $this->template->setTemplateOverride('action_creation/params', 'kanboardEmailHistory:action_creation/params'); + } + + } public function onStartup() diff --git a/Template/action_creation/params.php b/Template/action_creation/params.php new file mode 100755 index 0000000..9ccb043 --- /dev/null +++ b/Template/action_creation/params.php @@ -0,0 +1,57 @@ + + +
+ form->csrf() ?> + + form->hidden('event_name', $values) ?> + form->hidden('action_name', $values) ?> + + form->label(t('Action'), 'action_name') ?> + form->select('action_name', $available_actions, $values, array(), array('disabled')) ?> + + form->label(t('Event'), 'event_name') ?> + form->select('event_name', $events, $values, array(), array('disabled')) ?> + + $param_desc): ?> + text->contains($param_name, 'column_id')): ?> + form->label($param_desc, $param_name) ?> + form->select('params['.$param_name.']', $columns_list, $values) ?> + text->contains($param_name, 'user_id')): ?> + form->label($param_desc, $param_name) ?> + form->select('params['.$param_name.']', $users_list, $values) ?> + text->contains($param_name, 'project_id')): ?> + form->label($param_desc, $param_name) ?> + form->select('params['.$param_name.']', $projects_list, $values) ?> + text->contains($param_name, 'color_id')): ?> + form->colorSelect('params['.$param_name.']', $values) ?> + text->contains($param_name, 'category_id')): ?> + form->label($param_desc, $param_name) ?> + form->select('params['.$param_name.']', $categories_list, $values) ?> + text->contains($param_name, 'link_id')): ?> + form->label($param_desc, $param_name) ?> + form->select('params['.$param_name.']', $links_list, $values) ?> + text->contains($param_name, 'check_box')): ?> + form->label(t('Options'), $param_name) ?> + form->checkbox('params['.$param_name.']', $param_desc, 1) ?> + + form->label($param_desc, $param_name) ?> + form->select('params['.$param_name.']', $priorities_list, $values) ?> + text->contains($param_name, 'duration')): ?> + form->label($param_desc, $param_name) ?> + form->number('params['.$param_name.']', $values) ?> + text->contains($param_name, 'swimlane_id')): ?> + form->label($param_desc, $param_name) ?> + form->select('params['.$param_name.']', $swimlane_list, $values) ?> + + form->label(ucfirst($param_name), $param_name) ?> + form->select('params['.$param_name.']', $param_desc, $values) ?> + + form->label($param_desc, $param_name) ?> + form->text('params['.$param_name.']', $values) ?> + + + + modal->submitButtons() ?> +
\ No newline at end of file