summaryrefslogtreecommitdiffstats
path: root/template/en/default/bug
diff options
context:
space:
mode:
authorDavid Lawrence <dlawrence@mozilla.com>2011-10-05 00:25:23 +0200
committerDavid Lawrence <dlawrence@mozilla.com>2011-10-05 00:25:23 +0200
commit57584dc4744fea59833ef355f7513690d246c70f (patch)
tree805f2b2941eca17eaf97263165d11d9e676ad9d1 /template/en/default/bug
parent785580c6c290b93fe25868cfbb5d4e300749de62 (diff)
downloadbugzilla-57584dc4744fea59833ef355f7513690d246c70f.tar.gz
bugzilla-57584dc4744fea59833ef355f7513690d246c70f.tar.xz
more porting work
Diffstat (limited to 'template/en/default/bug')
-rw-r--r--template/en/default/bug/comments.html.tmpl53
-rw-r--r--template/en/default/bug/create/comment-guided.txt.tmpl2
-rw-r--r--template/en/default/bug/create/create-guided.html.tmpl48
-rw-r--r--template/en/default/bug/create/create.html.tmpl52
-rw-r--r--template/en/default/bug/edit.html.tmpl224
-rw-r--r--template/en/default/bug/field.html.tmpl24
-rw-r--r--template/en/default/bug/process/updates-disabled.html.tmpl73
-rw-r--r--template/en/default/bug/show-multiple.html.tmpl1
-rw-r--r--template/en/default/bug/show.xml.tmpl5
9 files changed, 314 insertions, 168 deletions
diff --git a/template/en/default/bug/comments.html.tmpl b/template/en/default/bug/comments.html.tmpl
index 208ea092a..a6a2867bb 100644
--- a/template/en/default/bug/comments.html.tmpl
+++ b/template/en/default/bug/comments.html.tmpl
@@ -25,6 +25,37 @@
<script src="[% 'js/comments.js' FILTER mtime %]" type="text/javascript">
</script>
+<script type="text/javascript">
+<!--
+ /* Adds the reply text to the `comment' textarea */
+ function replyToComment(id, real_id, name) {
+ var prefix = "(In reply to " + name + " from comment #" + id + ")\n";
+ var replytext = "";
+ [% IF user.settings.quote_replies.value == 'quoted_reply' %]
+ /* pre id="comment_name_N" */
+ var text_elem = document.getElementById('comment_text_'+id);
+ var text = getText(text_elem);
+ replytext = prefix + wrapReplyText(text);
+ [% ELSIF user.settings.quote_replies.value == 'simple_reply' %]
+ replytext = prefix;
+ [% END %]
+
+ [% IF user.is_insider %]
+ if (document.getElementById('isprivate_' + real_id).checked) {
+ document.getElementById('newcommentprivacy').checked = 'checked';
+ updateCommentTagControl(document.getElementById('newcommentprivacy'), 'comment');
+ }
+ [% END %]
+
+ /* <textarea id="comment"> */
+ var textarea = document.getElementById('comment');
+ textarea.value += replytext;
+
+ textarea.focus();
+ }
+//-->
+</script>
+
[% DEFAULT start_at = 0 mode = "show" %]
[% sort_order = user.settings.comment_sort_order.value %]
@@ -52,6 +83,8 @@
[% END %]
[% END %]
+[% Hook.process("comment_banner") %]
+
<!-- This auto-sizes the comments and positions the collapse/expand links
to the right. -->
<table class="bz_comment_table" cellpadding="0" cellspacing="0"><tr>
@@ -65,14 +98,6 @@
[% count = count + increment %]
[% END %]
-[% IF user.settings.comment_box_position.value == "before_comments" && user.id %]
- <div class="bz_add_comment">
- <a href="#"
- onclick="return goto_add_comments();">
- Add Comment</a>
- </div>
-[% END %]
-
[%# Note: this template is used in multiple places; if you use this hook,
# make sure you are aware of this fact.
#%]
@@ -86,11 +111,6 @@
return false;">Collapse All Comments</a></li>
<li><a href="#" onclick="toggle_all_comments('expand');
return false;">Expand All Comments</a></li>
- [% IF user.settings.comment_box_position.value == "after_comments" && user.id %]
- <li class="bz_add_comment"><a href="#"
- onclick="return goto_add_comments('bug_status_bottom');">
- Add Comment</a></li>
- [% END %]
</ul>
[% END %]
</td>
@@ -120,8 +140,12 @@
[% IF mode == "edit" %]
<span class="bz_comment_actions">
+ [<a class="bz_reply_link" href="#add_comment"
+ [% IF user.settings.quote_replies.value != 'off' %]
+ onclick="replyToComment('[% count %]', '[% comment.id %]', '[% comment.author.name || comment.author.nick FILTER html FILTER js %]'); return false;"
+ [% END %]
+ >reply</a>]
<script type="text/javascript"><!--
- addReplyLink([% count %], [% comment.id %]);
addCollapseLink([% count %]); // -->
</script>
</span>
@@ -148,6 +172,7 @@
<span class="bz_comment_user">
[% INCLUDE global/user.html.tmpl who = comment.author %]
+ [% Hook.process('user', 'bug/comments.html.tmpl') %]
</span>
<span class="bz_comment_user_images">
diff --git a/template/en/default/bug/create/comment-guided.txt.tmpl b/template/en/default/bug/create/comment-guided.txt.tmpl
index df04d8fb5..67748e594 100644
--- a/template/en/default/bug/create/comment-guided.txt.tmpl
+++ b/template/en/default/bug/create/comment-guided.txt.tmpl
@@ -41,7 +41,7 @@ Steps to Reproduce:
[%+ cgi.param("reproduce_steps") %]
[% END %]
-[% IF cgi.param("actual_results") -%]
+[% IF cgi.param("actual_results") %]
Actual Results:
[%+ cgi.param("actual_results") %]
[% END %]
diff --git a/template/en/default/bug/create/create-guided.html.tmpl b/template/en/default/bug/create/create-guided.html.tmpl
index d10314628..43437bcd7 100644
--- a/template/en/default/bug/create/create-guided.html.tmpl
+++ b/template/en/default/bug/create/create-guided.html.tmpl
@@ -31,22 +31,12 @@
[% PROCESS global/header.html.tmpl
title = "Enter $terms.ABug"
onload = "PutDescription()"
- style = "#somebugs { width: 100%; height: 500px }"
+ style_urls = [ "skins/standard/guided.css" ]
%]
[% style = "" %]
-<p>
- <font color="red">
- This is a template used on mozilla.org. This template, and the
- comment-guided.txt.tmpl template that formats the data submitted via
- the form in this template, are included as a demo of what it's
- possible to do with custom templates in general, and custom [% terms.bug %]
- entry templates in particular. As much of the text will not apply,
- you should alter it
- if you want to use this form on your [% terms.Bugzilla %] installation.
- </font>
-</p>
+[% INCLUDE 'bug/create/user-message.html.tmpl' %]
[% tablecolour = "#FFFFCC" %]
@@ -80,15 +70,15 @@ function PutDescription() {
[%# Include other products if sensible %]
[% IF product.name == "Firefox" %]
- [% productstring = "product=Mozilla%20Application%20Suite&amp;product=Firefox" %]
+ [% productstring = "product=Toolkit&amp;product=Core&amp;product=Firefox" %]
[% ELSIF product.name == "Thunderbird" %]
- [% productstring = "product=Mozilla%20Application%20Suite&amp;product=Thunderbird" %]
+ [% productstring = "product=MailNews%20Core&amp;product=Thunderbird" %]
[% ELSE %]
[% productstring = BLOCK %]product=[% product.name FILTER uri %][% END %]
[% END %]
<p>
- <a href="duplicates.cgi?[% productstring %]&amp;format=simple" target="somebugs">All-time Top 100</a> (loaded initially) |
+ <a href="duplicates.cgi?[% productstring %]&amp;format=simple" target="somebugs">All-time Top 20</a> (loaded initially) |
<a href="duplicates.cgi?[% productstring %]&amp;format=simple&amp;sortby=delta&amp;reverse=1&amp;maxrows=100&amp;changedsince=14" target="somebugs">Hot in the last two weeks</a>
</p>
@@ -112,14 +102,14 @@ function PutDescription() {
<input type="hidden" name="product" value="[% product.name FILTER html %]">
[% IF product.name == "Firefox" OR
product.name == "Thunderbird" OR
- product.name == "Mozilla Application Suite" OR
+ product.name == "SeaMonkey" OR
product.name == "Camino" %]
<input type="hidden" name="product" value="Core">
<input type="hidden" name="product" value="Toolkit">
- <input type="hidden" name="product" value="PSM">
<input type="hidden" name="product" value="NSPR">
<input type="hidden" name="product" value="NSS">
- [% END %]
+ <input type="hidden" name="product" value="MailNews Core">
+ [% END %]
<input type="hidden" name="chfieldfrom" value="-6m">
<input type="hidden" name="chfieldto" value="Now">
<input type="hidden" name="chfield" value="[Bug creation]">
@@ -215,7 +205,7 @@ function PutDescription() {
[%# We override rep_platform and op_sys for simplicity. The values chosen
are based on which are most common in the b.m.o database %]
- [% rep_platform = [ "PC", "Macintosh", "All", "Other" ] %]
+ [% rep_platform = [ "x86", "x86_64", "PowerPC", "All", "Other" ] %]
<tr bgcolor="[% tablecolour %]">
<td align="right" valign="top">
@@ -238,7 +228,7 @@ function PutDescription() {
</td>
</tr>
- [% IF product.name.match("Firefox|Camino|Mozilla Application Suite") %]
+ [% IF product.name.match("Firefox|Camino|SeaMonkey") %]
[% matches = cgi.user_agent('Gecko/(\d+)') %]
[% buildid = cgi.user_agent() IF matches %]
[% END %]
@@ -257,8 +247,8 @@ function PutDescription() {
<p>
This should identify the exact version of the product you were using.
If the above field is blank or you know it is incorrect, copy the
- version text from the product's Help |
- About menu (for browsers this will begin with "Mozilla/5.0...").
+ user agent text from the product's Help | Troubleshooting Information menu
+ (for browsers this will begin with "Mozilla/5.0...").
If the product won't start, instead paste the complete URL you downloaded
it from.
</p>
@@ -275,7 +265,7 @@ function PutDescription() {
URL that demonstrates the problem you are seeing (optional).<br>
<b>IMPORTANT</b>: if the problem is with a broken web page, you need
to report it
- <a href="https://bugzilla.mozilla.org/page.cgi?id=broken-website.html">a different way</a>.
+ <a href="http://input.mozilla.com/feedback">a different way</a>.
</p>
</td>
</tr>
@@ -418,10 +408,7 @@ function PutDescription() {
%]
<p>
Add any additional information you feel may be
- relevant to this [% terms.bug %], such as the <b>theme</b> you were
- using (does the [% terms.bug %] still occur
- with the default theme?), a
- <b><a href="http://kb.mozillazine.org/Quality_Feedback_Agent">Talkback crash ID</a></b>, or special
+ relevant to this [% terms.bug %], such as special
information about <b>your computer's configuration</b>. Any information
longer than a few lines, such as a <b>stack trace</b> or <b>HTML
testcase</b>, should be added
@@ -431,13 +418,12 @@ function PutDescription() {
into your URL bar.
<br>
<br>
- If you are reporting a crash, note the module in
- which the software crashed (e.g., <tt>Application Violation in
- gkhtml.dll</tt>).
+ If you are reporting a crash, please <a href="https://developer.mozilla.org/En/How_to_get_a_stacktrace_for_a_bug_report
+">try and get a stack trace</a>, which tells us exactly where things went wrong.
</p>
</td>
</tr>
-
+
<tr>
<td valign="top" align="right">
<b>Severity</b>
diff --git a/template/en/default/bug/create/create.html.tmpl b/template/en/default/bug/create/create.html.tmpl
index ee19ab5d6..52f4c3cf4 100644
--- a/template/en/default/bug/create/create.html.tmpl
+++ b/template/en/default/bug/create/create.html.tmpl
@@ -59,12 +59,10 @@ var flags = new Array([% product.components.size %]);
comp_desc[[% count %]] = "[% c.description FILTER html_light FILTER js %]";
initialowners[[% count %]] = "[% c.default_assignee.login FILTER js %]";
[% flag_list = [] %]
- [% FOREACH f = c.flag_types.bug %]
- [% NEXT UNLESS f.is_active %]
+ [% FOREACH f = c.flag_types(is_active=>1).bug %]
[% flag_list.push(f.id) %]
[% END %]
- [% FOREACH f = c.flag_types.attachment %]
- [% NEXT UNLESS f.is_active %]
+ [% FOREACH f = c.flag_types(is_active=>1).attachment %]
[% flag_list.push(f.id) %]
[% END %]
flags[[% count %]] = [[% flag_list.join(",") FILTER js %]];
@@ -358,18 +356,17 @@ TUI_hide_default('attachment_text_field');
%]
<td rowspan="[% num_rows FILTER html %]">
- [% IF product.flag_types.bug.size > 0 %]
+ [% IF product.flag_types(isactive=>1).bug.size > 0 %]
[% display_flag_headers = 0 %]
[% any_flags_requesteeble = 0 %]
- [% FOREACH flag_type = product.flag_types.bug %]
- [% NEXT UNLESS flag_type.is_active %]
+ [% FOREACH flag_type = product.flag_types(is_active=>1).bug %]
[% display_flag_headers = 1 %]
[% SET any_flags_requesteeble = 1 IF flag_type.is_requestable && flag_type.is_requesteeble %]
[% END %]
[% IF display_flag_headers %]
- [% PROCESS "flag/list.html.tmpl" flag_types = product.flag_types.bug
+ [% PROCESS "flag/list.html.tmpl" flag_types = product.flag_types(is_active=>1).bug
any_flags_requesteeble = any_flags_requesteeble
flag_table_id = "bug_flags"
%]
@@ -488,9 +485,11 @@ TUI_hide_default('attachment_text_field');
<tbody>
[% USE Bugzilla %]
-
+
[% FOREACH field = Bugzilla.active_custom_fields %]
[% NEXT UNLESS field.enter_bug %]
+ [% NEXT IF cf_hidden_in_product(field.name, product.name, component.name) %]
+
[% SET value = ${field.name}.defined ? ${field.name} : "" %]
<tr [% 'class="expert_fields"' IF !field.is_mandatory %]>
[% INCLUDE bug/field.html.tmpl
@@ -574,22 +573,6 @@ TUI_hide_default('attachment_text_field');
</td>
</tr>
- [% IF user.is_insider %]
- <tr class="expert_fields">
- <th>&nbsp;</th>
- <td colspan="3">
- &nbsp;&nbsp;
- <input type="checkbox" id="comment_is_private" name="comment_is_private"
- [% ' checked="checked"' IF comment_is_private %]
- onClick="updateCommentTagControl(this, 'comment')">
- <label for="comment_is_private">
- Make description and any new attachment private (visible only to members
- of the <strong>[% Param('insidergroup') FILTER html %]</strong> group)
- </label>
- </td>
- </tr>
- [% END %]
-
[% IF Param("maxattachmentsize") %]
<tr>
<th>Attachment:</th>
@@ -605,10 +588,20 @@ TUI_hide_default('attachment_text_field');
<legend>Add an attachment</legend>
<table class="attachment_entry">
[% PROCESS attachment/createformcontents.html.tmpl
- flag_types = product.flag_types.attachment
+ flag_types = product.flag_types(is_active=>1).attachment
any_flags_requesteeble = 1
flag_table_id ="attachment_flags" %]
</table>
+
+ [% IF user.is_insider %]
+ <input type="checkbox" id="comment_is_private" name="comment_is_private"
+ [% ' checked="checked"' IF comment_is_private %]
+ onClick="updateCommentTagControl(this, 'comment')">
+ <label for="comment_is_private">
+ Make this attachment and [% terms.bug %] description private (visible only
+ to members of the <strong>[% Param('insidergroup') FILTER html %]</strong> group)
+ </label>
+ [% END %]
</fieldset>
</div>
</td>
@@ -629,6 +622,13 @@ TUI_hide_default('attachment_text_field');
[% END %]
<tr>
+ <th>Status Whiteboard:</th>
+ <td colspan="3">
+ <input id="status_whiteboard" name="status_whiteboard" size="70"
+ value="[% status_whiteboard FILTER html %]">
+ </td>
+ </tr>
+ <tr>
[% INCLUDE "bug/field-label.html.tmpl"
field = bug_fields.dependson editable = 1
%]
diff --git a/template/en/default/bug/edit.html.tmpl b/template/en/default/bug/edit.html.tmpl
index ab150dd31..b44d7c9b0 100644
--- a/template/en/default/bug/edit.html.tmpl
+++ b/template/en/default/bug/edit.html.tmpl
@@ -32,21 +32,13 @@
<script type="text/javascript">
<!--
-
- /* Outputs a link to call replyToComment(); used to reduce HTML output */
- function addReplyLink(id, real_id) {
- /* XXX this should really be updated to use the DOM Core's
- * createElement, but finding a container isn't trivial.
- */
- [% IF user.settings.quote_replies.value != 'off' %]
- document.write('[<a href="#add_comment" onclick="replyToComment(' +
- id + ',' + real_id + '); return false;">reply<' + '/a>]');
- [% END %]
- }
-
/* Adds the reply text to the `comment' textarea */
- function replyToComment(id, real_id) {
- var prefix = "(In reply to comment #" + id + ")\n";
+ function replyToComment(id, real_id, name) {
+ var prefix = "(In reply to ";
+ if (name) {
+ prefix = prefix + name + " from";
+ }
+ prefix = prefix + " comment #" + id + ")\n";
var replytext = "";
[% IF user.settings.quote_replies.value == 'quoted_reply' %]
/* pre id="comment_name_N" */
@@ -57,12 +49,15 @@
replytext = prefix;
[% END %]
- [% IF user.is_insider %]
- if (document.getElementById('isprivate_' + real_id).checked) {
- document.getElementById('newcommentprivacy').checked = 'checked';
- updateCommentTagControl(document.getElementById('newcommentprivacy'), 'comment');
- }
- [% END %]
+ [% IF user.is_insider %]
+ if (document.getElementById('isprivate_' + real_id).checked) {
+ document.getElementById('newcommentprivacy').checked = 'checked';
+ updateCommentTagControl(document.getElementById('newcommentprivacy'), 'comment');
+ }
+ [% END %]
+
+ /* Remove embedded links to attachment details */
+ replytext = replytext.replace(/(attachment\s+\d+)(\s+\[[^\[]+\])+/gi, '$1');
/* <textarea id="comment"> */
var textarea = document.getElementById('comment');
@@ -71,33 +66,6 @@
textarea.focus();
}
- if (typeof Node == 'undefined') {
- /* MSIE doesn't define Node, so provide a compatibility object */
- window.Node = {
- TEXT_NODE: 3,
- ENTITY_REFERENCE_NODE: 5
- };
- }
-
- /* Concatenates all text from element's childNodes. This is used
- * instead of innerHTML because we want the actual text (and
- * innerText is non-standard).
- */
- function getText(element) {
- var child, text = "";
- for (var i=0; i < element.childNodes.length; i++) {
- child = element.childNodes[i];
- var type = child.nodeType;
- if (type == Node.TEXT_NODE || type == Node.ENTITY_REFERENCE_NODE) {
- text += child.nodeValue;
- } else {
- /* recurse into nodes of other types */
- text += getText(child);
- }
- }
- return text;
- }
-
[% IF user.is_timetracker %]
var fRemainingTime = [% bug.remaining_time %]; // holds the original value
function adjustRemainingTime() {
@@ -116,7 +84,6 @@
// if the remaining time is changed manually, update fRemainingTime
fRemainingTime = document.changeform.remaining_time.value;
}
-
[% END %]
/* Index all classifications so we can keep track of the classification
@@ -164,17 +131,26 @@
[% PROCESS section_url_keyword_whiteboard %]
[% PROCESS section_spacer %]
-
- [%# *** Dependencies *** %]
+
+ [%# *** Dependencies and duplicates *** %]
+ [% PROCESS section_duplicates %]
+
[% PROCESS section_dependson_blocks %]
-
+
+ [% IF user.id %]
+ <tr>
+ <td colspan="2">
+ [% PROCESS commit_button id="_top"%]
+ </td>
+ </tr>
+ [% END %]
</table>
</td>
<td>
<div class="bz_column_spacer">&nbsp;</div>
</td>
[%# 2nd Column %]
- <td id="bz_show_bug_column_2" class="bz_show_bug_column">
+ <td id="bz_show_bug_column_2" class="bz_show_bug_column_table" valign="top">
<table cellpadding="3" cellspacing="1">
[%# *** Reported and modified dates *** %]
[% PROCESS section_dates %]
@@ -182,16 +158,16 @@
[% PROCESS section_cclist %]
[% PROCESS section_spacer %]
-
- [% PROCESS section_see_also %]
+
+ [% PROCESS section_flags %]
- [% PROCESS section_customfields %]
+ [% PROCESS section_see_also %]
[% PROCESS section_spacer %]
+ [% PROCESS section_customfields %]
+
[% Hook.process("after_custom_fields") %]
-
- [% PROCESS section_flags %]
</table>
</td>
@@ -220,6 +196,8 @@
[% IF user.settings.comment_box_position.value == 'before_comments' %]
[% PROCESS comment_box %]
+ [% ELSE %]
+ [% PROCESS summon_comment_box %]
[% END %]
</td>
<td>
@@ -238,7 +216,10 @@
[% IF user.settings.comment_box_position.value == 'after_comments' %]
<hr>
[% PROCESS comment_box %]
- [% END %]
+ [% ELSE %]
+ [% PROCESS summon_comment_box %]
+ [% END %]
+
</form>
@@ -249,7 +230,10 @@
[% BLOCK section_title %]
[%# That's the main table, which contains all editable fields. %]
<div class="bz_alias_short_desc_container edit_form">
- [% PROCESS commit_button id="_top"%]
+ <span class="last_comment_link">
+ <a href="#c[% bug.comments.size - 1 %]"
+ accesskey="l"><b>L</b>ast Comment</a>
+ </span>
<a href="show_bug.cgi?id=[% bug.bug_id %]">
[%-# %]<b>[% terms.Bug %]&nbsp;[% bug.bug_id FILTER html %]</b>
[%-# %]</a> -<span id="summary_alias_container" class="bz_default_hidden">
@@ -408,6 +392,30 @@
</span>
</td>
</tr>
+ [% IF Param('usestatuswhiteboard') %]
+ <tr>
+ <td class="field_label">
+ <label for="status_whiteboard" accesskey="w"><b><u>W</u>hiteboard</b></label>:
+ </td>
+ [% PROCESS input inputname => "status_whiteboard" size => "40" colspan => 2 %]
+ </tr>
+ [% END %]
+
+ [% IF use_keywords %]
+ <tr>
+ <td class="field_label">
+ <label for="keywords" accesskey="k">
+ <b><a href="describekeywords.cgi"><u>K</u>eywords</a></b></label>:
+ </td>
+ <td class="field_value" colspan="2">
+ [% INCLUDE bug/field.html.tmpl
+ bug = bug, field = bug_fields.keywords, value = bug.keywords
+ editable = bug.check_can_change_field("keywords", 0, 1),
+ no_tds = 1
+ %]
+ </td>
+ </tr>
+ [% END %]
[% END %]
[%############################################################################%]
@@ -568,14 +576,17 @@
<td>
[% IF bug.check_can_change_field("bug_file_loc", 0, 1) %]
<span id="bz_url_edit_container" class="bz_default_hidden">
- [% IF is_safe_url(bug.bug_file_loc) %]
- <a href="[% bug.bug_file_loc FILTER html %]" target="_blank"
- title="[% bug.bug_file_loc FILTER html %]">
- [% bug.bug_file_loc FILTER truncate(40) FILTER html %]</a>
- [% ELSE %]
- [% bug.bug_file_loc FILTER html %]
- [% END %]
- (<a href="#" id="bz_url_edit_action">edit</a>)</span>
+ <a href="[% bug.bug_file_loc FILTER html %]" target="_blank"
+ title="[% bug.bug_file_loc FILTER html %]"
+ [% IF NOT is_safe_url(bug.bug_file_loc) %]
+ onclick="return confirm(
+ 'This is considered an unsafe URL and could possibly be harmful. '
+ + 'The full URL is:\n\n[% bug.bug_file_loc FILTER js FILTER html %]\n\n'
+ + 'Continue?')"
+ [% END %]>
+ [% bug.bug_file_loc FILTER truncate(40) FILTER html %]</a>
+ (<a href="#" id="bz_url_edit_action">edit</a>)
+ </span>
[% END %]
<span id="bz_url_input_area">
[% url_output = PROCESS input no_td=1 inputname => "bug_file_loc" size => "40" colspan => 2 %]
@@ -597,36 +608,34 @@
[% END %]
</td>
</tr>
-
- [% IF Param('usestatuswhiteboard') %]
- <tr>
- <td class="field_label">
- <label for="status_whiteboard" accesskey="w"><b><u>W</u>hiteboard</b></label>:
- </td>
- [% PROCESS input inputname => "status_whiteboard" size => "40" colspan => 2 %]
- </tr>
- [% END %]
-
- [% IF use_keywords %]
- <tr>
- <td class="field_label">
- <label for="keywords" accesskey="k">
- <b><a href="describekeywords.cgi"><u>K</u>eywords</a></b></label>:
- </td>
- <td class="field_value" colspan="2">
- [% INCLUDE bug/field.html.tmpl
- bug = bug, field = bug_fields.keywords, value = bug.keywords
- editable = bug.check_can_change_field("keywords", 0, 1),
- no_tds = 1
- %]
- </td>
- </tr>
- [% END %]
[% END %]
[%############################################################################%]
-[%# Block for Depends On / Blocks #%]
+[%# Block for Duplicates #%]
[%############################################################################%]
+
+[% BLOCK section_duplicates %]
+ [% RETURN UNLESS bug.duplicates.size %]
+ <tr>
+ <td class="field_label">
+ <label for="duplicates">Duplicates</label>:
+ </td>
+ <td class="field_value" colspan="2">
+ <span id="duplicates">
+ [% FOREACH dupe = bug.duplicates %]
+ [% dupe.id FILTER bug_link(dupe, use_alias => 1) FILTER none %][% " " %]
+ [% END %]
+ </span>
+ (<a href="buglist.cgi?bug_id=[% bug.duplicate_ids.join(",") FILTER html %]">
+ [%-%]view as [% terms.bug %] list</a>)
+ </td>
+ </tr>
+[% END %]
+
+[%############################################################################%]
+[%# Block for Depends On / Blocks #%]
+[%############################################################################%]
+
[% BLOCK section_dependson_blocks %]
<tr>
[% INCLUDE dependencies
@@ -812,10 +821,18 @@
[% IF user.id || bug.cc.size %]
<span id="cc_edit_area_showhide_container" class="bz_default_hidden">
(<a href="#" id="cc_edit_area_showhide">[% IF user.id %]edit[% ELSE %]show[% END %]</a>)
- </span>
+ [% IF user.id %]
+ <div id="cc_list_num_users">
+ <ul class="cc_list_display">
+ [% FOREACH c = bug.cc %]
+ <li>[% c FILTER email FILTER html %]</li>
+ [% END %]
+ </ul>
+ </div>
+ [% END %]
+ </span>
[% END %]
<div id="cc_edit_area">
- <br>
[% IF user.id %]
<div>
<div><label for="cc"><b>Add</b></label></div>
@@ -922,6 +939,8 @@
[%# *** Custom Fields *** %]
[% USE Bugzilla %]
[% FOREACH field = Bugzilla.active_custom_fields %]
+ [% NEXT IF NOT user.id AND field.value == "---" %]
+ [% NEXT IF cf_hidden_in_product(field.name, bug.product, bug.component, 1) %]
<tr>
[% PROCESS bug/field.html.tmpl value = bug.${field.name}
editable = bug.check_can_change_field(field.name, 0, 1)
@@ -1127,6 +1146,21 @@
</div>
[% END %]
+[% BLOCK summon_comment_box %]
+<div id="comment_top_hat">
+ <script type="text/javascript">
+ function summonCommentBox() {
+ var commentbox = document.getElementById('add_comment');
+ document.getElementById('comment_top_hat').appendChild(commentbox);
+ document.getElementById('wave_wand').style.display = 'none';
+ }
+ </script>
+ <p id="wave_wand">
+ <a href="javascript:summonCommentBox()"><i>Summon comment box</i></a>
+ </p>
+</div>
+[% END %]
+
[%############################################################################%]
[%# Block for SELECT fields #%]
[%############################################################################%]
diff --git a/template/en/default/bug/field.html.tmpl b/template/en/default/bug/field.html.tmpl
index 323b4b6be..bb9c553e5 100644
--- a/template/en/default/bug/field.html.tmpl
+++ b/template/en/default/bug/field.html.tmpl
@@ -125,6 +125,30 @@
[% END %]
[% FOREACH legal_value = legal_values %]
[% NEXT IF NOT legal_value.is_active AND NOT value.contains(legal_value.name).size %]
+
+ [%# Purpose: hide field values from those who can't change them %]
+ [% IF field.name.match("^cf_blocking_") OR
+ field.name.match("^cf_status_") OR
+ field.name.match("^cf_tracking_") OR
+ field.name == "resolution" %]
+ [% NEXT UNLESS bug.check_can_change_field(field.name, '---', legal_value.name) OR
+ value.contains(legal_value.name).size %]
+ [% END %]
+
+ [% IF field.name == "resolution" &&
+ legal_value.name != bug.resolution %]
+ [% r = legal_value.name %]
+ [% IF bug.user.canconfirm &&
+ !(bug.user.canedit || bug.user.isreporter) %]
+ [% NEXT IF r != "WORKSFORME" && r != "INCOMPLETE" %]
+ [% END %]
+ [% IF bug.user.isreporter &&
+ !(bug.user.canconfirm || bug.user.canedit) %]
+ [% NEXT IF r == "INCOMPLETE" %]
+ [% END %]
+ [% NEXT IF r == "EXPIRED" %]
+ [% END %]
+
<option value="[% legal_value.name FILTER html %]"
id="v[% legal_value.id FILTER html %]_
[%- field.name FILTER html %]"
diff --git a/template/en/default/bug/process/updates-disabled.html.tmpl b/template/en/default/bug/process/updates-disabled.html.tmpl
new file mode 100644
index 000000000..5ea84d476
--- /dev/null
+++ b/template/en/default/bug/process/updates-disabled.html.tmpl
@@ -0,0 +1,73 @@
+[%# The contents of this file are subject to the Mozilla Public License Version
+ # 1.1 (the "License"); you may not use this file except in compliance with
+ # the License. You may obtain a copy of the License at
+ # http://www.mozilla.org/MPL/
+ #
+ # Software distributed under the License is distributed on an "AS IS" basis,
+ # WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+ # for the specific language governing rights and limitations under the
+ # License.
+ #
+ # The Original Code is the Bugzilla Bug Tracking System.
+ #
+ # The Initial Developer of the Original Code is
+ # the Mozilla Foundation.
+ # Portions created by the Initial Developer are Copyright (C) 2011
+ # the Initial Developer. All Rights Reserved.
+ #
+ # Contributor(s): Byron Jones <glob@mozilla.com>
+ #
+ #%]
+[% PROCESS global/variables.none.tmpl %]
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
+<html>
+<head>
+<title>[% terms.Bugzilla %] - [% terms.Bug %] Updates Temporarily Suspended</title>
+<style type="text/css">
+body {
+ margin: 2em;
+ background-color: #455372;
+ color: #fff;
+ font-family: verdana, sans-serif;
+ font-size: small;
+}
+a {
+ color: #fff;
+ text-decoration: underline;
+}
+#buggie {
+ float: left;
+}
+#content {
+ margin-left: 100px;
+ max-width: 600px;
+}
+</style>
+</head>
+<body>
+<img src="images/buggie.png" id="buggie" alt="buggie">
+<div id="content">
+<h1>[% terms.Bug %] Updates Temporarily Suspended</h1>
+
+<p>
+We are currently adding a field to [% terms.Bugzilla %]. This requires us to
+prevent updates to [% terms.bugs %] for the duration of the database schema
+change to add the field (usually 3 to 5 minutes).
+</p>
+
+<p>
+<b>You should be able to leave this page open, wait a minute or two, then hit
+reload or refresh in your browser</b> (and OK any request to re-send the form
+data) to complete your [% terms.bug %] change. Once this maintenance is
+complete, your change will succeed and you won't get this page any more.
+</p>
+
+<p>
+Only updates to [% terms.bugs %] are being blocked by this page, any other
+activities in [% terms.Bugzilla %] are still fair game. <a href="index.cgi"
+target="_blank">Open [% terms.Bugzilla %] in a new tab/window</a> if you'd
+like, to continue working on other things while waiting.
+</p>
+</div>
+</body>
+</html>
diff --git a/template/en/default/bug/show-multiple.html.tmpl b/template/en/default/bug/show-multiple.html.tmpl
index 33dde14a3..03ce294c5 100644
--- a/template/en/default/bug/show-multiple.html.tmpl
+++ b/template/en/default/bug/show-multiple.html.tmpl
@@ -180,6 +180,7 @@
[% USE Bugzilla %]
[% field_counter = 0 %]
[% FOREACH field = Bugzilla.active_custom_fields %]
+ [% NEXT IF cf_hidden_in_product(field.name, bug.product, bug.component) %]
[% field_counter = field_counter + 1 %]
[%# Odd-numbered fields get an opening <tr> %]
[% '<tr>' IF field_counter % 2 %]
diff --git a/template/en/default/bug/show.xml.tmpl b/template/en/default/bug/show.xml.tmpl
index dae207f26..cb323d229 100644
--- a/template/en/default/bug/show.xml.tmpl
+++ b/template/en/default/bug/show.xml.tmpl
@@ -20,8 +20,10 @@
#
#%]
[% PROCESS bug/time.html.tmpl %]
+[% USE Bugzilla %]
+[% cgi = Bugzilla.cgi %]
<?xml version="1.0" [% IF Param('utf8') %]encoding="UTF-8" [% END %]standalone="yes" ?>
-<!DOCTYPE bugzilla SYSTEM "[% urlbase FILTER html %]bugzilla.dtd">
+<!DOCTYPE bugzilla [% IF cgi.param('dtd') %][[% PROCESS pages/bugzilla.dtd.tmpl %]][% ELSE %]SYSTEM "[% urlbase FILTER xml %]page.cgi?id=bugzilla.dtd"[% END %]>
<bugzilla version="[% constants.BUGZILLA_VERSION %]"
urlbase="[% urlbase FILTER xml %]"
@@ -142,6 +144,7 @@
[% ELSIF field == "see_also" %]
[% val = val.name %]
[% END %]
+ [% NEXT IF cf_hidden_in_product(field.name, bug.product, bug.component) %]
<[% field %][% IF name != '' %] name="[% name FILTER xml %]"[% END -%]>
[%- val FILTER xml %]</[% field %]>
[% END %]