Bug 31271: Preselect previous search index

This patch passes the constructed value of the preselect to search_indexes.inc

To test:
1 - Perform an advanced search, making sure to select different indexes
2 - Click 'Edit search' on results page
3 - Confirm index selections are preselected
4 - Enable  IntranetCatalogSearchPulldown
5 - Do a search form the top bar using an index
6 - Confirm 'Edit search' correctly popluates the chosen index

Signed-off-by: Andrew Fuerste-Henry <andrewfh@dubcolib.org>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Nick Clemens 2022-11-03 12:29:59 +00:00 committed by Tomas Cohen Arazi
parent 2621f28376
commit 0106f3957d
No known key found for this signature in database
GPG Key ID: 0A272EA1B2F3C15F
1 changed files with 1 additions and 1 deletions

View File

@ -170,7 +170,7 @@
<div>
[% END %]
[% SET preselect = 'ms_' _ indexes.${loop.index}.replace(',','comma') %]
[% INCLUDE 'search_indexes.inc' %]
[% INCLUDE 'search_indexes.inc' ${preselect} = 1 %]
<input type="text" size="30" name="q" title="Enter search terms" value="[% query | html %]" />
[% IF ( expanded_options ) %]
[% IF ( loop.last ) %]