Lines 37-43
my %params = $cgi->Vars;
Link Here
|
37 |
my $format = $cgi->param('format'); |
37 |
my $format = $cgi->param('format'); |
38 |
my ($template_name, $content_type); |
38 |
my ($template_name, $content_type); |
39 |
if (defined $format and $format eq 'json') { |
39 |
if (defined $format and $format eq 'json') { |
40 |
$template_name = 'catalogue/itemsearch.json.tt'; |
40 |
$template_name = 'catalogue/itemsearch_json.tt'; |
41 |
$content_type = 'json'; |
41 |
$content_type = 'json'; |
42 |
|
42 |
|
43 |
# Map DataTables parameters with 'regular' parameters |
43 |
# Map DataTables parameters with 'regular' parameters |
Lines 69-75
if (defined $format and $format eq 'json') {
Link Here
|
69 |
$cgi->param('op', @op); |
69 |
$cgi->param('op', @op); |
70 |
$cgi->param('c', @c); |
70 |
$cgi->param('c', @c); |
71 |
} elsif (defined $format and $format eq 'csv') { |
71 |
} elsif (defined $format and $format eq 'csv') { |
72 |
$template_name = 'catalogue/itemsearch.csv.tt'; |
72 |
$template_name = 'catalogue/itemsearchi_csv.tt'; |
73 |
|
73 |
|
74 |
# Retrieve all results |
74 |
# Retrieve all results |
75 |
$cgi->param('rows', 0); |
75 |
$cgi->param('rows', 0); |