summaryrefslogtreecommitdiff
path: root/app/Template/board
diff options
context:
space:
mode:
author85pando <85pando@googlemail.com>2016-02-05 10:28:40 +0100
committer85pando <85pando@googlemail.com>2016-02-05 10:28:40 +0100
commit791d13c87bf510d913973b77a5f6d152311a1d87 (patch)
tree81412e8dbd3ac4fa0047030a6068afafd975687e /app/Template/board
parent2074aaaa9a75455097e4e77ca09f4fba3e567052 (diff)
parent12aaec03b19a07635f59b00f532c92c37ac1df5f (diff)
Merge remote-tracking branch 'refs/remotes/upstream/master'
Conflicts: app/Locale/de_DE/translations.php
Diffstat (limited to 'app/Template/board')
-rw-r--r--app/Template/board/popover_assignee.php3
-rw-r--r--app/Template/board/popover_category.php3
-rw-r--r--app/Template/board/task_footer.php6
-rw-r--r--app/Template/board/task_menu.php5
-rw-r--r--app/Template/board/tooltip_external_links.php20
-rw-r--r--app/Template/board/tooltip_subtasks.php15
-rw-r--r--app/Template/board/tooltip_tasklinks.php37
7 files changed, 61 insertions, 28 deletions
diff --git a/app/Template/board/popover_assignee.php b/app/Template/board/popover_assignee.php
index e86ba420..8db95323 100644
--- a/app/Template/board/popover_assignee.php
+++ b/app/Template/board/popover_assignee.php
@@ -9,8 +9,7 @@
<?= $this->form->hidden('id', $values) ?>
<?= $this->form->hidden('project_id', $values) ?>
- <?= $this->form->label(t('Assignee'), 'owner_id') ?>
- <?= $this->form->select('owner_id', $users_list, $values, array(), array('autofocus')) ?><br/>
+ <?= $this->task->selectAssignee($users_list, $values, array(), array('autofocus')) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
diff --git a/app/Template/board/popover_category.php b/app/Template/board/popover_category.php
index 224ce8d1..e65593cd 100644
--- a/app/Template/board/popover_category.php
+++ b/app/Template/board/popover_category.php
@@ -9,8 +9,7 @@
<?= $this->form->hidden('id', $values) ?>
<?= $this->form->hidden('project_id', $values) ?>
- <?= $this->form->label(t('Category'), 'category_id') ?>
- <?= $this->form->select('category_id', $categories_list, $values, array(), array('autofocus')) ?><br/>
+ <?= $this->task->selectCategory($categories_list, $values, array(), array('autofocus'), true) ?>
<div class="form-actions">
<input type="submit" value="<?= t('Save') ?>" class="btn btn-blue"/>
diff --git a/app/Template/board/task_footer.php b/app/Template/board/task_footer.php
index 26f3b1d4..1912dd83 100644
--- a/app/Template/board/task_footer.php
+++ b/app/Template/board/task_footer.php
@@ -35,7 +35,11 @@
<?php endif ?>
<?php if (! empty($task['nb_links'])): ?>
- <span title="<?= t('Links') ?>" class="tooltip" data-href="<?= $this->url->href('BoardTooltip', 'tasklinks', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>"><i class="fa fa-code-fork"></i>&nbsp;<?= $task['nb_links'] ?></span>
+ <span title="<?= t('Links') ?>" class="tooltip" data-href="<?= $this->url->href('BoardTooltip', 'tasklinks', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>"><i class="fa fa-code-fork fa-fw"></i><?= $task['nb_links'] ?></span>
+ <?php endif ?>
+
+ <?php if (! empty($task['nb_external_links'])): ?>
+ <span title="<?= t('External links') ?>" class="tooltip" data-href="<?= $this->url->href('BoardTooltip', 'externallinks', array('task_id' => $task['id'], 'project_id' => $task['project_id'])) ?>"><i class="fa fa-external-link fa-fw"></i><?= $task['nb_external_links'] ?></span>
<?php endif ?>
<?php if (! empty($task['nb_subtasks'])): ?>
diff --git a/app/Template/board/task_menu.php b/app/Template/board/task_menu.php
index b5ed125d..bd582185 100644
--- a/app/Template/board/task_menu.php
+++ b/app/Template/board/task_menu.php
@@ -7,11 +7,12 @@
<li><i class="fa fa-pencil-square-o fa-fw"></i>&nbsp;<?= $this->url->link(t('Edit this task'), 'taskmodification', 'edit', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?></li>
<li><i class="fa fa-comment-o fa-fw"></i>&nbsp;<?= $this->url->link(t('Add a comment'), 'comment', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?></li>
<li><i class="fa fa-code-fork fa-fw"></i>&nbsp;<?= $this->url->link(t('Add a link'), 'tasklink', 'create', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?></li>
+ <li><i class="fa fa-external-link fa-fw"></i>&nbsp;<?= $this->url->link(t('Add external link'), 'TaskExternalLink', 'find', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?></li>
<li><i class="fa fa-camera fa-fw"></i>&nbsp;<?= $this->url->link(t('Add a screenshot'), 'BoardPopover', 'screenshot', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?></li>
<?php if ($task['is_active'] == 1): ?>
- <li><i class="fa fa-close fa-fw"></i>&nbsp;<?= $this->url->link(t('Close this task'), 'taskstatus', 'close', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'redirect' => 'board'), false, 'popover') ?></li>
+ <li><i class="fa fa-close fa-fw"></i>&nbsp;<?= $this->url->link(t('Close this task'), 'taskstatus', 'close', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?></li>
<?php else: ?>
- <li><i class="fa fa-check-square-o fa-fw"></i>&nbsp;<?= $this->url->link(t('Open this task'), 'taskstatus', 'open', array('task_id' => $task['id'], 'project_id' => $task['project_id'], 'redirect' => 'board'), false, 'popover') ?></li>
+ <li><i class="fa fa-check-square-o fa-fw"></i>&nbsp;<?= $this->url->link(t('Open this task'), 'taskstatus', 'open', array('task_id' => $task['id'], 'project_id' => $task['project_id']), false, 'popover') ?></li>
<?php endif ?>
</ul>
</span> \ No newline at end of file
diff --git a/app/Template/board/tooltip_external_links.php b/app/Template/board/tooltip_external_links.php
new file mode 100644
index 00000000..7681c06c
--- /dev/null
+++ b/app/Template/board/tooltip_external_links.php
@@ -0,0 +1,20 @@
+<table class="table-striped table-small">
+ <tr>
+ <th class="column-20"><?= t('Type') ?></th>
+ <th class="column-80"><?= t('Title') ?></th>
+ <th class="column-10"><?= t('Dependency') ?></th>
+ </tr>
+ <?php foreach ($links as $link): ?>
+ <tr>
+ <td>
+ <?= $link['type'] ?>
+ </td>
+ <td>
+ <a href="<?= $link['url'] ?>" target="_blank"><?= $this->e($link['title']) ?></a>
+ </td>
+ <td>
+ <?= $this->e($link['dependency_label']) ?>
+ </td>
+ </tr>
+ <?php endforeach ?>
+</table> \ No newline at end of file
diff --git a/app/Template/board/tooltip_subtasks.php b/app/Template/board/tooltip_subtasks.php
index 5c273e08..65b7ce4d 100644
--- a/app/Template/board/tooltip_subtasks.php
+++ b/app/Template/board/tooltip_subtasks.php
@@ -1,7 +1,12 @@
-<section id="tooltip-subtasks">
+<table class="table-stripped">
<?php foreach ($subtasks as $subtask): ?>
- <?= $this->subtask->toggleStatus($subtask, 'board', $task['project_id']) ?>
- <?= $this->e(empty($subtask['username']) ? '' : ' ['.$this->user->getFullname($subtask).']') ?>
- <br/>
+ <tr>
+ <td class="column-80">
+ <?= $this->subtask->toggleStatus($subtask, $task['project_id']) ?>
+ </td>
+ <td>
+ <?= $this->e($subtask['username'] ?: $this->user->getFullname($subtask)) ?>
+ </td>
+ </tr>
<?php endforeach ?>
-</section>
+</table>
diff --git a/app/Template/board/tooltip_tasklinks.php b/app/Template/board/tooltip_tasklinks.php
index 62304330..b51f90ed 100644
--- a/app/Template/board/tooltip_tasklinks.php
+++ b/app/Template/board/tooltip_tasklinks.php
@@ -1,19 +1,24 @@
<div class="tooltip-tasklinks">
- <ul>
- <?php foreach ($links as $link): ?>
- <li>
- <strong><?= t($link['label']) ?></strong>
- [<i><?= $link['project_name'] ?></i>]
- <?= $this->url->link(
- $this->e('#'.$link['task_id'].' - '.$link['title']),
- 'task', 'show', array('task_id' => $link['task_id'], 'project_id' => $link['project_id']),
- false,
- $link['is_active'] ? '' : 'task-link-closed'
- ) ?>
- <?php if (! empty($link['task_assignee_username'])): ?>
- [<?= $this->e($link['task_assignee_name'] ?: $link['task_assignee_username']) ?>]
- <?php endif ?>
- </li>
+ <dl>
+ <?php foreach ($links as $label => $grouped_links): ?>
+ <dt><strong><?= t($label) ?></strong></dt>
+ <?php foreach ($grouped_links as $link): ?>
+ <dd>
+ <span class="progress"><?= $this->task->getProgress($link).'%' ?></span>
+ <?= $this->url->link(
+ $this->e('#'.$link['task_id'].' '.$link['title']),
+ 'task', 'show', array('task_id' => $link['task_id'], 'project_id' => $link['project_id']),
+ false,
+ $link['is_active'] ? '' : 'task-link-closed'
+ ) ?>
+ <?php if (! empty($link['task_assignee_username'])): ?>
+ [<?= $this->e($link['task_assignee_name'] ?: $link['task_assignee_username']) ?>]
+ <?php endif ?>
+ <?php if ($task['project_id'] != $link['project_id']): ?>
+ (<i><?= $link['project_name'] ?></i>)
+ <?php endif ?>
+ </dd>
+ <?php endforeach ?>
<?php endforeach ?>
- </ul>
+ </dl>
</div> \ No newline at end of file