1
[%# 1.0@bugzilla.org %]
2
[%# The contents of this file are subject to the Mozilla Public
3
# License Version 1.1 (the "License"); you may not use this file
4
# except in compliance with the License. You may obtain a copy of
5
# the License at http://www.mozilla.org/MPL/
7
# Software distributed under the License is distributed on an "AS
8
# IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
9
# implied. See the License for the specific language governing
10
# rights and limitations under the License.
12
# The Original Code is the Bugzilla Bug Tracking System.
14
# The Initial Developer of the Original Code is Netscape Communications
15
# Corporation. Portions created by Netscape are
16
# Copyright (C) 1998 Netscape Communications Corporation. All
19
# Contributor(s): Myk Melez <myk@mozilla.org>
22
[% PROCESS global/variables.none.tmpl %]
24
[% PROCESS global/header.html.tmpl
25
title = 'Administer Flag Types'
27
table#flag_types tr th { text-align: left; }
28
.inactive { color: #787878; }
33
Flags are markers that identify whether [% terms.abug %] or attachment has been granted
34
or denied some status. Flags appear in the UI as a name and a status symbol
35
("+" for granted, "-" for denied, and "?" for statuses requested by users).
39
For example, you might define a "review" status for users to request review
40
for their patches. When a patch writer requests review, the string "review?"
41
will appear in the attachment. When a patch reviewer reviews the patch,
42
either the string "review+" or the string "review-" will appear in the patch,
43
depending on whether the patch passed or failed review.
46
<h3>Flag Types for [% terms.Bugs %]</h3>
48
[% PROCESS display_flag_types types=bug_types %]
51
<a href="editflagtypes.cgi?action=enter&target_type=bug">Create Flag Type for [% terms.Bugs %]</a>
54
<h3>Flag Types for Attachments</h3>
56
[% PROCESS display_flag_types types=attachment_types %]
59
<a href="editflagtypes.cgi?action=enter&target_type=attachment">Create Flag Type For Attachments</a>
62
<script type="text/javascript" language="JavaScript">
64
function confirmDelete(id, name, count)
67
var msg = 'There are ' + count + ' flags of type ' + name + '. ' +
68
'If you delete this type, those flags will also be ' +
69
'deleted.\n\nNote: to deactivate the type instead ' +
70
'of deleting it, edit it and uncheck its "is active" ' +
71
'flag.\n\nDo you really want to delete this flag type?';
72
if (!confirm(msg)) return false;
74
location.href = "editflagtypes.cgi?action=delete&id=" + id;
75
return false; // prevent strict JavaScript warning that this function
76
// does not always return a value
81
[% PROCESS global/footer.html.tmpl %]
84
[% BLOCK display_flag_types %]
85
<table id="flag_types" cellspacing="0" cellpadding="4" border="1">
88
<th>Edit name ...</th>
93
[% FOREACH type = types %]
95
<tr class="[% IF type.is_active %]active[% ELSE %]inactive[% END %]">
96
<td><a href="editflagtypes.cgi?action=edit&id=[% type.id %]">[% type.name FILTER html %]</a></td>
97
<td>[% type.description FILTER html %]</td>
99
<a href="editflagtypes.cgi?action=copy&id=[% type.id %]">Copy</a>
100
| <a href="editflagtypes.cgi?action=confirmdelete&id=[% type.id %]"
101
onclick="return confirmDelete([% type.id %], '[% type.name FILTER js FILTER html %]',
102
[% type.flag_count %]);">Delete</a>