diff options
author | lpsolit%gmail.com <> | 2007-07-28 05:54:36 +0000 |
---|---|---|
committer | lpsolit%gmail.com <> | 2007-07-28 05:54:36 +0000 |
commit | 737535fcbcfd91d7c15eab2f43386333af113797 (patch) | |
tree | 11f720ceb06a1774840735eb9dc602b47252b97a /template/en/default/list/edit-multiple.html.tmpl | |
parent | 0885b2b60ea61f2b3ca8d1f61049412f340b6c6d (diff) | |
download | bugs-737535fcbcfd91d7c15eab2f43386333af113797.tar bugs-737535fcbcfd91d7c15eab2f43386333af113797.tar.gz bugs-737535fcbcfd91d7c15eab2f43386333af113797.tar.bz2 bugs-737535fcbcfd91d7c15eab2f43386333af113797.tar.xz bugs-737535fcbcfd91d7c15eab2f43386333af113797.zip |
Bug 389835: Various issues when changing several bugs at once - Patch by Frédéric Buclin <LpSolit@gmail.com> r/a=mkanat
Diffstat (limited to 'template/en/default/list/edit-multiple.html.tmpl')
-rw-r--r-- | template/en/default/list/edit-multiple.html.tmpl | 31 |
1 files changed, 25 insertions, 6 deletions
diff --git a/template/en/default/list/edit-multiple.html.tmpl b/template/en/default/list/edit-multiple.html.tmpl index 28e513e7b..0fd206797 100644 --- a/template/en/default/list/edit-multiple.html.tmpl +++ b/template/en/default/list/edit-multiple.html.tmpl @@ -300,7 +300,9 @@ [% END %] - +[% all_open_bugs = !current_bug_statuses.containsany(closedstates) %] +[% all_closed_bugs = !current_bug_statuses.containsany(openstates) %] +[% display_warning = 0 %] <input id="knob-none" type="radio" name="knob" value="none" checked="checked"> <label for="knob-none">Do nothing else</label><br> @@ -311,18 +313,35 @@ <label for="knob_[% bug_status.id FILTER html %]"> Change status to <b>[% get_status(bug_status.name) FILTER html %]</b> </label> - [% IF !bug_status.is_open %] - and set the resolution to [% PROCESS select_resolution field = "knob_${bug_status.id}" %] + [%# Closed bugs cannot have their resolution changed this way. %] + [% IF !bug_status.is_open && !all_closed_bugs %] + and set the resolution to [% PROCESS select_resolution id = bug_status.id %] + [%+ "(*)" UNLESS all_open_bugs %] + [% display_warning = 1 UNLESS all_open_bugs %] [% END %] <br> [% END %] [%# If all the bugs being changed are open, allow the user to clear their resolution. %] -[% IF !current_bug_statuses.containsany(closedstates) %] +[% IF all_open_bugs %] <input id="knob-clearresolution" type="radio" name="knob" value="clearresolution"> <label for="knob-clearresolution">Clear the resolution</label><br> [% END %] +[%# If all the bugs being changed are closed, allow the user to change their resolution. %] +[% IF all_closed_bugs %] + <input type="radio" id="knob_change_resolution" name="knob" value="change_resolution"> + <label for="knob_change_resolution">Change resolution to</label> + [%+ PROCESS select_resolution id = "change_resolution" %]<br> +[% END %] + +[% IF display_warning %] + <p class="box"> + (*) Note that the resolution will only be applied to open [% terms.bugs %]. + Already closed [% terms.bugs %] will keep their resolution unchanged. + </p> +[% END %] + <input type="submit" id="commit" value="Commit"> [% IF Param('move-enabled') && user.is_mover %] @@ -346,8 +365,8 @@ [% END %] [% BLOCK select_resolution %] - <select name="resolution" - onchange="document.forms['changeform'].[% field FILTER html %].checked=true"> + <select id="resolution_knob_[% id FILTER html %]" name="resolution_knob_[% id FILTER html %]" + onchange="document.forms['changeform'].[% "knob_$id" FILTER html %].checked=true"> [% FOREACH r = resolutions %] [% NEXT IF !r %] <option value="[% r FILTER html %]">[% get_resolution(r) FILTER html %]</option> |