From 871d4b12d78c58fdb7151ade2d1b9c87faad27b2 Mon Sep 17 00:00:00 2001 From: "lpsolit%gmail.com" <> Date: Wed, 15 Jun 2005 05:43:11 +0000 Subject: Bug 296180: Table and CSV reports should use localised terms for statuses and resolutions - Patch by Emmanuel Seyman - r/a=myk --- template/en/default/reports/report-table.csv.tmpl | 16 ++++++++++++++-- template/en/default/reports/report-table.html.tmpl | 16 ++++++++++++++-- 2 files changed, 28 insertions(+), 4 deletions(-) (limited to 'template/en/default/reports') diff --git a/template/en/default/reports/report-table.csv.tmpl b/template/en/default/reports/report-table.csv.tmpl index 216419fea..42fcd6686 100644 --- a/template/en/default/reports/report-table.csv.tmpl +++ b/template/en/default/reports/report-table.csv.tmpl @@ -43,14 +43,26 @@ [% title %], [% IF col_field -%] [% FOREACH col = col_names -%] - [% col FILTER csv -%], + [% IF col_field == 'bug_status' %] + [% status_descs.$col FILTER csv -%] + [% ELSIF col_field == 'resolution' %] + [% resolution_descs.$col FILTER csv -%] + [% ELSE %] + [% col FILTER csv -%], + [% END %] [% END -%] [% ELSE -%] [% num_bugs %], [% END %] [% FOREACH row = row_names %] - [% row FILTER csv -%], +[% IF row_field == 'bug_status' %] + [% status_descs.$row FILTER csv -%] + [% ELSIF row_field == 'resolution' %] + [% resolution_descs.$row FILTER csv -%] + [% ELSE %] + [% row FILTER csv -%], + [% END %] [% FOREACH col = col_names %] [% IF data.$tbl AND data.$tbl.$col AND data.$tbl.$col.$row %] [% data.$tbl.$col.$row -%], diff --git a/template/en/default/reports/report-table.html.tmpl b/template/en/default/reports/report-table.html.tmpl index 3c90d5bf2..0e2ae62c8 100644 --- a/template/en/default/reports/report-table.html.tmpl +++ b/template/en/default/reports/report-table.html.tmpl @@ -85,7 +85,13 @@ [% col_idx = 1 - col_idx %] - [% col FILTER html FILTER replace('^ $',' ') %] + [% IF col_field == 'bug_status' %] + [% status_descs.$col FILTER html FILTER replace('^ $',' ') %] + [% ELSIF col_field == 'resolution' %] + [% resolution_descs.$col FILTER html FILTER replace('^ $',' ') %] + [% ELSE %] + [% col FILTER html FILTER replace('^ $',' ') %] + [% END %] [% END %] @@ -100,7 +106,13 @@ [% row_idx = 1 - row_idx %] - [% row FILTER html FILTER replace('^ $',' ') %] + [% IF row_field == 'bug_status' %] + [% status_descs.$row FILTER html FILTER replace('^ $',' ') %] + [% ELSIF row_field == 'resolution' %] + [% resolution_descs.$row FILTER html FILTER replace('^ $',' ') %] + [% ELSE %] + [% row FILTER html FILTER replace('^ $',' ') %] + [% END %] [% FOREACH col = col_names %] [% row_total = row_total + data.$tbl.$col.$row %] -- cgit v1.2.3-24-g4f1b