diff options
author | Olivier Maridat <olivier.maridat@trialog.com> | 2015-03-10 14:32:23 +0100 |
---|---|---|
committer | Olivier Maridat <olivier.maridat@trialog.com> | 2015-03-10 14:32:23 +0100 |
commit | ef1fea4509a8bd475c9d77ab63764378f1b5067b (patch) | |
tree | deb2702ba728b03bbf8e1ad6021d4f4097c6f977 /app/Template/tasklink/create.php | |
parent | 900e3fa1fd0a41e1617cd42a83b34d4c39d1730f (diff) |
Add an item "Add a link" in the dropdown menu of a task in the board view
Diffstat (limited to 'app/Template/tasklink/create.php')
-rw-r--r-- | app/Template/tasklink/create.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/app/Template/tasklink/create.php b/app/Template/tasklink/create.php index fb438cd8..aec3b34a 100644 --- a/app/Template/tasklink/create.php +++ b/app/Template/tasklink/create.php @@ -2,7 +2,7 @@ <h2><?= t('Add a new link') ?></h2> </div> -<form action="<?= $this->u('tasklink', 'save', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>" method="post" autocomplete="off"> +<form action="<?= $this->u('tasklink', 'save', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'ajax' => isset($ajax))) ?>" method="post" autocomplete="off"> <?= $this->formCsrf() ?> <?= $this->formHidden('task_id', $values) ?> @@ -22,6 +22,10 @@ <div class="form-actions"> <input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/> <?= t('or') ?> - <?= $this->a(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?php if (isset($ajax)): ?> + <?= $this->a(t('cancel'), 'board', 'show', array('project_id' => $task['project_id'])) ?> + <?php else: ?> + <?= $this->a(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?php endif ?> </div> </form>
\ No newline at end of file |