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 $tpl->getLang($tpl->get('task')->thread_comment->type) ?> 35 </strong> 36 <?php echo $tpl->get('task')->thread_comment->content_html ?> 37 </div> 38 <?php endif ?> 39 </div> 40 41 42 <br> 43<?php endif ?> 44 45<?php if ( $tpl->param('action') == 'task_edit' && 46 $tpl->param('tid') == $tpl->get('task')->id): ?> 47 <?php include 'task_form.php' ?> 48<?php else: ?> 49 <?php include 'task_box.php' ?> 50<?php endif ?> 51 52<br> 53<div class="bez_comments"> 54 <div class="bez_left_col"> 55 <?php foreach ($tpl->get('task_comments') as $task_comment): ?> 56 <?php $tpl->set('task_comment', $task_comment) ?> 57 <?php if ( $tpl->param('action') == 'comment_edit' && 58 $tpl->param('zkid') == $task_comment->id): ?> 59 <?php include 'task_comment_form.php' ?> 60 <?php else: ?> 61 <?php include 'task_comment_box.php' ?> 62 <?php endif ?> 63 <?php endforeach ?> 64 65 <?php if ($tpl->get('task')->state == 'done'): ?> 66 <div class="plugin__bez_status_label"> 67 <span class="icon icon_green"> 68 <?php echo inlineSVG(DOKU_PLUGIN . 'bez/images/tick.svg') ?> 69 </span> 70 <?php printf($tpl->getLang('user_did_task'), 71 '<strong>' . $tpl->user_name($tpl->get('task')->closed_by) . '</strong>', 72 $tpl->date_fuzzy_age($tpl->get('task')->close_date)) ?> 73 </div> 74 <?php endif ?> 75 76 <?php if($tpl->param('action') != 'task_edit' && $tpl->param('action') != 'comment_edit' && $tpl->get('task')->can_add_comments()): ?> 77 <?php include 'task_comment_form.php' ?> 78 <?php endif ?> 79 80 </div> 81 82<div class="bez_right_col" style="position:relative; top: -15px;"> 83 84 <div class="bez_box bez_subscribe_box"> 85 <h2><?php echo $tpl->getLang('norifications') ?></h2> 86 <?php if ($tpl->get('task')->is_subscribent()): ?> 87 <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> 88 <p><?php echo $tpl->getLang('task_subscribed_info') ?></p> 89 <?php else: ?> 90 <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> 91 <p><?php echo $tpl->getLang('task_not_subscribed_info') ?></p> 92 <?php endif ?> 93 94 </div> 95 96 <div class="bez_box"> 97 <h2><?php echo $tpl->getLang('comment_participants') ?></h2> 98 <ul id="issue_participants"> 99 <?php foreach ($tpl->get('task')->get_participants() as $participant): ?> 100 <li> 101 <?php if ($tpl->get('task')->acl_of('participants') >= BEZ_PERMISSION_CHANGE && 102 $participant['assignee'] == '0'): ?> 103 <a href="<?php echo $tpl->url('task', 'tid', $tpl->get('task')->id, 'action', 'participant_remove', 'user_id', $participant['user_id']) ?>" 104 class="participant_remove"> 105 <span class="bez_awesome"> 106  107 </span> 108 </a> 109 <?php endif ?> 110 <a href="<?php echo $tpl->mailto($tpl->user_email($participant['user_id']), 111 '#z'.$tpl->get('task')->id, 112 $tpl->url('task', 'tid', $tpl->get('task')->id)) ?>" 113 title="<?php echo $participant['user_id'] ?>"> 114 <span class="bez_name"><?php echo $tpl->user_name($participant['user_id']) ?></span> 115 <span class="bez_icons"> 116 <?php if($participant['original_poster']): ?> 117 <span class="bez_awesome" 118 title="<?php echo $tpl->getLang('reporter') ?>"> 119  120 </span> 121 <?php endif ?> 122 <?php if($participant['assignee']): ?> 123 <span class="bez_awesome" 124 title="<?php echo $tpl->getLang('executor') ?>"> 125  126 </span> 127 <?php endif ?> 128 <?php if($participant['commentator']): ?> 129 <span class="bez_awesome" 130 title="<?php echo $tpl->getLang('commentator') ?>"> 131  132 </span> 133 <?php endif ?> 134 <?php if($participant['subscribent']): ?> 135 <span class="bez_awesome" 136 title="<?php echo $tpl->getLang('subscribent') ?>"> 137  138 </span> 139 <?php endif ?> 140 </span> 141 </a></li> 142 <?php endforeach ?> 143 </ul> 144 145 <?php if ($tpl->get('task')->acl_of('participants') >= BEZ_PERMISSION_CHANGE): ?> 146 <h2><?php echo $tpl->getLang('issue_invite_header') ?></h2> 147 <form action="<?php echo $tpl->url('task', 'tid', $tpl->get('task')->id, 'action', 'invite') ?>" method="post" id="bez_invite_users_form"> 148 <div id="bez_invite_users" class="ui-widget"> 149 <select name="client"> 150 <option value="">--- <?php echo $tpl->getLang('select') ?> ---</option> 151 <?php foreach (array_diff_key($tpl->get('users'), $tpl->get('task')->get_participants('subscribent')) as $user_id => $ignore): ?> 152 <option value="<?php echo $user_id ?>"><?php echo $tpl->user_name($user_id) ?></option> 153 <?php endforeach ?> 154 </select> 155 </div> 156 <button class="bez_subscribe_button"><?php echo $tpl->getLang('issue_invite_button') ?></button> 157 </form> 158 <?php endif ?> 159 160 161 </div> 162 163 164</div> 165 166</div> 167 168