echo '</tr>'; } # Tagging if ($tpl_show_tags) { echo '<tr ', helper_alternate_class(), '>'; echo '<th class="bug-tags category">', lang_get('tags'), '</th>'; echo '<td class="bug-tags" colspan="5">'; tag_display_attached($tpl_bug_id); echo '</td></tr>'; } # Attachments Form if ($tpl_can_attach_tag) { echo '<tr ', helper_alternate_class(), '>'; echo '<th class="bug-attach-tags category">', lang_get('tag_attach_long'), '</th>'; echo '<td class="bug-attach-tags" colspan="5">'; print_tag_attach_form($tpl_bug_id); echo '</td></tr>'; } # spacer echo '<tr class="spacer"><td colspan="6"></td></tr>'; # Custom Fields $t_custom_fields_found = false; $t_related_custom_field_ids = custom_field_get_linked_ids($tpl_bug->project_id); foreach ($t_related_custom_field_ids as $t_id) { if (!custom_field_has_read_access($t_id, $f_bug_id)) { continue; } # has read access $t_custom_fields_found = true; $t_def = custom_field_get_definition($t_id); echo '<tr ', helper_alternate_class(), '>';
?> <?php if (access_has_bug_level(config_get('tag_attach_threshold'), $f_bug_id)) { ?> <tr <?php echo helper_alternate_class(); ?> > <td class="category"><?php echo lang_get('tag_attach_long'); ?> </td> <td colspan="5"> <?php print_tag_attach_form($f_bug_id); ?> </td> </tr> <?php } # has tag attach access ?> <!-- spacer --> <tr class="spacer"> <td colspan="6"></td> </tr> <!-- Custom Fields -->
echo '<td>', string_html_specialchars($t_tag_row['name']), '</td></tr>'; if (!is_blank($t_tag_string)) { $t_tag_string .= config_get('tag_separator'); } $t_tag_string .= $t_tag_row['name']; } ?> <tr class="spacer"><td colspan="2"></td></tr> <tr> <th class="category"><?php echo lang_get('tag_attach_long'); ?> </th> <td> <?php print_tag_attach_form($f_bug_id, $t_tag_string); ?> </td> </tr> </table> <?php html_page_bottom(); // end failed to attach tag } else { foreach ($t_tags_create as $t_tag_row) { $t_tag_row['id'] = tag_create($t_tag_row['name'], $t_user_id); $t_tags_attach[] = $t_tag_row; } foreach ($t_tags_attach as $t_tag_row) { if (!tag_bug_is_attached($t_tag_row['id'], $f_bug_id)) { tag_bug_attach($t_tag_row['id'], $f_bug_id, $t_user_id);