Lines 30-44
use Modern::Perl;
Link Here
|
30 |
use C4::Context; |
30 |
use C4::Context; |
31 |
|
31 |
|
32 |
my $searchengine = C4::Context->preference("SearchEngine"); |
32 |
my $searchengine = C4::Context->preference("SearchEngine"); |
33 |
for ( $searchengine ) { |
33 |
if ( $searchengine =~ /^Solr$/ ) { |
34 |
when ( /^Solr$/ ) { |
34 |
warn "We use Solr"; |
35 |
warn "We use Solr"; |
35 |
require 'opac/search.pl'; |
36 |
require 'opac/search.pl'; |
36 |
exit; |
37 |
exit; |
37 |
} elsif ( $searchengine =~ /^Zebra$/ ) { |
38 |
} |
|
|
39 |
when ( /^Zebra$/ ) { |
40 |
|
38 |
|
41 |
} |
|
|
42 |
} |
39 |
} |
43 |
|
40 |
|
44 |
use C4::Output; |
41 |
use C4::Output; |
Lines 360-366
my @allowed_sortby = qw /acqdate_asc acqdate_dsc author_az author_za call_number
Link Here
|
360 |
@sort_by = $cgi->param('sort_by'); |
357 |
@sort_by = $cgi->param('sort_by'); |
361 |
$sort_by[0] = $default_sort_by if !$sort_by[0] && defined($default_sort_by); |
358 |
$sort_by[0] = $default_sort_by if !$sort_by[0] && defined($default_sort_by); |
362 |
foreach my $sort (@sort_by) { |
359 |
foreach my $sort (@sort_by) { |
363 |
if ( $sort ~~ @allowed_sortby ) { |
360 |
if ( grep { /^$sort$/ } @allowed_sortby ) { |
364 |
$template->param($sort => 1); |
361 |
$template->param($sort => 1); |
365 |
} |
362 |
} |
366 |
} |
363 |
} |
367 |
- |
|
|