1<?php /* @var \dokuwiki\plugin\bez\meta\Tpl $tpl */ ?> 2<?php if ($tpl->get('task')->thread_id != '' && $tpl->get('task')->thread->acl_of('id') >= BEZ_PERMISSION_VIEW): ?> 3 <div class="bez_thread 4 <?php 5 if ($tpl->get('task')->thread->state == 'opened') { 6 echo 'priority_' . $tpl->get('task')->thread->priority; 7 } 8 ?>"> 9 <div> 10 <strong><?php echo $tpl->getLang('issue') ?>:</strong> 11 <a href="<?php echo $tpl->url('thread', 'id', $tpl->get('task')->thread->id) ?>"> 12 #<?php echo $tpl->get('task')->thread->id ?> 13 </a> 14 <strong> 15 <?php if ($tpl->get('task')->thread->type == 'project'): ?> 16 <?php echo $tpl->getLang('project') ?> 17 <?php elseif (!empty($tpl->get('task')->thread->label_name)): ?> 18 <?php echo $tpl->get('task')->thread->label_name ?> 19 <?php else: ?> 20 <i style="color: #777"><?php echo $tpl->getLang('issue_type_no_specified') ?></i> 21 <?php endif ?> 22 23 (<?php echo $tpl->getLang('state_' . $tpl->get('task')->thread->state) ?>): 24 </strong> 25 <?php echo $tpl->get('task')->thread->title ?> 26 </div> 27 28 <?php if ($tpl->get('task')->thread_comment_id != ''): ?> 29 <div style="margin-top: 12px;"> 30 <strong> 31 <a href="<?php echo $tpl->url('thread', 'id', $tpl->get('task')->thread->id) ?>#k<?php echo $tpl->get('task')->thread_comment->id ?>"> 32 #k<?php echo $tpl->get('task')->thread_comment->id ?> 33 </a> 34 <?php echo ucfirst($tpl->getLang('cause')) ?> 35 (<?php echo $tpl->getLang($tpl->get('task')->thread_comment->type) ?>) 36 </strong> 37 <?php echo $tpl->get('task')->thread_comment->content_html ?> 38 </div> 39 <?php endif ?> 40 </div> 41 42 43 <br> 44<?php endif ?> 45 46<?php if ( $tpl->param('action') == 'task_edit' && 47 $tpl->param('tid') == $tpl->get('task')->id): ?> 48 <?php include 'task_form.php' ?> 49<?php else: ?> 50 <?php include 'task_box.php' ?> 51<?php endif ?> 52 53<br> 54<div class="bez_comments"> 55 <div class="bez_left_col"> 56 <?php foreach ($tpl->get('task_comments') as $task_comment): ?> 57 <?php $tpl->set('task_comment', $task_comment) ?> 58 <?php if ( $tpl->param('action') == 'comment_edit' && 59 $tpl->param('zkid') == $task_comment->id): ?> 60 <?php include 'task_comment_form.php' ?> 61 <?php else: ?> 62 <?php include 'task_comment_box.php' ?> 63 <?php endif ?> 64 <?php endforeach ?> 65 66 <?php if ($tpl->get('task')->state == 'done'): ?> 67 <div class="plugin__bez_status_label"> 68 <span class="icon icon_green"> 69 <?php echo inlineSVG(DOKU_PLUGIN . 'bez/images/tick.svg') ?> 70 </span> 71 <?php printf($tpl->getLang('user_did_task'), 72 '<strong>' . $tpl->user_name($tpl->get('task')->closed_by) . '</strong>', 73 $tpl->date_fuzzy_age($tpl->get('task')->close_date)) ?> 74 </div> 75 <?php endif ?> 76 77 <?php if($tpl->param('action') != 'task_edit' && $tpl->param('action') != 'comment_edit' && $tpl->get('task')->can_add_comments()): ?> 78 <?php include 'task_comment_form.php' ?> 79 <?php endif ?> 80 81 </div> 82 83<div class="bez_right_col" style="position:relative; top: -15px;"> 84 85 <div class="bez_box bez_subscribe_box"> 86 <h2><?php echo $tpl->getLang('norifications') ?></h2> 87 <?php if ($tpl->get('task')->is_subscribent()): ?> 88 <a href="<?php echo $tpl->url('task', 'tid', $tpl->get('task')->id, 'action', 'unsubscribe') ?>" class="bez_subscribe_button"><span class="bez_awesome"></span> <?php echo $tpl->getLang('unsubscribe') ?></a> 89 <p><?php echo $tpl->getLang('task_subscribed_info') ?></p> 90 <?php else: ?> 91 <a href="<?php echo $tpl->url('task', 'tid', $tpl->get('task')->id, 'action', 'subscribe') ?>" class="bez_subscribe_button"><span class="bez_awesome"></span> <?php echo $tpl->getLang('subscribe') ?></a> 92 <p><?php echo $tpl->getLang('task_not_subscribed_info') ?></p> 93 <?php endif ?> 94 95 </div> 96 97 <div class="bez_box"> 98 <h2><?php echo $tpl->getLang('comment_participants') ?></h2> 99 <ul id="issue_participants"> 100 <?php foreach ($tpl->get('task')->get_participants() as $participant): ?> 101 <li> 102 <?php if ($tpl->get('task')->acl_of('participants') >= BEZ_PERMISSION_CHANGE && 103 $participant['assignee'] == '0'): ?> 104 <a href="<?php echo $tpl->url('task', 'tid', $tpl->get('task')->id, 'action', 'participant_remove', 'user_id', $participant['user_id']) ?>" 105 class="participant_remove"> 106 <span class="bez_awesome"> 107  108 </span> 109 </a> 110 <?php endif ?> 111 <a href="<?php echo $tpl->mailto($tpl->user_email($participant['user_id']), 112 '#z'.$tpl->get('task')->id, 113 $tpl->url('task', 'tid', $tpl->get('task')->id)) ?>" 114 title="<?php echo $participant['user_id'] ?>"> 115 <span class="bez_name"><?php echo $tpl->user_name($participant['user_id']) ?></span> 116 <span class="bez_icons"> 117 <?php if($participant['original_poster']): ?> 118 <span class="bez_awesome" 119 title="<?php echo $tpl->getLang('reporter') ?>"> 120  121 </span> 122 <?php endif ?> 123 <?php if($participant['assignee']): ?> 124 <span class="bez_awesome" 125 title="<?php echo $tpl->getLang('executor') ?>"> 126  127 </span> 128 <?php endif ?> 129 <?php if($participant['commentator']): ?> 130 <span class="bez_awesome" 131 title="<?php echo $tpl->getLang('commentator') ?>"> 132  133 </span> 134 <?php endif ?> 135 <?php if($participant['subscribent']): ?> 136 <span class="bez_awesome" 137 title="<?php echo $tpl->getLang('subscribent') ?>"> 138  139 </span> 140 <?php endif ?> 141 </span> 142 </a></li> 143 <?php endforeach ?> 144 </ul> 145 146 <?php if ($tpl->get('task')->acl_of('participants') >= BEZ_PERMISSION_CHANGE): ?> 147 <h2><?php echo $tpl->getLang('issue_invite_header') ?></h2> 148 <form action="<?php echo $tpl->url('task', 'tid', $tpl->get('task')->id, 'action', 'invite') ?>" method="post" id="bez_invite_users_form"> 149 <div id="bez_invite_users" class="ui-widget"> 150 <select name="client"> 151 <option value="">--- <?php echo $tpl->getLang('select') ?> ---</option> 152 <?php foreach (array_diff_key($tpl->get('users'), $tpl->get('task')->get_participants('subscribent')) as $user_id => $ignore): ?> 153 <option value="<?php echo $user_id ?>"><?php echo $tpl->user_name($user_id) ?></option> 154 <?php endforeach ?> 155 </select> 156 </div> 157 <button class="bez_subscribe_button"><?php echo $tpl->getLang('issue_invite_button') ?></button> 158 </form> 159 <?php endif ?> 160 161 162 </div> 163 164 165</div> 166 167</div> 168 169