summaryrefslogtreecommitdiff
path: root/app/Template/subtask/timer.php
blob: 0f17fc73ea74045669baf2b7157c38156adb76f9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<span class="subtask-time-tracking">
    <?php if (! empty($subtask['time_spent'])): ?>
        <?= t('%sh spent', n($subtask['time_spent'])) ?>
    <?php endif ?>

    <?php if (! empty($subtask['time_spent']) && ! empty($subtask['time_estimated'])): ?>/<?php endif ?>

    <?php if (! empty($subtask['time_estimated'])): ?>
        <?= t('%sh estimated', n($subtask['time_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>