diff options
author | Frederic Guillot <fred@kanboard.net> | 2017-02-26 19:30:02 -0500 |
---|---|---|
committer | Frederic Guillot <fred@kanboard.net> | 2017-02-26 19:30:02 -0500 |
commit | f3deb6492a74f1ffa9e3391274e0ab7947a04016 (patch) | |
tree | cbf7a3563cf1543bd131dd114f8dc89afdf5328f /app/Template/subtask/timer.php | |
parent | 4f325193be4f16a9658258fecd525e71917156a0 (diff) |
Add toggle button to show/hide subtasks in task list view
Diffstat (limited to 'app/Template/subtask/timer.php')
-rw-r--r-- | app/Template/subtask/timer.php | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/app/Template/subtask/timer.php b/app/Template/subtask/timer.php new file mode 100644 index 00000000..2102e6cc --- /dev/null +++ b/app/Template/subtask/timer.php @@ -0,0 +1,13 @@ +<span class="subtask-time-tracking"> + <?php if (! empty($subtask['time_spent'])): ?> + <strong><?= $this->text->e($subtask['time_spent']).'h' ?></strong> <?= t('spent') ?> + <?php endif ?> + + <?php if (! empty($subtask['time_estimated'])): ?> + <strong><?= $this->text->e($subtask['time_estimated']).'h' ?></strong> <?= t('estimated') ?> + <?php endif ?> + + <?php if ($this->user->hasProjectAccess('SubtaskController', 'edit', $task['project_id']) && $subtask['user_id'] == $this->user->getId()): ?> + <?= $this->subtask->renderTimer($task, $subtask) ?> + <?php endif ?> +</span> |