Enh 7031: More options for Advanced Search
authorIan Walls <ian.walls@bywatersolutions.com>
Wed, 27 Jul 2011 18:08:23 +0000 (14:08 -0400)
committerPaul Poulain <paul.poulain@biblibre.com>
Wed, 14 Mar 2012 13:35:27 +0000 (14:35 +0100)
commitc04404c2fb2ffe3ae504e8055cd16eaba120d206
treefffddd07c211c931250e2cd9640e76dc4e73d3ef
parent49c387cddf6de083343fe6c88ad9f167844521b4
Enh 7031: More options for Advanced Search

Adds the ability to perform advanced searches in both the OPAC and staff client on more than
a single AdvancedSearchType at a time.  Support included for Itemtype, Collection Code and Shelving Location.

AdvancedSearchTypes syspref preference is repurposed; no longer a single value, it can now take
multiple item code fields separated by "|".  The order of these fields will determine the order
of the tabs in the OPAC and staff client advanced search screens.  Values within the search type
are OR'ed together, while each different search type is AND'ed together in the query limits.  The
current stored values are supported without any required modification.

Each set of advanced search fields are displayed in tabs in both the OPAC and staff client.  The
first value in the AdvancedSearchTypes syspref is the selected tab; if no values are present, "itemtypes"
is used.  For non-itemtype values, the value in AdvancedSearchTypes must match the Authorised Value name, and
must be indexed with 'mc-' prefixing that name.

<li> elements in tab are assigned unique IDs, so the text of the tab can be altered to match the
library's needs (using JQuery)

The logic to handle the 5 element row limit has been moved from the Perl to the templates, since Template::Toolkit
has a simple method for extracting the count of an element in a loop and performing 'modulus' on it.

2011-12-21: Incorporated changes recommend by Owen Leonard on bug report.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
C4/Search.pm
catalogue/search.pl
koha-tmpl/intranet-tmpl/prog/en/css/staff-global.css
koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/searching.pref
koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/advsearch.tt
koha-tmpl/opac-tmpl/prog/en/css/opac.css
koha-tmpl/opac-tmpl/prog/en/modules/opac-advsearch.tt
opac/opac-search.pl