|
Lines 556-561
for (my $i=0;$i<@servers;$i++) {
Link Here
|
| 556 |
@newresults = searchResults('opac', $query_desc, $hits, $results_per_page, $offset, $scan, |
556 |
@newresults = searchResults('opac', $query_desc, $hits, $results_per_page, $offset, $scan, |
| 557 |
$results_hashref->{$server}->{"RECORDS"}); |
557 |
$results_hashref->{$server}->{"RECORDS"}); |
| 558 |
} |
558 |
} |
|
|
559 |
$hits = 0 unless @newresults; |
| 559 |
|
560 |
|
| 560 |
foreach my $res (@newresults) { |
561 |
foreach my $res (@newresults) { |
| 561 |
|
562 |
|
|
Lines 610-616
for (my $i=0;$i<@servers;$i++) {
Link Here
|
| 610 |
} |
611 |
} |
| 611 |
|
612 |
|
| 612 |
if ($results_hashref->{$server}->{"hits"}){ |
613 |
if ($results_hashref->{$server}->{"hits"}){ |
| 613 |
$total = $total + $results_hashref->{$server}->{"hits"}; |
614 |
$total = $total + $hits; |
| 614 |
} |
615 |
} |
| 615 |
|
616 |
|
| 616 |
# Opac search history |
617 |
# Opac search history |
|
Lines 656-662
for (my $i=0;$i<@servers;$i++) {
Link Here
|
| 656 |
} |
657 |
} |
| 657 |
} |
658 |
} |
| 658 |
## If there's just one result, redirect to the detail page |
659 |
## If there's just one result, redirect to the detail page |
| 659 |
if ($total == 1 && $format ne 'rss2' |
660 |
if ( @newresults && $total == 1 && $format ne 'rss2' |
| 660 |
&& $format ne 'opensearchdescription' && $format ne 'atom') { |
661 |
&& $format ne 'opensearchdescription' && $format ne 'atom') { |
| 661 |
my $biblionumber=$newresults[0]->{biblionumber}; |
662 |
my $biblionumber=$newresults[0]->{biblionumber}; |
| 662 |
if (C4::Context->preference('BiblioDefaultView') eq 'isbd') { |
663 |
if (C4::Context->preference('BiblioDefaultView') eq 'isbd') { |
| 663 |
- |
|
|