diff options
Diffstat (limited to 'app/Template/tasklink/create.php')
-rw-r--r-- | app/Template/tasklink/create.php | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/app/Template/tasklink/create.php b/app/Template/tasklink/create.php new file mode 100644 index 00000000..749f2968 --- /dev/null +++ b/app/Template/tasklink/create.php @@ -0,0 +1,37 @@ +<div class="page-header"> + <h2><?= t('Add a new link') ?></h2> +</div> + +<form action="<?= $this->url->href('tasklink', 'save', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'ajax' => isset($ajax))) ?>" method="post" autocomplete="off"> + + <?= $this->form->csrf() ?> + <?= $this->form->hidden('task_id', array('task_id' => $task['id'])) ?> + <?= $this->form->hidden('opposite_task_id', $values) ?> + + <?= $this->form->label(t('Label'), 'link_id') ?> + <?= $this->form->select('link_id', $labels, $values, $errors) ?> + + <?= $this->form->label(t('Task'), 'title') ?> + <?= $this->form->text( + 'title', + $values, + $errors, + array( + 'required', + 'placeholder="'.t('Start to type task title...').'"', + 'title="'.t('Start to type task title...').'"', + 'data-dst-field="opposite_task_id"', + 'data-search-url="'.$this->url->href('app', 'autocomplete', array('exclude_task_id' => $task['id'])).'"', + ), + 'task-autocomplete') ?> + + <div class="form-actions"> + <input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/> + <?= t('or') ?> + <?php if (isset($ajax)): ?> + <?= $this->url->link(t('cancel'), 'board', 'show', array('project_id' => $task['project_id']), false, 'close-popover') ?> + <?php else: ?> + <?= $this->url->link(t('cancel'), 'task', 'show', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?> + <?php endif ?> + </div> +</form>
\ No newline at end of file |