summaryrefslogtreecommitdiff
path: root/app/Templates/task_show.php
diff options
context:
space:
mode:
authorFrédéric Guillot <fred@kanboard.net>2014-05-22 20:58:21 -0400
committerFrédéric Guillot <fred@kanboard.net>2014-05-22 20:58:21 -0400
commit40917992e775bd21a280eb267241c452e04e5ade (patch)
treec1bf82ab83564bc9ca749f026f54342cbd35374f /app/Templates/task_show.php
parent2230dd4e6b148346c0ec596b9e3e12996a762ed8 (diff)
Add files upload
Diffstat (limited to 'app/Templates/task_show.php')
-rw-r--r--app/Templates/task_show.php17
1 files changed, 17 insertions, 0 deletions
diff --git a/app/Templates/task_show.php b/app/Templates/task_show.php
index a5b79359..56f6cba5 100644
--- a/app/Templates/task_show.php
+++ b/app/Templates/task_show.php
@@ -64,6 +64,23 @@
</form>
<?php endif ?>
+<?php if (! empty($files)): ?>
+ <h2 id="attachments"><?= t('Attachments') ?></h2>
+ <ul class="task-show-files">
+ <?php foreach ($files as $file): ?>
+ <li>
+ <a href="?controller=task&amp;action=download&amp;file_id=<?= $file['id'] ?>&amp;task_id=<?= $task['id'] ?>"><?= Helper\escape($file['name']) ?></a>
+ <span class="task-show-file-actions">
+ <?php if ($file['is_image']): ?>
+ <a href="?controller=task&amp;action=openFile&amp;file_id=<?= $file['id'] ?>&amp;task_id=<?= $task['id'] ?>" class="popover"><?= t('open') ?></a>,
+ <?php endif ?>
+ <a href="?controller=task&amp;action=confirmRemoveFile&amp;file_id=<?= $file['id'] ?>&amp;task_id=<?= $task['id'] ?>"><?= t('remove') ?></a>
+ </span>
+ </li>
+ <?php endforeach ?>
+ </ul>
+<?php endif ?>
+
<h2><?= t('Comments') ?></h2>
<?php if ($comments): ?>
<ul id="comments">