diff options
author | Valentin Yakovenkov <yakovenkov@niistt.ru> | 2016-07-06 15:00:21 +0300 |
---|---|---|
committer | Valentin Yakovenkov <yakovenkov@niistt.ru> | 2016-07-07 09:40:19 +0300 |
commit | 1d58b33950e1fe87cf7caa9b16849813ac939b5c (patch) | |
tree | e1e92e5e6a47e948807ac001d6f79f9fac63231a /app | |
parent | 8856e57163dbdc069f9438b28706f8eec68bbcdc (diff) |
Hide empty parts of task details page
Diffstat (limited to 'app')
-rw-r--r-- | app/Template/task/show.php | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/app/Template/task/show.php b/app/Template/task/show.php index 80786715..76c572a1 100644 --- a/app/Template/task/show.php +++ b/app/Template/task/show.php @@ -7,9 +7,12 @@ 'editable' => $this->user->hasProjectAccess('TaskModificationController', 'edit', $project['id']), )) ?> +<?php if(!empty($task['description'])): ?> <?= $this->hook->render('template:task:show:before-description', array('task' => $task, 'project' => $project)) ?> <?= $this->render('task/description', array('task' => $task)) ?> +<?php endif ?> +<?php if(!empty($subtasks)): ?> <?= $this->hook->render('template:task:show:before-subtasks', array('task' => $task, 'project' => $project)) ?> <?= $this->render('subtask/show', array( 'task' => $task, @@ -17,7 +20,9 @@ 'project' => $project, 'editable' => true, )) ?> +<?php endif ?> +<?php if(!empty($internal_links)): ?> <?= $this->hook->render('template:task:show:before-internal-links', array('task' => $task, 'project' => $project)) ?> <?= $this->render('task_internal_link/show', array( 'task' => $task, @@ -27,21 +32,27 @@ 'editable' => true, 'is_public' => false, )) ?> +<?php endif ?> +<?php if(!empty($external_links)): ?> <?= $this->hook->render('template:task:show:before-external-links', array('task' => $task, 'project' => $project)) ?> <?= $this->render('task_external_link/show', array( 'task' => $task, 'links' => $external_links, 'project' => $project, )) ?> +<?php endif ?> +<?php if(!empty($files)): ?> <?= $this->hook->render('template:task:show:before-attachments', array('task' => $task, 'project' => $project)) ?> <?= $this->render('task_file/show', array( 'task' => $task, 'files' => $files, 'images' => $images )) ?> +<?php endif ?> +<?php if(!empty($comments)): ?> <?= $this->hook->render('template:task:show:before-comments', array('task' => $task, 'project' => $project)) ?> <?= $this->render('comments/show', array( 'task' => $task, @@ -49,5 +60,6 @@ 'project' => $project, 'editable' => $this->user->hasProjectAccess('CommentController', 'edit', $project['id']), )) ?> +<?php endif ?> <?= $this->hook->render('template:task:show:bottom', array('task' => $task, 'project' => $project)) ?> |