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): Gervase Markham <gerv@gerv.net>
22
[% PROCESS global/variables.none.tmpl %]
24
[% y_label = "$terms.Bugs" %]
26
[% PROCESS "global/field-descs.none.tmpl" %]
28
[% col_field_disp = field_descs.$col_field || col_field %]
30
[% IF col_field == 'bug_status' %]
31
[% FOR i IN [ 0 .. data.0.0.max ] %]
32
[% data.0.0.$i = status_descs.${data.0.0.$i} %]
36
[% IF col_field == 'resolution' %]
37
[% FOR i IN [ 0 .. data.0.0.max ] %]
38
[% data.0.0.$i = get_resolution(data.0.0.$i) %]
42
[% IF row_field == 'bug_status' %]
43
[% FOR i IN [ 0 .. row_names.max ] %]
44
[% row_names.$i = status_descs.${row_names.$i} %]
48
[% IF row_field == 'resolution' %]
49
[% FOR i IN [ 0 .. row_names.max ] %]
50
[% row_names.$i = get_resolution(row_names.$i) %]
55
[% USE graph = GD.Graph.area(width, height) %]
56
[% graph.set(cumulate => "true") %]
58
[% USE graph = GD.Graph.lines(width, height) %]
62
graph.set(x_label => col_field_disp,
65
x_label_position => 0.5,
66
x_labels_vertical => x_labels_vertical,
67
legend_placement => "RT",
69
dclrs => ["lred", "lgreen", "lblue", "lyellow",
70
"lpurple", "lorange", "black", "green",
71
"blue", "dpink", "lbrown", "gray",
72
"red", "dpurple", "gold", "marine"]);
74
# Workaround for the fact that set_legend won't take row_names directly,
75
# because row_names is an array reference rather than an array.
76
graph.set_legend(row_names.0, row_names.1, row_names.2, row_names.3,
77
row_names.4, row_names.5, row_names.6, row_names.7,
78
row_names.8, row_names.9, row_names.10, row_names.11,
79
row_names.12, row_names.13, row_names.14, row_names.15);
81
graph.plot(data.0).png | stdout(1);