summaryrefslogtreecommitdiffstats
path: root/template
diff options
context:
space:
mode:
authorbugreport%peshkin.net <>2004-08-21 06:49:17 +0200
committerbugreport%peshkin.net <>2004-08-21 06:49:17 +0200
commit88d26275229b5f52f435130496169766313c87b7 (patch)
treec71532045500b6e2335b1e5e2512d10b8846551b /template
parent2f9f28d0bfb1f321d1548844a41aaf2d51789695 (diff)
downloadbugzilla-88d26275229b5f52f435130496169766313c87b7.tar.gz
bugzilla-88d26275229b5f52f435130496169766313c87b7.tar.xz
Bug 224208 Add a higher level of categorization (.ie departments, locations, etc.)
patch by Albert Ting r=joel, glob a=myk
Diffstat (limited to 'template')
-rw-r--r--template/en/default/admin/classifications/add.html.tmpl45
-rw-r--r--template/en/default/admin/classifications/del.html.tmpl60
-rw-r--r--template/en/default/admin/classifications/delete.html.tmpl31
-rw-r--r--template/en/default/admin/classifications/edit.html.tmpl70
-rw-r--r--template/en/default/admin/classifications/new.html.tmpl32
-rw-r--r--template/en/default/admin/classifications/reclassify.html.tmpl84
-rw-r--r--template/en/default/admin/classifications/select.html.tmpl70
-rw-r--r--template/en/default/admin/classifications/update.html.tmpl37
-rw-r--r--template/en/default/admin/products/groupcontrol/edit.html.tmpl2
-rw-r--r--template/en/default/bug/edit.html.tmpl5
-rw-r--r--template/en/default/bug/show-multiple.html.tmpl10
-rw-r--r--template/en/default/filterexceptions.pl1
-rw-r--r--template/en/default/global/choose-classification.html.tmpl65
-rw-r--r--template/en/default/global/field-descs.none.tmpl1
-rw-r--r--template/en/default/global/useful-links.html.tmpl11
-rw-r--r--template/en/default/global/user-error.html.tmpl38
-rw-r--r--template/en/default/search/form.html.tmpl106
-rw-r--r--template/en/default/search/search-advanced.html.tmpl35
-rw-r--r--template/en/default/search/search-help.html.tmpl7
-rw-r--r--template/en/default/search/search-report-graph.html.tmpl8
-rw-r--r--template/en/default/search/search-report-select.html.tmpl2
-rw-r--r--template/en/default/search/search-report-table.html.tmpl8
-rw-r--r--template/en/default/search/search-specific.html.tmpl22
23 files changed, 702 insertions, 48 deletions
diff --git a/template/en/default/admin/classifications/add.html.tmpl b/template/en/default/admin/classifications/add.html.tmpl
new file mode 100644
index 000000000..d6a7c3880
--- /dev/null
+++ b/template/en/default/admin/classifications/add.html.tmpl
@@ -0,0 +1,45 @@
+[%# 1.0@bugzilla.org %]
+[%# 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 Netscape Communications
+ # Corporation. Portions created by Netscape are
+ # Copyright (C) 1998 Netscape Communications Corporation. All
+ # Rights Reserved.
+ #
+ # Contributor(s): Albert Ting <alt@sonic.net>
+ #%]
+
+[% PROCESS global/header.html.tmpl
+ title = "Add new classification"
+%]
+
+<form method=post action="editclassifications.cgi">
+ <table border=0 cellpadding=4 cellspacing=0>
+ <tr>
+ <th align="right">Classification:</th>
+ <td><input size=64 maxlength=64 name="classification"></td>
+ </tr>
+ <tr>
+ <th align="right">Description:</th>
+ <td><textarea rows=4 cols=64 wrap=virtual name="description"></textarea></td>
+ </tr>
+ </table>
+ <hr>
+ <input type=submit value="Add">
+ <input type=hidden name="action" value="new">
+</FORM>
+
+<p>Back to the <a href="./">main [% terms.bugs %] page</a>
+or <a href="editclassifications.cgi"> edit</a> more classifications.
+
+[% PROCESS global/footer.html.tmpl %]
diff --git a/template/en/default/admin/classifications/del.html.tmpl b/template/en/default/admin/classifications/del.html.tmpl
new file mode 100644
index 000000000..008971562
--- /dev/null
+++ b/template/en/default/admin/classifications/del.html.tmpl
@@ -0,0 +1,60 @@
+[%# 1.0@bugzilla.org %]
+[%# 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 Netscape Communications
+ # Corporation. Portions created by Netscape are
+ # Copyright (C) 1998 Netscape Communications Corporation. All
+ # Rights Reserved.
+ #
+ # Contributor(s): Albert Ting <alt@sonic.net>
+ #%]
+
+[% PROCESS global/header.html.tmpl
+ title = "Delete classification"
+%]
+
+<table border=1 cellpadding=4 cellspacing=0>
+<tr bgcolor="#6666ff">
+ <th valign="top" align="left">Part</th>
+ <th valign="top" align="left">Value</th>
+
+</tr><tr>
+ <td valign="top">Classification:</td>
+ <td valign="top">[% classification FILTER html %]</td>
+
+</tr><tr>
+ <td valign="top">Description:</td>
+ <td valign="top">
+ [% IF description %]
+ [% description FILTER html %]
+ [% ELSE %]
+ <font color="red">description missing</font>
+ [% END %]
+ </td>
+
+</tr>
+</table>
+
+<h2>Confirmation</h2>
+
+<p>Do you really want to delete this classification?<p>
+<form method=post action="editclassifications.cgi">
+ <input type=submit value="Yes, delete">
+ <input type=hidden name="action" value="delete">
+ <input type=hidden name="classification" value="[% classification FILTER html %]">
+</form>
+
+<p>Back to the <a href="./">main [% terms.bugs %] page</a>
+or <a href="editclassifications.cgi"> edit</a> more classifications.
+
+[% PROCESS global/footer.html.tmpl %]
diff --git a/template/en/default/admin/classifications/delete.html.tmpl b/template/en/default/admin/classifications/delete.html.tmpl
new file mode 100644
index 000000000..b2ec26cbb
--- /dev/null
+++ b/template/en/default/admin/classifications/delete.html.tmpl
@@ -0,0 +1,31 @@
+[%# 1.0@bugzilla.org %]
+[%# 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 Netscape Communications
+ # Corporation. Portions created by Netscape are
+ # Copyright (C) 1998 Netscape Communications Corporation. All
+ # Rights Reserved.
+ #
+ # Contributor(s): Albert Ting <alt@sonic.net>
+ #%]
+
+[% PROCESS global/header.html.tmpl
+ title = "Classification deleted"
+%]
+
+Classification [% classification FILTER html %] deleted.<br>
+
+<p>Back to the <a href="./">main [% terms.bugs %] page</a>
+or <a href="editclassifications.cgi"> edit</a> more classifications.
+
+[% PROCESS global/footer.html.tmpl %]
diff --git a/template/en/default/admin/classifications/edit.html.tmpl b/template/en/default/admin/classifications/edit.html.tmpl
new file mode 100644
index 000000000..ebc16e82e
--- /dev/null
+++ b/template/en/default/admin/classifications/edit.html.tmpl
@@ -0,0 +1,70 @@
+[%# 1.0@bugzilla.org %]
+[%# 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 Netscape Communications
+ # Corporation. Portions created by Netscape are
+ # Copyright (C) 1998 Netscape Communications Corporation. All
+ # Rights Reserved.
+ #
+ # Contributor(s): Albert Ting <alt@sonic.net>
+ #%]
+
+[% PROCESS global/header.html.tmpl
+ title = "Edit classification"
+%]
+
+<form method=post action="editclassifications.cgi">
+ <table border=0 cellpadding=4 cellspacing=0>
+ <tr>
+ <th align="right">Classification:</th>
+ <td><input size=64 maxlength=64 name="classification" value="[% classification FILTER html %]"></TD>
+ </tr>
+ <tr>
+ <th align="right">Description:</th>
+ <td><textarea rows=4 cols=64 name="description">[% description FILTER html %]</textarea></TD>
+ </tr>
+ <tr valign=top>
+ <th align="right"><a href="editproducts.cgi?classification=[% classification FILTER html %]">Edit products</a></th>
+ <td>
+ [% IF products AND products.size > 0 %]
+ <table>
+ [% FOREACH product = products %]
+ <tr>
+ <th align=right valign=top>[% product.name FILTER html %]</th>
+ <td valign=top>
+ [% IF product.description %]
+ [% product.description FILTER html %]
+ [% ELSE %]
+ <font color="red">description missing</font>
+ [% END %]
+ </td>
+ </tr>
+ [% END %]
+ </table>
+ [% ELSE %]
+ <font color="red">none</font>
+ [% END %]
+ </td>
+ </tr>
+ </table>
+
+ <input type=hidden name="classificationold" value="[% classification FILTER html %]">
+ <input type=hidden name="descriptionold" value="[% description FILTER html %]">
+ <input type=hidden name="action" value="update">
+ <input type=submit value="Update">
+</form>
+
+<p>Back to the <a href="./">main [% terms.bugs %] page</a>
+or <a href="editclassifications.cgi"> edit</a> more classifications.
+
+[% PROCESS global/footer.html.tmpl %]
diff --git a/template/en/default/admin/classifications/new.html.tmpl b/template/en/default/admin/classifications/new.html.tmpl
new file mode 100644
index 000000000..c8046b898
--- /dev/null
+++ b/template/en/default/admin/classifications/new.html.tmpl
@@ -0,0 +1,32 @@
+[%# 1.0@bugzilla.org %]
+[%# 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 Netscape Communications
+ # Corporation. Portions created by Netscape are
+ # Copyright (C) 1998 Netscape Communications Corporation. All
+ # Rights Reserved.
+ #
+ # Contributor(s): Albert Ting <alt@sonic.net>
+ #%]
+
+[% PROCESS global/header.html.tmpl
+ title = "Adding new classification"
+%]
+
+OK, done.
+
+<p>Back to the <a href="./">main [% terms.bugs %] page</a>,
+<a href="editproducts.cgi?action=add&amp;classification=[% classification FILTER html %]">add</a> products to this new classification,
+or <a href="editclassifications.cgi"> edit</a> more classifications.
+
+[% PROCESS global/footer.html.tmpl %]
diff --git a/template/en/default/admin/classifications/reclassify.html.tmpl b/template/en/default/admin/classifications/reclassify.html.tmpl
new file mode 100644
index 000000000..d860f67cf
--- /dev/null
+++ b/template/en/default/admin/classifications/reclassify.html.tmpl
@@ -0,0 +1,84 @@
+[%# 1.0@bugzilla.org %]
+[%# 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 Netscape Communications
+ # Corporation. Portions created by Netscape are
+ # Copyright (C) 1998 Netscape Communications Corporation. All
+ # Rights Reserved.
+ #
+ # Contributor(s): Albert Ting <alt@sonic.net>
+ #%]
+
+[% PROCESS global/header.html.tmpl
+ title = "Reclassify products"
+%]
+
+[% main_classification = classification %]
+
+<form method=post action="editclassifications.cgi">
+ <table border=0 cellpadding=4 cellspacing=0>
+ <tr>
+ <td valign="top">Classification:</td>
+ <td valign="top" colspan=3>[% main_classification FILTER html %]</td>
+
+ </tr><tr>
+ <td valign="top">Description:</td>
+ <td valign="top" colspan=3>
+ [% IF description %]
+ [% description FILTER html %]
+ [% ELSE %]
+ <font color="red">description missing</font>
+ [% END %]
+ </td>
+
+ </tr><tr>
+ <td valign="top">Products:</td>
+ <td valign="top">Products</td>
+ <td></td>
+ <td valign="top">[% main_classification FILTER html %] Products</td>
+
+ </tr><tr>
+ <td></td>
+ <td valign="top">
+ <select name="prodlist" id="prodlist" multiple="multiple" size="20">
+ [% FOREACH cl = class_products %]
+ <option value="[% cl.value FILTER html %]">
+ [% cl.name FILTER html %]
+ </option>
+ [% END %]
+ </select></td>
+
+ <td align="center">
+ <input type=submit value=" Add &gt;&gt; " name="add_products"><br><br>
+ <input type=submit value="&lt;&lt; Remove" name="remove_products">
+ </td>
+
+ <td valign="middle" rowspan=2>
+ <select name="myprodlist" id="myprodlist" multiple="multiple" size="20">
+ [% FOREACH product = selected_products %]
+ <option value="[% product FILTER html %]">
+ [% product FILTER html %]
+ </option>
+ [% END %]
+ </select></td>
+ </tr>
+ </table>
+
+ <input type=hidden name="action" value="reclassify">
+ <input type=hidden name="classification" value="[% main_classification FILTER html %]">
+</form>
+
+<p>Back to the <a href="./">main [% terms.bugs %] page</a>,
+or <a href="editclassifications.cgi"> edit</a> more classifications.
+
+[% PROCESS global/footer.html.tmpl %]
diff --git a/template/en/default/admin/classifications/select.html.tmpl b/template/en/default/admin/classifications/select.html.tmpl
new file mode 100644
index 000000000..5908375d2
--- /dev/null
+++ b/template/en/default/admin/classifications/select.html.tmpl
@@ -0,0 +1,70 @@
+[%# 1.0@bugzilla.org %]
+[%# 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 Netscape Communications
+ # Corporation. Portions created by Netscape are
+ # Copyright (C) 1998 Netscape Communications Corporation. All
+ # Rights Reserved.
+ #
+ # Contributor(s): Albert Ting <alt@sonic.net>
+ #%]
+
+[% PROCESS global/header.html.tmpl
+ title = "Select classification"
+%]
+
+[% filt_classification = classification FILTER html %]
+
+<table border=1 cellpadding=4 cellspacing=0>
+ <tr bgcolor="#6666ff">
+ <th align="left">Edit Classification ...</th>
+ <th align="left">Description</th>
+ <th align="left">Products</th>
+ <th align="left">Action</th>
+ </tr>
+
+ [% FOREACH cl = classifications %]
+ <tr>
+ <td valign="top"><a href="editclassifications.cgi?action=edit&amp;classification=[% cl.classification FILTER html %]"><b>[% cl.classification FILTER html %]</b></a></td>
+ <td valign="top">
+ [% IF cl.description %]
+ [% cl.description FILTER html %]
+ [% ELSE %]
+ <font color="red">none</font>
+ [% END %]
+ </td>
+ [% IF (cl.id == 1) %]
+ <td valign="top">[% cl.total FILTER html %]</td>
+ [% ELSE %]
+ <td valign="top"><a href="editclassifications.cgi?action=reclassify&amp;classification=[% cl.classification FILTER html %]">reclassify ([% cl.total FILTER html %])</a></td>
+ [% END %]
+
+ [%# don't allow user to delete the default id. %]
+ [% IF (cl.id == 1) %]
+ <td valign="top">&nbsp;</td>
+ [% ELSE %]
+ <td valign="top"><a href="editclassifications.cgi?action=del&amp;classification=[% cl.classification FILTER html %]">delete</a></td>
+ [% END %]
+ </tr>
+ [% END %]
+
+ <tr>
+ <td valign="top" colspan=3>Add a new classification</td>
+ <td valign="top" align="center"><a href="editclassifications.cgi?action=add">Add</a></td>
+ </tr>
+</table>
+
+<p>Back to the <a href="./">main [% terms.bugs %] page</a>
+or <a href="editclassifications.cgi"> edit</a> more classifications.
+
+[% PROCESS global/footer.html.tmpl %]
diff --git a/template/en/default/admin/classifications/update.html.tmpl b/template/en/default/admin/classifications/update.html.tmpl
new file mode 100644
index 000000000..3ad7bbc69
--- /dev/null
+++ b/template/en/default/admin/classifications/update.html.tmpl
@@ -0,0 +1,37 @@
+[%# 1.0@bugzilla.org %]
+[%# 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 Netscape Communications
+ # Corporation. Portions created by Netscape are
+ # Copyright (C) 1998 Netscape Communications Corporation. All
+ # Rights Reserved.
+ #
+ # Contributor(s): Albert Ting <alt@sonic.net>
+ #%]
+
+[% PROCESS global/header.html.tmpl
+ title = "Update classification"
+%]
+
+[% IF updated_description %]
+ Updated description.<br>
+[% END %]
+
+[% IF updated_classification %]
+ Updated classification name.<br>
+[% END %]
+
+<p>Back to the <a href="./">main [% terms.bugs %] page</a>
+or <a href="editclassifications.cgi"> edit</a> more classifications.
+
+[% PROCESS global/footer.html.tmpl %]
diff --git a/template/en/default/admin/products/groupcontrol/edit.html.tmpl b/template/en/default/admin/products/groupcontrol/edit.html.tmpl
index 85816398b..6bd30040d 100644
--- a/template/en/default/admin/products/groupcontrol/edit.html.tmpl
+++ b/template/en/default/admin/products/groupcontrol/edit.html.tmpl
@@ -22,6 +22,7 @@
[% PROCESS global/variables.none.tmpl %]
[% filt_product = product FILTER html %]
+[% filt_classification = classification FILTER html %]
[% PROCESS global/header.html.tmpl
title = "Edit Group Controls for '$filt_product'"
%]
@@ -29,6 +30,7 @@
<form method="post" action="editproducts.cgi">
<input type="hidden" name="action" value="updategroupcontrols">
<input type="hidden" name="product" value="[% filt_product %]">
+ <input type="hidden" name="classification" value="[% filt_classification %]">
<table id="form" cellspacing="0" cellpadding="4" border="1">
<tr bgcolor="#6666ff">
diff --git a/template/en/default/bug/edit.html.tmpl b/template/en/default/bug/edit.html.tmpl
index f4c68bb4d..b898afee1 100644
--- a/template/en/default/bug/edit.html.tmpl
+++ b/template/en/default/bug/edit.html.tmpl
@@ -119,6 +119,11 @@
<table cellspacing="1" cellpadding="1" border="0">
<tr>
<td align="right">
+ [% IF Param('useclassification') %]
+ [% IF bug.classification_id != "1" %]
+ <b>[[% bug.classification FILTER html %]]</b>
+ [% END %]
+ [% END %]
<b>[% terms.Bug %]#:</b>
</td>
<td>
diff --git a/template/en/default/bug/show-multiple.html.tmpl b/template/en/default/bug/show-multiple.html.tmpl
index 6b48feb00..8cf86dd5f 100644
--- a/template/en/default/bug/show-multiple.html.tmpl
+++ b/template/en/default/bug/show-multiple.html.tmpl
@@ -62,8 +62,14 @@
([% bug.alias FILTER html %])
[% END %]
</td>
- [% PROCESS cell attr = { description => "Product",
- name => "product" } %]
+ <td>
+ <b> Product: </b>&nbsp;
+ [% IF Param("useclassification") %]
+ [[% bug.classification FILTER html %]]&nbsp;
+ [% END %]
+ [% bug.product FILTER html %]
+ </td>
+
[% PROCESS cell attr = { description => "Version",
name => "version" } %]
[% PROCESS cell attr = { description => "Platform",
diff --git a/template/en/default/filterexceptions.pl b/template/en/default/filterexceptions.pl
index 8d25e2536..c1921a908 100644
--- a/template/en/default/filterexceptions.pl
+++ b/template/en/default/filterexceptions.pl
@@ -500,6 +500,7 @@
],
'admin/products/groupcontrol/edit.html.tmpl' => [
+ 'filt_classification',
'filt_product',
'group.bugcount',
'group.id',
diff --git a/template/en/default/global/choose-classification.html.tmpl b/template/en/default/global/choose-classification.html.tmpl
new file mode 100644
index 000000000..b7b8fb66e
--- /dev/null
+++ b/template/en/default/global/choose-classification.html.tmpl
@@ -0,0 +1,65 @@
+<!-- 1.0@bugzilla.org -->
+
+[%# 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 Albert Ting
+ #
+ # Contributor(s): Albert Ting <alt@sonic.net>
+ #%]
+
+[%# INTERFACE:
+ # classdesc: hash. May be empty. The hash keys are the classifications, and the values
+ # are their descriptions.
+ #%]
+
+[% IF target == "enter_bug.cgi" %]
+ [% title = "Select Classification" %]
+ [% h2 = "Please select the classification." %]
+[% END %]
+
+[% DEFAULT title = "Choose the classification" %]
+[% PROCESS global/header.html.tmpl %]
+
+<table>
+
+[% IF Param('showallproducts') %]
+ <tr>
+ <th align="right" valign="center" height=50>
+ <a href="[% target FILTER url_quote %]?classification=__all
+ [% IF format %]&amp;format=[% format FILTER url_quote %][% END %]">
+ All</a>:
+ </th>
+
+ <td valign="center">&nbsp;Show all products</td>
+ </tr>
+[% END %]
+
+[% FOREACH p = classdesc.keys.sort %]
+ [% IF classifications.$p.size > 0 %]
+ <tr>
+ <th align="right" valign="top">
+ <a href="[% target FILTER url_quote %]?classification=[% p FILTER url_quote %]
+ [% IF format %]&amp;format=[% format FILTER url_quote %][% END %]">
+ [% p FILTER html %]</a>:
+ </th>
+
+ [% IF classdesc.$p %]
+ <td valign="top">&nbsp;[% classdesc.$p FILTER html %]</td>
+ [% END %]
+ </tr>
+ [% END %]
+[% END %]
+
+</table>
+
+[% PROCESS global/footer.html.tmpl %]
diff --git a/template/en/default/global/field-descs.none.tmpl b/template/en/default/global/field-descs.none.tmpl
index 7a21ca056..1080e8e44 100644
--- a/template/en/default/global/field-descs.none.tmpl
+++ b/template/en/default/global/field-descs.none.tmpl
@@ -32,6 +32,7 @@
"bug_status" => "Status",
"changeddate" => "Last Changed Date",
"cc" => "CC",
+ "classification" => "Classification",
"cclist_accessible" => "CC list accessible?",
"component_id" => "Component ID",
"component" => "Component",
diff --git a/template/en/default/global/useful-links.html.tmpl b/template/en/default/global/useful-links.html.tmpl
index 7e568372c..8a11b2ad3 100644
--- a/template/en/default/global/useful-links.html.tmpl
+++ b/template/en/default/global/useful-links.html.tmpl
@@ -77,8 +77,17 @@
IF user.groups.tweakparams %]
[% ' | <a href="editusers.cgi">Users</a>' IF user.groups.editusers
|| user.can_bless %]
- [% ' | <a href="editproducts.cgi">Products</a>'
+ [% IF Param('useclassification') %]
+ [% IF user.groups.editclassifications %]
+ [% ' | <a href="editclassifications.cgi">Classifications</a>' %]
+ [% END %]
+ [% IF user.groups.editcomponents %]
+ [% ' | <a href="editproducts.cgi">Products</a>' %]
+ [% END %]
+ [% ELSE %]
+ [% ' | <a href="editproducts.cgi">Products</a>'
IF user.groups.editcomponents %]
+ [% END %]
[% ' | <a href="editflagtypes.cgi">Flags</a>'
IF user.groups.editcomponents %]
[% ' | <a href="editgroups.cgi">Groups</a>'
diff --git a/template/en/default/global/user-error.html.tmpl b/template/en/default/global/user-error.html.tmpl
index a17b1275b..7638806cf 100644
--- a/template/en/default/global/user-error.html.tmpl
+++ b/template/en/default/global/user-error.html.tmpl
@@ -142,6 +142,40 @@
[% title = "Comment Too Long" %]
Comments cannot be longer than 65,535 characters.
+ [% ELSIF error == "auth_classification_not_enabled" %]
+ [% title = "Classification Not Enabled" %]
+ Sorry, classification is not enabled.
+
+ [% ELSIF error == "auth_cant_edit_classifications" %]
+ [% title = "Access Denied" %]
+ Sorry, you aren't a member of the 'editclassifications' group, and so
+ you aren't allowed to add, modify or delete classifications.
+
+ [% ELSIF error == "classification_not_specified" %]
+ [% title = "You Must Supply A Classification Name" %]
+ You must enter a classification name.
+
+ [% ELSIF error == "classification_already_exists" %]
+ [% title = "Classification Already Exists" %]
+ A classification with the name '[% name FILTER html %]' already exists.
+
+ [% ELSIF error == "classification_doesnt_exist" %]
+ [% title = "Classification Does Not Exist" %]
+ The classification '[% name FILTER html %]' does not exist.
+
+ [% ELSIF error == "classification_not_deletable" %]
+ [% title = "Default Classification Can Not Be Deleted" %]
+ You can not delete the default classification
+
+ [% ELSIF error == "classification_has_products" %]
+ Sorry, there are products for this classification. You
+ must reassign those products to another classification before you
+ can delete this one.
+
+ [% ELSIF error == "cant_delete_default_classification" %]
+ Sorry, but you can not delete the default classification,
+ '[% name FILTER html %]'.
+
[% ELSIF error == "auth_cant_edit_components" %]
[% title = "Access Denied" %]
Sorry, you aren't a member of the 'editcomponents' group, and so
@@ -463,6 +497,10 @@
[% title = "Invalid group name" %]
The group you specified, [% name FILTER html %], is not valid here.
+ [% ELSIF error == "invalid_group_name" %]
+ [% title = "Invalid group name" %]
+ The group you specified, [% name FILTER html %], is not valid here.
+
[% ELSIF error == "invalid_maxrows" %]
[% title = "Invalid Max Rows" %]
The maximum number of rows, '[% maxrows FILTER html %]', must be
diff --git a/template/en/default/search/form.html.tmpl b/template/en/default/search/form.html.tmpl
index f875f3541..77308f28b 100644
--- a/template/en/default/search/form.html.tmpl
+++ b/template/en/default/search/form.html.tmpl
@@ -21,6 +21,81 @@
# Gervase Markham <gerv@gerv.net>
#%]
+<script type="text/javascript" language="JavaScript">
+
+var first_load = true; [%# is this the first time we load the page? %]
+var last_sel = new Array(); [%# caches last selection %]
+
+[% IF Param('useclassification') %]
+var useclassification = true;
+var prods = new Array();
+[% ELSE %]
+var useclassification = false;
+[% END %]
+var cpts = new Array();
+var vers = new Array();
+[% IF Param('usetargetmilestone') %]
+var tms = new Array();
+[% END %]
+
+[%# Create an array of products, indexed by the classification #%]
+
+[% nclass = 0 %]
+[% FOREACH c = classification %]
+ prods[[% nclass FILTER js %]] = [
+ [%- FOREACH item = c.products %]'[% item FILTER js %]'[% ", " UNLESS loop.last %] [%- END -%] ];
+ [% nclass = nclass+1 %]
+[% END %]
+
+[%# Create three arrays of components, versions and target milestones, indexed
+ # numerically according to the product they refer to. #%]
+
+[% n = 0 %]
+[% FOREACH p = product %]
+ [% IF Param('useclassification') %]
+ prods['[% p.name FILTER js %]'] = [% n %]
+ [% END %]
+ cpts[[% n %]] = [
+ [%- FOREACH item = p.components %]'[% item FILTER js %]'[% ", " UNLESS loop.last %] [%- END -%] ];
+ vers[[% n %]] = [
+ [%- FOREACH item = p.versions -%]'[% item FILTER js %]'[% ", " UNLESS loop.last %] [%- END -%] ];
+ [% IF Param('usetargetmilestone') %]
+ tms[[% n %]] = [
+ [%- FOREACH item = p.milestones %]'[% item FILTER js %]'[% ", " UNLESS loop.last %] [%- END -%] ];
+ [% END %]
+ [% n = n+1 %]
+[% END %]
+
+/*
+ * doOnSelectProduct determines which selection should get updated
+ *
+ * - selectmode = 0 - init
+ * selectmode = 1 - classification selected
+ * selectmode = 2 - product selected
+ *
+ * globals:
+ * queryform - string holding the name of the selection form
+ */
+function doOnSelectProduct(selectmode) {
+ var f = document.forms[queryform];
+ milestone = (typeof(f.target_milestone) == "undefined" ?
+ null : f.target_milestone);
+ if (selectmode == 0) {
+ if (useclassification) {
+ selectClassification(f.classification, f.product, f.component, f.version, milestone);
+ } else {
+ selectProduct(f.product, f.component, f.version, milestone);
+ }
+ } else if (selectmode == 1) {
+ selectClassification(f.classification, f.product, f.component, f.version, milestone);
+ } else {
+ selectProduct(f.product, f.component, f.version, milestone);
+ }
+}
+
+</script>
+
+
[% PROCESS global/variables.none.tmpl %]
[% query_variants = [
@@ -56,7 +131,7 @@
<input name="short_desc" size="40" accesskey="s"
value="[% default.short_desc.0 FILTER html %]">
<script language="JavaScript" type="text/javascript"> <!--
- document.forms['queryform'].short_desc.focus();
+ document.forms[queryform].short_desc.focus();
// -->
</script>
</td>
@@ -67,12 +142,35 @@
</td>
</tr>
-[%# *** Product Component Version Target *** %]
-
+[%# *** Classification Product Component Version Target *** %]
<tr>
<td colspan="4">
<table>
<tr>
+ [% IF Param('useclassification') %]
+ <td valign="top">
+ <table>
+ <tr valign="bottom">
+ <th align="left"><u>C</u>lassification:</th>
+ </tr>
+ <tr valign="top">
+ <td align="left">
+ <label for="classification">
+ <select name="classification" multiple="multiple" size="5" id="classification"
+ onchange="doOnSelectProduct(1);">
+ [% FOREACH cat = classification %]
+ <option value="[% cat.name FILTER html %]"
+ [% " selected" IF lsearch(default.classification, cat.name) != -1 %]>
+ [% cat.name FILTER html %]
+ </option>
+ [% END %]
+ </select>
+ </label>
+ </td>
+ </tr>
+ </table>
+ </td>
+ [% END %]
<td valign="top">
<table>
<tr valign="bottom">
@@ -83,7 +181,7 @@
<td align="left">
<label for="product" accesskey="p">
<select name="product" multiple="multiple" size="5" id="product"
- onchange="doOnSelectProduct();">
+ onchange="doOnSelectProduct(2);">
[% FOREACH p = product %]
<option value="[% p.name FILTER html %]"
[% " selected" IF lsearch(default.product, p.name) != -1 %]>
diff --git a/template/en/default/search/search-advanced.html.tmpl b/template/en/default/search/search-advanced.html.tmpl
index 89938adbe..c17d8a2e4 100644
--- a/template/en/default/search/search-advanced.html.tmpl
+++ b/template/en/default/search/search-advanced.html.tmpl
@@ -32,44 +32,13 @@
[% js_data = BLOCK %]
-function doOnSelectProduct() {
- var f = document.forms['queryform'];
- milestone = (typeof(f.target_milestone) == "undefined" ?
- null : f.target_milestone);
- selectProduct(f.product, f.component, f.version, milestone);
-}
-
-var first_load = true; [%# is this the first time we load the page? %]
-var last_sel = new Array(); [%# caches last selection %]
-
-var cpts = new Array();
-var vers = new Array();
-[% IF Param('usetargetmilestone') %]
-var tms = new Array();
-[% END %]
-
-[%# Create three arrays of components, versions and target milestones, indexed
- # numerically according to the product they refer to. #%]
-
-[% n = 0 %]
-[% FOREACH p = product %]
- cpts[[% n %]] = [
- [%- FOREACH item = p.components %]'[% item FILTER js %]'[% ", " UNLESS loop.last %] [%- END -%] ];
- vers[[% n %]] = [
- [%- FOREACH item = p.versions -%]'[% item FILTER js %]'[% ", " UNLESS loop.last %] [%- END -%] ];
- [% IF Param('usetargetmilestone') %]
- tms[[% n %]] = [
- [%- FOREACH item = p.milestones %]'[% item FILTER js %]'[% ", " UNLESS loop.last %] [%- END -%] ];
- [% END %]
- [% n = n+1 %]
-[% END %]
-
+var queryform = "queryform"
[% END %]
[% PROCESS global/header.html.tmpl
title = "Search for $terms.bugs"
h1 = ""
- onload = "doOnSelectProduct(); initHelp();"
+ onload = "doOnSelectProduct(0); initHelp();"
javascript = js_data
javascript_urls = [ "js/productform.js" ]
style = "td.selected_tab {
diff --git a/template/en/default/search/search-help.html.tmpl b/template/en/default/search/search-help.html.tmpl
index 1d3544e28..0d4b53e26 100644
--- a/template/en/default/search/search-help.html.tmpl
+++ b/template/en/default/search/search-help.html.tmpl
@@ -25,8 +25,13 @@
{ id => "short_desc",
html => "The $terms.bug summary is a short sentence which succinctly
describes <br> what the $terms.bug is about." },
+{ id => "classification",
+ html => "$terms.Bugs are categorised into Classifications, Products and Components. classifications is the<br>
+ top-level categorisation." },
{ id => "product",
- html => "$terms.Bugs are categorised into Products and Components. Product is
+ html => Param('useclassification') ?
+ "$terms.Bugs are categorised into Products and Components. Select a Classification to narrow down this list" :
+ "$terms.Bugs are categorised into Products and Components. Product is
the<br>top-level categorisation." },
{ id => "component",
html => "Components are second-level categories; each belongs to a<br>
diff --git a/template/en/default/search/search-report-graph.html.tmpl b/template/en/default/search/search-report-graph.html.tmpl
index 4e1f0bae3..276fe7560 100644
--- a/template/en/default/search/search-report-graph.html.tmpl
+++ b/template/en/default/search/search-report-graph.html.tmpl
@@ -26,9 +26,15 @@
[% PROCESS global/variables.none.tmpl %]
+[% js_data = BLOCK %]
+var queryform = "reportform"
+[% END %]
+
[% PROCESS global/header.html.tmpl
title = "Generate Graphical Report"
- onload = "selectProduct(document.forms['reportform']);chartTypeChanged()"
+ onload = "doOnSelectProduct(0); chartTypeChanged()"
+ javascript = js_data
+ javascript_urls = [ "js/productform.js" ]
%]
[% PROCESS "search/search-report-select.html.tmpl" %]
diff --git a/template/en/default/search/search-report-select.html.tmpl b/template/en/default/search/search-report-select.html.tmpl
index 9afe41c4b..36288425c 100644
--- a/template/en/default/search/search-report-select.html.tmpl
+++ b/template/en/default/search/search-report-select.html.tmpl
@@ -27,7 +27,7 @@
[% PROCESS "global/field-descs.none.tmpl" %]
[% BLOCK select %]
- [% rep_fields = ["product", "component", "version", "rep_platform",
+ [% rep_fields = ["classification", "product", "component", "version", "rep_platform",
"op_sys", "bug_status", "resolution", "bug_severity",
"priority", "target_milestone", "assigned_to",
"reporter", "qa_contact", "votes" ] %]
diff --git a/template/en/default/search/search-report-table.html.tmpl b/template/en/default/search/search-report-table.html.tmpl
index 8718da5fd..1894fa795 100644
--- a/template/en/default/search/search-report-table.html.tmpl
+++ b/template/en/default/search/search-report-table.html.tmpl
@@ -26,9 +26,15 @@
[% PROCESS global/variables.none.tmpl %]
+[% js_data = BLOCK %]
+var queryform = "reportform"
+[% END %]
+
[% PROCESS global/header.html.tmpl
title = "Generate Tabular Report"
- onload = "selectProduct(document.forms['reportform']);"
+ onload = "doOnSelectProduct(0)"
+ javascript = js_data
+ javascript_urls = [ "js/productform.js" ]
%]
[% PROCESS "search/search-report-select.html.tmpl" %]
diff --git a/template/en/default/search/search-specific.html.tmpl b/template/en/default/search/search-specific.html.tmpl
index b50307552..30b3e7b9e 100644
--- a/template/en/default/search/search-specific.html.tmpl
+++ b/template/en/default/search/search-specific.html.tmpl
@@ -75,10 +75,24 @@ for "crash secure SSL flash".
<td>
<select name="product" id="product">
<option value="">All</option>
- [% FOREACH p = product %]
- <option value="[% p.name FILTER html %]"
- [% " selected" IF lsearch(default.product, p.name) != -1 %]>
- [% p.name FILTER html %]</option>
+ [% IF Param('useclassification') %]
+ [% FOREACH c = classification %]
+ <optgroup label="[% c.name FILTER html %]">
+ [% FOREACH p = c.products %]
+ <option value="[% p FILTER html %]"
+ [% " selected" IF lsearch(default.product, p) != -1 %]>
+ [% p FILTER html %]
+ </option>
+ [% END %]
+ </optgroup>
+ [% END %]
+ [% ELSE %]
+ [% FOREACH p = product %]
+ <option value="[% p.name FILTER html %]"
+ [% " selected" IF lsearch(default.product, p.name) != -1 %]>
+ [% p.name FILTER html %]
+ </option>
+ [% END %]
[% END %]
</select>
</td>