From e1143e57ae10ac6128f9ec7af2cc9f37d55c59bb Mon Sep 17 00:00:00 2001 From: "travis%sedsystems.ca" <> Date: Sat, 12 Mar 2005 10:58:23 +0000 Subject: [PATCH] Bug 262848 : tabular reports don't show columns with empty header Patch by Rob Siklos r=gerv a=myk --- report.cgi | 8 +++++++- template/en/default/reports/report-table.html.tmpl | 4 ++-- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/report.cgi b/report.cgi index a4df4d08fd..b89f507156 100755 --- a/report.cgi +++ b/report.cgi @@ -164,6 +164,12 @@ my $tbl_isnumeric = 1; while (MoreSQLData()) { my ($row, $col, $tbl) = FetchSQLData(); + + # handle empty dimension member names + $row = ' ' if ($row eq ''); + $col = ' ' if ($col eq ''); + $tbl = ' ' if ($tbl eq ''); + $row = "" if ($row eq $columns{''}); $col = "" if ($col eq $columns{''}); $tbl = "" if ($tbl eq $columns{''}); @@ -324,7 +330,7 @@ sub get_names { 'rep_platform' => \@::legal_platform, 'op_sys' => \@::legal_opsys, 'bug_status' => \@::legal_bug_status, - 'resolution' => \@::legal_resolution); + 'resolution' => [' ', @::legal_resolution]); my $field_list = $fields{$field}; my @sorted; diff --git a/template/en/default/reports/report-table.html.tmpl b/template/en/default/reports/report-table.html.tmpl index 21ff1b8744..3c90d5bf2f 100644 --- a/template/en/default/reports/report-table.html.tmpl +++ b/template/en/default/reports/report-table.html.tmpl @@ -85,7 +85,7 @@ [% col_idx = 1 - col_idx %] - [% col FILTER html %] + [% col FILTER html FILTER replace('^ $',' ') %] [% END %] @@ -100,7 +100,7 @@ [% row_idx = 1 - row_idx %] - [% row FILTER html %] + [% row FILTER html FILTER replace('^ $',' ') %] [% FOREACH col = col_names %] [% row_total = row_total + data.$tbl.$col.$row %] -- 2.47.2