From 44965f6040cf6e290d95635741be8ec4e8a69e06 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 9 Jun 2017 10:17:25 -0400 Subject: [PATCH] Bug 18734 - Internal server error in cash_register_stats.pl when exporting to file MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit To test: Output cash reigster stats report to file Internal server error Apply patch Export to file File is generated and correctly formed Signed-off-by: Marc Véron Signed-off-by: Jonathan Druart (cherry picked from commit 855ff0fb9a1cf7755a0805910c367150b37b5f2a) Signed-off-by: Fridolin Somers (cherry picked from commit 8e1cfdbd07bf0dceab147ab5df417d7deedaada8) Signed-off-by: Katrin Fischer --- .../prog/en/includes/csv_headers/reports/cash_register_stats.tt | 2 +- .../prog/en/modules/reports/csv/cash_register_stats.tt | 2 +- reports/cash_register_stats.pl | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/csv_headers/reports/cash_register_stats.tt b/koha-tmpl/intranet-tmpl/prog/en/includes/csv_headers/reports/cash_register_stats.tt index e70f1b5c88..0746a69bb3 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/includes/csv_headers/reports/cash_register_stats.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/includes/csv_headers/reports/cash_register_stats.tt @@ -1 +1 @@ -mfirstname[% sep %]card number[% sep %]firstname[% sep %]branchname[% sep %]date[% sep %]accounttype[% sep %]amount[% sep %]title[% sep %]barcode[% sep %]"itype" +mfirstname[% sep %]card number[% sep %]firstname[% sep %]branchname[% sep %]date[% sep %]accounttype[% sep %]amount[% sep %]title[% sep %]barcode[% sep %]itype diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/csv/cash_register_stats.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/csv/cash_register_stats.tt index fc0b217ad6..caecb0805b 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/csv/cash_register_stats.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/reports/csv/cash_register_stats.tt @@ -1,5 +1,5 @@ [% USE ItemTypes %] -[% INCLUDE csv_headers/reports/cash_register_stats.tt %] +[%- INCLUDE csv_headers/reports/cash_register_stats.tt %] [%- FOREACH row IN rows %] [%- FOREACH field IN row; field IF !loop.last; diff --git a/reports/cash_register_stats.pl b/reports/cash_register_stats.pl index 7d29119104..3bd8cadbff 100755 --- a/reports/cash_register_stats.pl +++ b/reports/cash_register_stats.pl @@ -169,7 +169,7 @@ if ($do_it) { my $csvTemplate = C4::Templates::gettemplate('reports/csv/cash_register_stats.tt', 'intranet', $input); $csvTemplate->param(sep => $delimiter, rows => \@rows, total => \@total ); print $csvTemplate->output; - exit(1); + exit; } } -- 2.39.5