diff --git a/report.cgi b/report.cgi index dabf06290..1997c9def 100755 --- a/report.cgi +++ b/report.cgi @@ -129,6 +129,11 @@ if ($action eq "wrap") $vars->{imagebase} = http_build_query($a); $a = { %$ARGS }; delete $a->{$_} for qw(query_format action ctype format width height measure); + for (keys %$a) + { + delete $a->{$_} if $a->{$_} eq ''; + } + $vars->{switchparams} = $a; $vars->{switchbase} = http_build_query($a); } elsif ($action eq "plot") diff --git a/skins/standard/global/diag.svg b/skins/standard/global/diag.svg new file mode 100644 index 000000000..03d337d75 --- /dev/null +++ b/skins/standard/global/diag.svg @@ -0,0 +1,22 @@ + + + + + + diff --git a/template/en/default/reports/report-table.html.tmpl b/template/en/default/reports/report-table.html.tmpl index ede67a7e3..9e9d0c3e9 100644 --- a/template/en/default/reports/report-table.html.tmpl +++ b/template/en/default/reports/report-table.html.tmpl @@ -53,21 +53,6 @@ END; %]

[% tbl_disp FILTER email FILTER html %]

[% END %] - - - - - - - - - - -
- - [% col_field_disp FILTER html %] -
- [% row_field_disp FILTER html %] - - [% classes = [ [ "t1", "t2" ] , [ "t3", "t4" ] ] %] [% col_idx = 0 %] [% row_idx = 0 %] @@ -76,14 +61,30 @@ END; %] [% IF col_field %] - + [% FOREACH col = col_names %] [% col_idx = 1 - col_idx %] [% END %] + [% IF col_names.size > 1 %] + + [% END %] + + [% ELSE %] + + @@ -160,10 +161,6 @@ END; %]
-
+ + + + +
[% col_field_disp FILTER html %]
[% row_field_disp FILTER html %]
+
[% PROCESS value_display value = col field = col_field %] + Total +
+ [% row_field_disp FILTER html %] + Total
-
- [% BLOCK value_display %] [% SET disp_value = value %] [% IF field == 'assigned_to' OR field == 'reporter' OR field == 'qa_contact' %] diff --git a/template/en/default/reports/report.html.tmpl b/template/en/default/reports/report.html.tmpl index 49aafe2f5..cda42cd67 100644 --- a/template/en/default/reports/report.html.tmpl +++ b/template/en/default/reports/report.html.tmpl @@ -17,14 +17,14 @@ # # Contributor(s): Gervase Markham #%] - + [%# INTERFACE: # col_field: string. Name of the field being plotted as columns. # row_field: string. Name of the field being plotted as rows. # tbl_field: string. Name of the field being plotted as tables. # tbl_names: array. List of values for the field being plotted as tables. # time: integer. Seconds since the epoch. - # data: . Data to plot. + # data: . Data to plot. # format: string. Format of the individual reports. # width: integer. For image charts, height of the image. # height: integer. For image charts, width of the image. @@ -41,10 +41,9 @@ [% tbl_field_disp = field_descs.$tbl_field || tbl_field %] [% col_field_disp = field_descs.$col_field || col_field %] [% row_field_disp = field_descs.$row_field || row_field %] -[% switchbase = switchbase FILTER html %] [% title = BLOCK %] - Report: + Report: [% IF tbl_field %] [% tbl_field_disp FILTER html %] [% END %] @@ -58,12 +57,12 @@ [% time = time FILTER time('%Y-%m-%d %H:%M:%S') FILTER html %] -[% PROCESS global/header.html.tmpl +[% PROCESS global/header.html.tmpl style = " .t1 { background-color: #ffffff } /* white */ .t2 { background-color: #dfefff } /* light blue */ - .t3 { background-color: #dddddd } /* grey */ - .t4 { background-color: #c3d3ed } /* darker blue */ + .t3 { background-color: #ffffff } /* white */ + .t4 { background-color: #dfefff } /* light blue */ .ttotal { background-color: #cfffdf } /* light green */ " style_urls = ['skins/standard/reports.css'] @@ -74,9 +73,9 @@

[% query FILTER html %]

[% END %] -
+
- [% FOREACH tbl = tbl_names %] + [% FOREACH tbl = tbl_names %] [% IF tbl == "-total-" %] [% tbl_disp = "Total" %] [% ELSE %] @@ -89,7 +88,7 @@ [% IF tbl %]

[% tbl_disp FILTER email FILTER html %]

[% END %] - + [% imageurl = BLOCK %]report.cgi?[% imagebase FILTER html %]&format= [% format FILTER url_quote %]&ctype=png&action=plot& [% IF tbl_field %] @@ -102,91 +101,93 @@ [% END %] [% END %] [% END %] - [% END %]width=[% width %]&height=[% height %] + [% END %]width=[% width %]&height=[% height %] [% END %] - + Graphical report results [% END %]
- [% END %] + [% END %] - + + + [% FOR k = switchparams.keys.sort %] + + [% END %] +
+ + + + + + + + + [% IF format != "table" %] + + + + + + + [% END %] + + - - [% IF format != "table" %] - - - [% sizeurl = BLOCK %]report.cgi? - [% switchbase %]&action=wrap&format=[% format FILTER html %]&measure=[% measure FILTER html %][% END %] - - [% END %]
+ Format: + + [% formats = [ + { name => "pie", description => "Pie" }, + { name => "bar", description => "Bar" }, + { name => "line", description => "Line" }, + { name => "table", description => "Table" } + ] %] + +
+ Show: + + [% measure_descs = { + rtime => 'Remaining time' + etime => 'Estimated time' + wtime => 'Actual time' + times => 'Estimated/Actual/Remaining' + count => "Number of $terms.bugs" + } %] + +
- [% formats = [ { name => "pie", description => "Pie" }, - { name => "bar", description => "Bar" }, - { name => "line", description => "Line" }, - { name => "table", description => "Table" } ] %] - - [% formaturl = "report.cgi?$switchbase&width=$width" _ - "&height=$height&action=wrap" %] - [% FOREACH other_format = formats %] - [% NEXT IF other_format.name == "pie" AND row_field AND col_field %] - [% UNLESS other_format.name == format %] - - [% END %] - [% other_format.description FILTER html %] - [% "" UNLESS other_format.name == format %] | - [% END %] - CSV + Width: + + +
+ Height: + + +
+ -        - - Taller
- Thinner * - Fatter    
- Shorter
-
- -
- [% measure_descs = { - rtime => 'Remaining time' - etime => 'Estimated time' - wtime => 'Actual time' - times => 'Estimated/Actual/Remaining' - count => "Number of $terms.bugs" - } %] - [% FOR m = measure_descs.keys.sort %] - [% IF m != 'times' || format == 'table' %] - [%+ IF measure != m %][% END %] - [% measure_descs.$m %] - [% IF measure != m %][% END %] - [% IF NOT loop.last %] | [% END %] - [% END %] - [% END %] -
- - -

- [% IF format == "table" %] - Edit - this report - [% ELSE %] - - Edit this report - - [% END %] + +

+ [% IF saved_report_id %] | Forget this report + [%~ issue_hash_token(['delete_report', saved_report_id]) FILTER uri %]">Forget this report [% ELSE %] -
+ as @@ -194,8 +195,8 @@
[% END %] -

- +
+
[% PROCESS global/footer.html.tmpl %]