@@ -, +, @@ prog theme facet display fix makes it so we hide the items, not the biblio. so that Number of results found indicator is correct, and auto-redirect to details when ONLY one result is returned works. no search results returned. --- C4/Search.pm | 6 ------ koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tt | 2 +- opac/opac-search.pl | 2 +- 3 files changed, 2 insertions(+), 8 deletions(-) --- a/C4/Search.pm +++ a/C4/Search.pm @@ -1867,17 +1867,11 @@ sub searchResults { # OPAC hidden items if ($is_opac) { - # hidden because lost - if ($hidelostitems && $item->{itemlost}) { - $hideatopac_count++; - next; - } # hidden based on OpacHiddenItems syspref my @hi = C4::Items::GetHiddenItemnumbers($item); if (scalar @hi) { push @hiddenitems, @hi; $hideatopac_count++; - next; } } --- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tt +++ a/koha-tmpl/opac-tmpl/prog/en/modules/opac-results.tt @@ -757,7 +757,7 @@ $(document).ready(function(){ - [% IF ( opacfacets ) %] + [% IF ( opacfacets && SEARCH_RESULTS.size ) %]
[% INCLUDE 'opac-facets.inc' %] --- a/opac/opac-search.pl +++ a/opac/opac-search.pl @@ -610,7 +610,7 @@ for (my $i=0;$i<@servers;$i++) { } if ($results_hashref->{$server}->{"hits"}){ - $total = $total + $results_hashref->{$server}->{"hits"}; + $total = @newresults; # newresults will just have the hidden biblios filtered (see Search) } # Opac search history --