summaryrefslogtreecommitdiffstats
path: root/template
diff options
context:
space:
mode:
Diffstat (limited to 'template')
-rw-r--r--template/en/default/admin/flag-type/edit.html.tmpl13
-rw-r--r--template/en/default/admin/flag-type/list.html.tmpl15
-rw-r--r--template/en/default/bug/edit.html.tmpl18
-rw-r--r--template/en/default/list/edit-multiple.html.tmpl8
-rw-r--r--template/en/default/reports/duplicates.html.tmpl12
-rw-r--r--template/en/default/reports/old-charts.html.tmpl11
-rw-r--r--template/en/default/request/queue.html.tmpl28
-rw-r--r--template/en/default/search/search-instant.html.tmpl28
-rw-r--r--template/en/default/search/search-specific.html.tmpl29
9 files changed, 104 insertions, 58 deletions
diff --git a/template/en/default/admin/flag-type/edit.html.tmpl b/template/en/default/admin/flag-type/edit.html.tmpl
index 9043db96d..69dc05bd3 100644
--- a/template/en/default/admin/flag-type/edit.html.tmpl
+++ b/template/en/default/admin/flag-type/edit.html.tmpl
@@ -108,13 +108,12 @@
<tr>
<td style="vertical-align: top;">
<b>Product/Component:</b><br>
- [% INCLUDE "global/product-select.html.tmpl"
- id => "product"
- name => "product"
- add => "__Any__"
- onchange => "selectProduct(this, this.form.component, null, null, '__Any__');"
- products => products
- %]<br>
+ <select name="product" onchange="selectProduct(this, this.form.component, null, null, '__Any__');">
+ <option value="">__Any__</option>
+ [% FOREACH prod = products %]
+ <option value="[% prod.name FILTER html %]">[% prod.name FILTER html %]</option>
+ [% END %]
+ </select><br>
<select name="component">
<option value="">__Any__</option>
[% FOREACH comp = components %]
diff --git a/template/en/default/admin/flag-type/list.html.tmpl b/template/en/default/admin/flag-type/list.html.tmpl
index 3d1be7bfb..220db8900 100644
--- a/template/en/default/admin/flag-type/list.html.tmpl
+++ b/template/en/default/admin/flag-type/list.html.tmpl
@@ -61,13 +61,14 @@
<tr>
<th><label for="product">Product:</label></th>
<td>
- [% INCLUDE "global/product-select.html.tmpl"
- id => "product"
- name => "product"
- add => "__Any__"
- onchange => "selectProduct(this, this.form.component, null, null, '__Any__');"
- products => products
- %]
+ <select name="product" onchange="selectProduct(this, this.form.component, null, null, '__Any__');">
+ <option value="">__Any__</option>
+ [% FOREACH prod = products %]
+ <option value="[% prod.name FILTER html %]"
+ [% " selected" IF selected_product == prod.name %]>
+ [% prod.name FILTER html %]</option>
+ [% END %]
+ </select>
</td>
<th><label for="component">Component:</label></th>
<td>
diff --git a/template/en/default/bug/edit.html.tmpl b/template/en/default/bug/edit.html.tmpl
index 5ea34cc59..fe6b27bc7 100644
--- a/template/en/default/bug/edit.html.tmpl
+++ b/template/en/default/bug/edit.html.tmpl
@@ -303,19 +303,11 @@
[%# PRODUCT #%]
[%#############%]
<tr>
- [% PROCESS "bug/field-label.html.tmpl"
- field = bug_fields.product
- desc_url = 'describecomponents.cgi'
- %]
- <td class="field_value" id="field_container_product">
- [% INCLUDE "global/product-select.html.tmpl"
- id => "product"
- name => "product"
- value => bug.product
- products => bug.choices.product
- isselect => bug.check_can_change_field('product', 0, 1)
- %]
- </td>
+ [% INCLUDE bug/field.html.tmpl
+ bug = bug, field = bug_fields.product,
+ override_legal_values = bug.choices.product
+ desc_url = 'describecomponents.cgi', value = bug.product
+ editable = bug.check_can_change_field('product', 0, 1) %]
</tr>
[%# Classification is here so that it can be used in value controllers
diff --git a/template/en/default/list/edit-multiple.html.tmpl b/template/en/default/list/edit-multiple.html.tmpl
index d560a9d57..6a3269dff 100644
--- a/template/en/default/list/edit-multiple.html.tmpl
+++ b/template/en/default/list/edit-multiple.html.tmpl
@@ -61,11 +61,9 @@
<th><label for="product">Product:</label></th>
<td>
- [% INCLUDE "global/product-select.html.tmpl"
- id => "product"
- name => "product"
- dontchange => dontchange
- %]
+ [% PROCESS selectmenu menuname = "product"
+ menuitems = products
+ property = "name" %]
</td>
<th><label for="version">Version:</label></th>
diff --git a/template/en/default/reports/duplicates.html.tmpl b/template/en/default/reports/duplicates.html.tmpl
index d17e1a094..ff1c271fe 100644
--- a/template/en/default/reports/duplicates.html.tmpl
+++ b/template/en/default/reports/duplicates.html.tmpl
@@ -82,11 +82,13 @@
</td>
<td rowspan="4" valign="top">Restrict to products:</td>
<td rowspan="4" valign="top">
- [% INCLUDE "global/product-select.html.tmpl"
- id => "product"
- name => "product"
- multiple => 5
- %]
+ <select name="product" size="5" multiple="multiple">
+ [% FOREACH p = user.get_selectable_products %]
+ <option name="[% p.name FILTER html %]"
+ [% ' selected="selected"' IF product.contains(p.name) %]
+ >[% p.name FILTER html %]</option>
+ [% END %]
+ </select>
</td>
</tr>
diff --git a/template/en/default/reports/old-charts.html.tmpl b/template/en/default/reports/old-charts.html.tmpl
index 2f50b31c6..4bdc0cffa 100644
--- a/template/en/default/reports/old-charts.html.tmpl
+++ b/template/en/default/reports/old-charts.html.tmpl
@@ -14,6 +14,7 @@
#%]
[%# INTERFACE:
+ # products: an array of product names the user is allowed to view.
# datasets: an array of hashes with available statuses and resolutions.
# url_image: URL of the generated graph.
#%]
@@ -36,11 +37,11 @@
<tr>
<th>Product:</th>
<td align="center">
- [% INCLUDE "global/product-select.html.tmpl"
- id => "product"
- name => "product"
- add => "-All-"
- %]
+ <select id="product" name="product">
+ [% FOREACH product = products %]
+ <option value="[% product FILTER html %]">[% product FILTER html %]</option>
+ [% END %]
+ </select>
</td>
</tr>
<tr>
diff --git a/template/en/default/request/queue.html.tmpl b/template/en/default/request/queue.html.tmpl
index 9ba8cbc45..261db0438 100644
--- a/template/en/default/request/queue.html.tmpl
+++ b/template/en/default/request/queue.html.tmpl
@@ -81,12 +81,28 @@ to some group are shown by default.
</td>
<th>Product:</th>
<td>
- [% INCLUDE "global/product-select.html.tmpl"
- id => "product"
- name => "product"
- add => "Any"
- onchange => "selectProduct(this, this.form.component, null, null, 'Any');"
- %]
+ <select name="product" onchange="selectProduct(this, this.form.component, null, null, 'Any');">
+ <option value="">Any</option>
+ [% IF Param('useclassification') %]
+ [% FOREACH c = user.get_selectable_classifications %]
+ <optgroup label="[% c.name FILTER html %]">
+ [% FOREACH p = user.get_selectable_products(c.id) %]
+ <option value="[% p.name FILTER html %]"
+ [% " selected" IF cgi.param('product') == p.name %]>
+ [% p.name FILTER html %]
+ </option>
+ [% END %]
+ </optgroup>
+ [% END %]
+ [% ELSE %]
+ [% FOREACH p = user.get_selectable_products %]
+ <option value="[% p.name FILTER html %]"
+ [% " selected" IF cgi.param('product') == p.name %]>
+ [% p.name FILTER html %]
+ </option>
+ [% END %]
+ [% END %]
+ </select>
</td>
<th>Flag:</th>
<td>
diff --git a/template/en/default/search/search-instant.html.tmpl b/template/en/default/search/search-instant.html.tmpl
index 94cb619d0..5d75d1996 100644
--- a/template/en/default/search/search-instant.html.tmpl
+++ b/template/en/default/search/search-instant.html.tmpl
@@ -41,11 +41,29 @@ YAHOO.bugzilla.instantSearch.setLabels( {
<b><label for="product">Product:</label></b>
</td>
<td>
- [% INCLUDE "global/product-select.html.tmpl"
- id => "product"
- name => "product"
- value => default.product.0
- %]
+ <select name="product" id="product">
+ [% IF Param('useclassification') %]
+ [% FOREACH c = classification %]
+ <optgroup label="[% c.name FILTER html %]">
+ [% FOREACH p = user.get_selectable_products(c.id) %]
+ [% IF p.components.size %]
+ <option value="[% p.name FILTER html %]"
+ [% " selected" IF lsearch(default.product, p.name) != -1 %]>
+ [% p.name FILTER html %]
+ </option>
+ [% END %]
+ [% 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>
</tr>
<tr>
diff --git a/template/en/default/search/search-specific.html.tmpl b/template/en/default/search/search-specific.html.tmpl
index ea522a877..7e5de2c4a 100644
--- a/template/en/default/search/search-specific.html.tmpl
+++ b/template/en/default/search/search-specific.html.tmpl
@@ -67,11 +67,30 @@ for "crash secure SSL flash".
<label for="product">[% field_descs.product FILTER html %]:</label>
</th>
<td>
- [% INCLUDE "global/product-select.html.tmpl"
- id => "product"
- name => "product"
- add => "All"
- %]
+ <select name="product" id="product">
+ <option value="">All</option>
+ [% IF Param('useclassification') %]
+ [% FOREACH c = classification %]
+ <optgroup label="[% c.name FILTER html %]">
+ [% FOREACH p = user.get_selectable_products(c.id) %]
+ [% IF p.components.size %]
+ <option value="[% p.name FILTER html %]"
+ [% " selected" IF default.product.contains(p.name) %]>
+ [% p.name FILTER html %]
+ </option>
+ [% END %]
+ [% END %]
+ </optgroup>
+ [% END %]
+ [% ELSE %]
+ [% FOREACH p = product %]
+ <option value="[% p.name FILTER html %]"
+ [% " selected" IF default.product.contains(p.name) %]>
+ [% p.name FILTER html %]
+ </option>
+ [% END %]
+ [% END %]
+ </select>
</td>
</tr>
<tr>