summaryrefslogtreecommitdiffstats
path: root/extensions/TrackingFlags/template/en/default/hook/bug/field-editable.html.tmpl
blob: f598609e80b2bb9e4e007106fd70d1d60dac6dd1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
[%# This Source Code Form is subject to the terms of the Mozilla Public
  # License, v. 2.0. If a copy of the MPL was not distributed with this
  # file, You can obtain one at http://mozilla.org/MPL/2.0/.
  #
  # This Source Code Form is "Incompatible With Secondary Licenses", as
  # defined by the Mozilla Public License, v. 2.0.
  #%]

<input type="hidden" id="[% field.name FILTER html %]_dirty">
<select id="[% field.name FILTER html %]"
        name="[% field.name FILTER html %]">
  [% IF allow_dont_change %]
    <option value="[% dontchange FILTER html %]"
      [% ' selected="selected"' IF value == dontchange %]>
      [% dontchange FILTER html %]
    </option>
  [% END %]
  [% FOREACH legal_value = field.values %]
    [% IF legal_value.name != value %]
      [% NEXT IF !field.can_set_value(legal_value.name) %]
      [% NEXT IF !legal_value.is_active %]
    [% END %]
    <option value="[% legal_value.name FILTER html %]"
            id="v[% legal_value.id FILTER html %] [%- field.name FILTER html %]"
            [% IF legal_value.name == value %]
              selected="selected"
            [% END %]>
      [%- display_value(field.name, legal_value.name) FILTER html ~%]
    </option>
  [% END %]
</select>
<script type="text/javascript">
<!--
  initHidingOptionsForIE('[% field.name FILTER js %]');
  [%+ INCLUDE "bug/field-events.js.tmpl"
      field = field, product = bug.product_obj %]
//-->
</script>