blob: 966cefdcf0e6d4f187e92a452b57fcab097c65b2 (
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
|
[%# 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.
#%]
[%#
# bug: bug object
#%]
[%
PROCESS global/variables.none.tmpl;
in_all_groups = 1;
in_a_group = 0;
FOREACH group IN bug.groups;
IF NOT group.ingroup;
in_all_groups = 0;
END;
IF group.ison;
in_a_group = 1;
END;
END
%]
<div class="groups edit-hide">
[% IF in_a_group %]
<b>Only users in all of the following groups can view this [% terms.bug %]:</b>
<ul>
[% FOREACH group IN bug.groups %]
[% NEXT UNLESS group.ison || group.mandatory %]
<li>[% group.description FILTER html %]</li>
[% END %]
</ul>
[% IF bug.reporter_accessible || bug.cclist_accessible %]
<b>Users in the roles below can always view this [% terms.bug %]:</b>
<ul>
[% IF bug.reporter_accessible %]<li>Reporter</li>[% END %]
[% IF bug.cclist_accessible %]<li>CC List</li>[% END %]
</ul>
[% END %]
[% ELSE %]
This [% terms.bug %] is publicly visible.
[% END %]
</div>
<div class="groups edit-show" style="display:none">
[% UNLESS bug.in_group(bug.product_obj.default_security_group_obj)
|| user.in_group(bug.product_obj.default_security_group)
|| (user.id != bug.reporter.id && !user.in_group('editbugs')) %]
<div>
<input type="checkbox" name="groups" class="restrict_sensitive"
value="[% bug.product_obj.default_security_group FILTER none %]"
id="group_[% bug.product_obj.default_security_group_obj.id FILTER html %]">
<label for="group_[% bug.product_obj.default_security_group_obj.id FILTER html %]"
title="This [% terms.bug %] is security sensitive and should be hidden from the public until it is resolved">
Restrict access to this [% terms.bug %]
</label>
</div>
[% END %]
[% emitted_description = 0 %]
[% FOREACH group IN bug.groups %]
[% IF NOT emitted_description %]
[% emitted_description = 1 %]
<b>Only users in all of the selected groups can view this [% terms.bug %]:</b>
[% END %]
[% IF group.ingroup && !group.mandatory %]
<input type="hidden" name="defined_groups" value="[% group.name FILTER html %]">
[% END %]
<div class="group">
<input type="checkbox" value="[% group.name FILTER html %]"
name="groups" id="group_[% group.bit FILTER html %]"
[% " checked" IF group.ison %]
[% " disabled" IF NOT group.ingroup || group.mandatory %]>
<label for="group_[% group.bit FILTER html %]">
[%~ group.description FILTER html_light ~%]
</label>
</div>
[% END %]
[% IF in_a_group %]
<b>Users in the roles selected below can always view this [% terms.bug %]:</b>
<div>
[% user_can_edit_accessible = bug.check_can_change_field("reporter_accessible", 0, 1) %]
[% IF user_can_edit_accessible %]
<input type="hidden" name="defined_reporter_accessible" value="1">
[% END %]
<input type="checkbox" value="1"
name="reporter_accessible" id="reporter_accessible"
[% " checked" IF bug.reporter_accessible %]
[% " disabled=\"disabled\"" UNLESS user_can_edit_accessible %]>
<label for="reporter_accessible">Reporter</label>
</div>
<div>
[% user_can_edit_accessible = bug.check_can_change_field("cclist_accessible", 0, 1) %]
[% IF user_can_edit_accessible %]
<input type="hidden" name="defined_cclist_accessible" value="1">
[% END %]
<input type="checkbox" value="1"
name="cclist_accessible" id="cclist_accessible"
[% " checked" IF bug.cclist_accessible %]
[% " disabled=\"disabled\"" UNLESS user_can_edit_accessible %]>
<label for="cclist_accessible">CC List</label>
</div>
The assignee [% IF (Param('useqacontact')) %]and QA contact[% END %]
can always see [% terms.abug %], and this section does not take effect
unless the [% terms.bug %] is restricted to at least one group.
[% END %]
</div>
|