1[%# This Source Code Form is subject to the terms of the Mozilla Public
2  # License, v. 2.0. If a copy of the MPL was not distributed with this
3  # file, You can obtain one at http://mozilla.org/MPL/2.0/.
4  #
5  # This Source Code Form is "Incompatible With Secondary Licenses", as
6  # defined by the Mozilla Public License, v. 2.0.
7  #%]
8
9[% dontchange = "--do_not_change--" %]
10<input type="hidden" name="dontchange" value="[% dontchange FILTER html %]">
11<input type="hidden" name="token" value="[% token FILTER html %]">
12
13<input type="button" id="uncheck_all" value="全て未選択"
14       class="bz_default_hidden" onclick="SetCheckboxes(false);">
15<input type="button" id="check_all" value="全て選択"
16       class="bz_default_hidden" onclick="SetCheckboxes(true);">
17
18<script type="text/javascript">
19  function SetCheckboxes(value) {
20      var elements = document.forms.changeform.getElementsByTagName('input'),
21          numelements = elements.length,
22          item, i;
23      for (i = 0; i < numelements; i++) {
24          item = elements[i];
25          if (item.type === 'checkbox' && item.name.match(/^id_/)) {
26            item.checked = value;
27          }
28      }
29  }
30  YAHOO.util.Dom.removeClass("check_all", "bz_default_hidden");
31  YAHOO.util.Dom.removeClass("uncheck_all", "bz_default_hidden");
32</script>
33
34<hr>
35
36<p style="font-size:smaller">
37<ol style="font-size:smaller">
38</ol>
39<div class="bz_info">
40  複数の [% terms.bugs %] を変更する
41  <ol>
42  <li>変更したい [% terms.bugs %] を選択してください。</li>
43  <li>行う変更を下のフォームに入力してください。
44    変更に説明が必要なものがあれば、コメントボックスに入れてください。</li>
45  <li><em>実行</em> ボタンを押してください。</li>
46  </ol>
47</div>
48
49[% IF excluded_values %]
50  <p class="extra_info">上の [%+ terms.bugs %] に有効なプロダクト
51  全てのみが表示されています。</p>
52[% END %]
53
54<table id="form">
55  <tr>
56
57    <th><label for="product">プロダクト:</label></th>
58    <td>
59      [% INCLUDE "global/product-select.html.tmpl"
60         id         => "product"
61         name       => "product"
62         dontchange => dontchange
63       %]
64    </td>
65
66    <th><label for="version">バージョン:</label></th>
67    <td>
68      [% PROCESS selectmenu menuname = "version"
69                            menuitems = versions
70                            property = "" %]
71    </td>
72
73  </tr>
74  <tr>
75
76    <th><label for="component">コンポーネント:</label></th>
77    <td>
78      [% PROCESS selectmenu menuname = "component"
79                            menuitems = components %]
80    </td>
81
82    <th>
83      <label for="priority">
84        <a href="page.cgi?id=fields.html#priority">重要度</a>:
85      </label>
86    </th>
87    <td>
88      [% PROCESS selectmenu menuname = "priority"
89                            menuitems = priorities %]
90    </td>
91
92  </tr>
93  <tr>
94
95    <th>
96      <label for="rep_platform">
97        <a href="page.cgi?id=fields.html#rep_platform">
98          [% field_descs.rep_platform FILTER html %]</a>:
99      </label>
100    </th>
101    <td>
102      [% PROCESS selectmenu menuname = "rep_platform"
103                            menuitems = platforms %]
104    </td>
105
106    <th>
107      <label for="bug_severity">
108        <a href="page.cgi?id=fields.html#bug_severity">
109          [% field_descs.bug_severity FILTER html %]</a>:
110      </label>
111    </th>
112    <td>
113      [% PROCESS selectmenu menuname = "bug_severity"
114                            menuitems = severities %]
115    </td>
116
117  </tr>
118
119  <tr>
120    <th>
121      <label for="op_sys">
122        <a href="page.cgi?id=fields.html#op_sys">[% field_descs.op_sys FILTER html %]</a>:
123      </label>
124    </th>
125    <td [% " colspan=\"3\"" IF !Param("usetargetmilestone") %]>
126      [% PROCESS selectmenu menuname = "op_sys"
127                            menuitems = op_sys %]
128    </td>
129
130    [% IF Param("usetargetmilestone") %]
131      <th><label for="target_milestone">ターゲットマイルストーン:</label></th>
132      <td>
133        [% PROCESS selectmenu menuname = "target_milestone"
134                              menuitems = milestones %]
135      </td>
136    [% END %]
137  </tr>
138
139  <tr>
140    <th><label for="bug_status">ステータス:</label></th>
141    <td colspan="3">[% PROCESS status_section %]</td>
142  </tr>
143  [% IF user.is_timetracker %]
144    <tr>
145      [% INCLUDE "bug/field-label.html.tmpl"
146         field = bug_fields.estimated_time, editable = 1
147      %]
148      <td>
149        <input id="estimated_time"
150               name="estimated_time"
151               value="[% dontchange FILTER html %]"
152               size="6">
153      </td>
154      [% PROCESS bug/field.html.tmpl
155          field = bug_fields.deadline, value = dontchange
156          editable = 1, allow_dont_change = 1 %]
157    </tr>
158    <tr>
159      [% INCLUDE "bug/field-label.html.tmpl"
160         field = bug_fields.remaining_time, editable = 1
161      %]
162      <td>
163        <input id="remaining_time"
164               name="remaining_time"
165               value="[% dontchange FILTER html %]"
166               size="6">
167      </td>
168      <th>&nbsp;</th>
169      <td>&nbsp;</td>
170    </tr>
171  [% END %]
172
173  <tr>
174    <th><label for="assigned_to">担当者:</label></th>
175    <td colspan="3">
176      [% INCLUDE global/userselect.html.tmpl
177           id => "assigned_to"
178           name => "assigned_to"
179           value => dontchange
180           size => 40
181      %]
182      <input type="checkbox" id="set_default_assignee" name="set_default_assignee" value="1">
183      <label for="set_default_assignee">既定の担当者に戻す</label>
184    </td>
185  </tr>
186
187  [% IF Param("useqacontact") %]
188    <tr>
189      <th><label for="qa_contact">QA コンタクト:</label></th>
190      <td colspan="3">
191        [% INCLUDE global/userselect.html.tmpl
192             id => "qa_contact"
193             name => "qa_contact"
194             value => dontchange
195             size => 40
196        %]
197        <input type="checkbox" id="set_default_qa_contact" name="set_default_qa_contact" value="1">
198        <label for="set_default_qa_contact">既定の QA コンタクトに戻す</label>
199      </td>
200    </tr>
201  [% END %]
202
203  <tr>
204
205    <th><label for="masscc">CC:</label></th>
206    <td colspan="3">
207      [% INCLUDE global/userselect.html.tmpl
208           id => "masscc"
209           name => "masscc"
210           value => ""
211           size => 40
212           multiple => 5
213      %]
214      <select name="ccaction">
215        <option value="add">CC に追加する</option>
216        <option value="remove">CC から削除する</option>
217      </select>
218    </td>
219
220  </tr>
221
222  [% IF use_keywords %]
223    <tr>
224
225      [% INCLUDE "bug/field-label.html.tmpl"
226         field = bug_fields.keywords, editable = 1
227         desc_url = "describekeywords.cgi"
228      %]
229      <td colspan="3">
230        [% INCLUDE bug/field.html.tmpl
231           field = bug_fields.keywords, editable = 1, value = keywords
232           possible_values = all_keywords
233           no_tds = 1
234        %]
235        <select name="keywordaction">
236          <option value="add">キーワードを追加する</option>
237          <option value="remove">キーワードを削除する</option>
238          <option value="set">このリストのキーワードのみを設定する</option>
239        </select>
240      </td>
241
242    </tr>
243  [% END %]
244
245  <tr>
246    <th>
247      <label for="dependson">
248          依存先:
249      </label>
250    </th>
251    <td colspan="3">
252      <input id="dependson" name="dependson" size="40">
253      <select name="dependson_action">
254          <option value="add">これらの ID を追加</option>
255          <option value="remove">これらの ID を削除</option>
256      </select>
257    </td>
258  </tr>
259
260  <tr>
261    <th>
262      <label for="blocked">
263          妨害先:
264      </label>
265    </th>
266    <td colspan="3">
267      <input id="blocked" name="blocked" size="40">
268      <select name="blocked_action">
269          <option value="add">これらの ID を追加</option>
270          <option value="remove">これらの ID を削除</option>
271      </select>
272    </td>
273  </tr>
274
275  [% IF Param('usestatuswhiteboard') %]
276    <tr>
277      <th>
278        <label for="status_whiteboard">ステータスホワイトボード:</label>
279      </th>
280      <td colspan="7">
281        <input name="status_whiteboard" id="status_whiteboard"
282               value="[% dontchange FILTER html %]" size="60">
283      </td>
284    </tr>
285  [% END %]
286
287  [% USE Bugzilla %]
288  [%# Show all legal values and all fields, ignoring visibility controls. %]
289  [% bug = 0 %]
290  [% FOREACH field = Bugzilla.active_custom_fields %]
291    <tr>
292      [% PROCESS bug/field.html.tmpl value = dontchange
293                                     editable = 1
294                                     allow_dont_change = 1 %]
295    </tr>
296  [% END %]
297
298  [% Hook.process("after_custom_fields") %]
299
300</table>
301
302<b><label for="comment">追加コメント:</label></b>
303[% IF user.is_insider %]
304  <input type="checkbox" name="comment_is_private" value="1"
305         id="newcommentprivacy"
306         onClick="updateCommentTagControl(this, 'comment')">
307   <label for="newcommentprivacy">
308     コメントをプライベートにします
309     (<strong>[% Param('insidergroup') FILTER html %]</strong>
310     グループのメンバーのみにしか見えなくなります)
311   </label>
312[% END %]
313<br>
314[% INCLUDE global/textarea.html.tmpl
315  name    = 'comment'
316  id      = 'comment'
317  minrows = 5
318  maxrows = 25
319  cols    = constants.COMMENT_COLS
320%]<br>
321[% IF user.is_insider %]
322  <script>
323     updateCommentTagControl(document.getElementById('newcommentprivacy'), 'comment');
324  </script>
325[% END %]
326
327[% IF flag_types %]
328<b><label for="flags">フラグ:</label></b><br>
329[% PROCESS "flag/list.html.tmpl"
330           edit_multiple_bugs = 1
331           flag_no_header = 1 %]
332[% END %]
333
334[% Hook.process('before_groups') %]
335
336[% IF groups.size > 0 %]
337
338  <script type="text/javascript">
339    function turn_off(myself, id) {
340        var other_checkbox = document.getElementById(id);
341        if (myself.checked && other_checkbox) {
342            other_checkbox.checked = false;
343        }
344    }
345  </script>
346
347  <b>グループ:</b><br>
348  <table id="groups_edit_multiple">
349    <tr>
350      <th class="narrow_column">このグループを [% terms.bugs %] から除く</th>
351      <th class="narrow_column">このグループを [% terms.bugs %] に追加する</th>
352      <th>グループ名</th>
353    </tr>
354
355    [% FOREACH group = groups %]
356    <tr>
357      <td class="center">
358        <input type="checkbox" name="defined_groups"
359               id="defined_group_[% group.id %]"
360               value="[% group.name FILTER html %]"
361               onchange="turn_off(this, 'group_[% group.id %]')">
362      </td>
363      [% IF group.is_active %]
364        <td class="center">
365          <input type="checkbox" name="groups"
366                 id="group_[% group.id FILTER html %]"
367                 value="[% group.name FILTER html %]"
368                 onchange="turn_off(this, 'defined_group_[% group.id %]')">
369        </td>
370      [% ELSE %]
371        <td>&nbsp;</td>
372        [% foundinactive = 1 %]
373      [% END %]
374
375      <td>
376        [% SET inactive = !group.is_active %]
377        [% group.description FILTER html_light FILTER inactive(inactive) %]
378      </td>
379
380    </tr>
381    [% END %]
382
383  </table>
384
385  [% IF foundinactive %]
386    <p class="bz_info">(注: [% terms.Bugs %] は [% FILTER inactive %]無効なグループ[% END %]
387    には追加できません。削除のみ可能です。)</p>
388  [% END %]
389
390[% END %]
391
392[%+ Hook.process('after_groups') %]
393
394<input type="submit" id="commit" value="実行">
395
396[%############################################################################%]
397[%# Select Menu Block                                                        #%]
398[%############################################################################%]
399
400[% BLOCK selectmenu %]
401  <select id="[% menuname %]" name="[% menuname %]">
402    <option value="[% dontchange FILTER html %]" selected="selected">
403      [% dontchange FILTER html %]
404    </option>
405    [% FOREACH menuitem = menuitems %]
406      [% IF property %][% menuitem = menuitem.$property %][% END %]
407      <option value="[% menuitem FILTER html %]">[% display_value(menuname, menuitem) FILTER html %]</option>
408    [% END %]
409  </select>
410[% END %]
411
412[%############################################################################%]
413[%# Status Block                                                             #%]
414[%############################################################################%]
415
416[% BLOCK status_section %]
417  [% all_open_bugs = !current_bug_statuses.containsany(closedstates) %]
418  [% all_closed_bugs = !current_bug_statuses.containsany(openstates) %]
419  [% closed_status_array = [] %]
420
421  <select name="bug_status" id="bug_status">
422    <option value="[% dontchange FILTER html %]" selected="selected">[% dontchange FILTER html %]</option>
423
424    [% FOREACH bug_status = new_bug_statuses %]
425      <option value="[% bug_status.name FILTER html %]">
426        [% display_value("bug_status", bug_status.name) FILTER html %]
427      </option>
428      [% IF !bug_status.is_open %]
429        [% filtered_status =  bug_status.name FILTER js %]
430        [% closed_status_array.push( filtered_status ) %]
431      [% END %]
432    [% END %]
433
434  [%# If all the bugs being changed are closed, allow the user to change their resolution. %]
435  [% IF all_closed_bugs %]
436    [% filtered_status = dontchange FILTER js %]
437    [% closed_status_array.push( filtered_status ) %]
438  [% END %]
439  </select>
440
441  <span id="resolution_settings">
442  <select id="resolution" name="resolution">
443      <option value="[% dontchange FILTER html %]" selected >[% dontchange FILTER html %]</option>
444    [% FOREACH r = resolutions %]
445      [% NEXT IF !r %]
446      [% NEXT IF r == "DUPLICATE" || r == "MOVED" %]
447      <option value="[% r FILTER html %]">[% display_value("resolution", r) FILTER html %]</option>
448    [% END %]
449  </select>
450  </span>
451
452  <script type="text/javascript">
453  var close_status_array = new Array("[% closed_status_array.join('", "') FILTER none %]");
454    YAHOO.util.Event.addListener('bug_status', "change", showHideStatusItems, '[% "is_duplicate" IF bug.dup_id %]');
455    YAHOO.util.Event.onDOMReady( showHideStatusItems );
456  </script>
457
458[% END %]
459