[Koha-patches] [PATCH] bug 2540: allow download of report
henridamien.laurent at biblibre.com
henridamien.laurent at biblibre.com
Fri Mar 6 11:37:51 CET 2009
From: Galen Charlton <galen.charlton at liblime.com>
$error return C4::Reports::execute_query is
always defined.
Signed-off-by: Galen Charlton <galen.charlton at liblime.com>
Signed-off-by: Henri-Damien LAURENT <henridamien.laurent at biblibre.com>
---
reports/guided_reports.pl | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/reports/guided_reports.pl b/reports/guided_reports.pl
index 65c4110..eb50d65 100755
--- a/reports/guided_reports.pl
+++ b/reports/guided_reports.pl
@@ -403,7 +403,7 @@ elsif ($phase eq 'Export'){
my $sql = $input->param('sql');
my $format = $input->param('format');
my ($results, $total, $errors) = execute_query($sql,1,0,0,$format);
- if (!@$errors) {
+ if ($#$errors == -1) {
$no_html=1;
print $input->header( -type => 'application/octet-stream',
-attachment=>'reportresults.csv'
--
1.5.6.3
More information about the Koha-patches
mailing list