my $totpages = int($total/$limit) + (($total % $limit) > 0 ? 1 : 0);
my $url = "/cgi-bin/koha/reports/guided_reports.pl?reports=$report_id&phase=Run%20this%20report&limit=$limit";
if (@sql_params) {
- $url = join('&sql_params=', $url, map { URI::Escape::uri_escape_utf8($_) } @sql_params);
+ $url = join('&sql_params=', $url, map { URI::Escape::uri_escape($_) } @sql_params);
}
$template->param(
'results' => \@rows,
'errors' => $errors,
'pagination_bar' => pagination_bar($url, $totpages, $input->param('page')),
'unlimited_total' => $total,
+ 'sql_params' => \@sql_params,
);
}
}
use strict;
use Data::Dumper;
use POSIX;
- use CGI qw/-utf8/;
+ use CGI;
use CGI::Cookie; # need to check cookies before having CGI parse the POST request
use C4::Auth qw(:DEFAULT check_cookie_auth);
});
my ($op, @errors, @tags);
-$op = lc($input->param('op')) || 'none';
+
+foreach (qw( approve reject test )) {
+ $op = $_ if ( $input->param("op-$_") );
+}
+$op ||= 'none';
+
@tags = $input->param('tags');
$borrowernumber == 0 and push @errors, {op_zero=>1};