From 135794228d792588eb101e6b92cd2d6611b43be7 Mon Sep 17 00:00:00 2001 From: Te Rauhina Jackson Date: Tue, 16 Jan 2018 03:03:47 +0000 Subject: [PATCH] Bug 18083: Don't show 'library' selection on popular titles page for single-branch libraries This patch hides the search filter labelled "From" that offers you to select a library branch which is located on the 'popular titles' page on the OPAC. It is hidden when the library only has one branchas it would be unneccessary to have an option for other branches when there is only one. Test Plan: 1) Make sure you have a single-branch library 2) Make sure OPACTopIssue is allowed in the OPAC preferences 3) In the OPAC, got to 'Most Popular' page 4) Check that there is no "From" filter in the refine search 5) Create a new branch so that you have more than one branch 6) Check that there is a "From" filter in the refine search on the Most Popular page. --- koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-topissues.inc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-topissues.inc b/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-topissues.inc index 2ce6921..6e9b133 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-topissues.inc +++ b/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-topissues.inc @@ -17,11 +17,13 @@ [% IF ( limit == 100 ) %][% ELSE %][% END %] + [% UNLESS Branches.all.size == 1 %]
  • + [% END %] [% AdvancedSearchTypes = Koha.Preference('AdvancedSearchTypes').split('\|') %] [% IF AdvancedSearchTypes.grep('^itemtypes$').size %] -- 2.1.4