diff options
Diffstat (limited to 'app/Template/subtask/show.php')
-rw-r--r-- | app/Template/subtask/show.php | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/app/Template/subtask/show.php b/app/Template/subtask/show.php index f48484cc..283057f4 100644 --- a/app/Template/subtask/show.php +++ b/app/Template/subtask/show.php @@ -1,4 +1,3 @@ - <div id="subtasks" class="task-show-section"> <?php if (! empty($subtasks)): ?> @@ -13,14 +12,14 @@ <th class="column-40"><?= t('Title') ?></th> <th><?= t('Assignee') ?></th> <th><?= t('Time tracking') ?></th> - <?php if (! isset($not_editable)): ?> + <?php if ($editable): ?> <th><?= t('Actions') ?></th> <?php endif ?> </tr> <?php foreach ($subtasks as $subtask): ?> <tr> <td> - <?php if (! isset($not_editable)): ?> + <?php if ($editable): ?> <?= $this->subtask->toggleStatus($subtask, 'task') ?> <?php else: ?> <?= $this->render('subtask/icons', array('subtask' => $subtask)) . $this->e($subtask['title']) ?> @@ -28,7 +27,7 @@ </td> <td> <?php if (! empty($subtask['username'])): ?> - <?php if (! isset($not_editable)): ?> + <?php if ($editable): ?> <?= $this->url->link($this->e($subtask['name'] ?: $subtask['username']), 'user', 'show', array('user_id' => $subtask['user_id'])) ?> <?php else: ?> <?= $this->e($subtask['name'] ?: $subtask['username']) ?> @@ -46,7 +45,7 @@ <strong><?= $this->e($subtask['time_estimated']).'h' ?></strong> <?= t('estimated') ?> <?php endif ?> </li> - <?php if (! isset($not_editable) && $subtask['user_id'] == $this->user->getId()): ?> + <?php if ($editable && $subtask['user_id'] == $this->user->getId()): ?> <li> <?php if ($subtask['is_timer_started']): ?> <i class="fa fa-pause"></i> @@ -60,7 +59,7 @@ <?php endif ?> </ul> </td> - <?php if (! isset($not_editable)): ?> + <?php if ($editable): ?> <td> <ul> <?php if ($subtask['position'] != $first_position): ?> @@ -87,7 +86,7 @@ </table> <?php endif ?> - <?php if (! isset($not_editable) && $this->user->hasProjectAccess('subtask', 'save', $task['project_id'])): ?> + <?php if ($editable && $this->user->hasProjectAccess('subtask', 'save', $task['project_id'])): ?> <?php if (empty($subtasks)): ?> <div class="page-header"> |