Bug 18083

Summary: Don't show 'library' selection on popular titles page for single-branch libraries
Product: Koha Reporter: Katrin Fischer <katrin.fischer>
Component: OPACAssignee: Te Rauhina Jackson <terauhina.jackson>
Status: CLOSED FIXED QA Contact: Marcel de Rooy <m.de.rooy>
Severity: enhancement    
Priority: P5 - low CC: jonathan.druart, m.de.rooy, nick
Version: MainKeywords: Academy
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: String patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: Bug 18083: Don't show 'library' selection on popular titles page for single-branch libraries
Bug 18083: Don't show 'library' selection on popular titles page for single-branch libraries
Bug 18083: Simplify the condition - if there are more than 1 library

Description Katrin Fischer 2017-02-08 16:02:44 UTC
On the 'popular titles' page in the OPAC there is a search filter labelled "From" that offers you to select a library branch.

For a library with only one branch this makes no sense and it would be nice if it was automatically hidden for single-branch libraries.

Note: Currently not possible to hide with CSS only either.
Comment 1 Te Rauhina Jackson 2018-01-16 03:22:18 UTC Comment hidden (obsolete)
Comment 2 Marcel de Rooy 2018-01-17 15:44:21 UTC
Created attachment 70623 [details] [review]
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.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Amended white space on second change.
Comment 3 Jonathan Druart 2018-01-19 18:43:49 UTC
Created attachment 70771 [details] [review]
Bug 18083: Simplify the condition - if there are more than 1 library
Comment 4 Jonathan Druart 2018-01-19 18:55:43 UTC
Pushed to master for 18.05, thanks to everybody involved!
Comment 5 Nick Clemens 2018-01-23 04:17:42 UTC
Awesome work all!

Enhancement, not backported for 17.11.