]> git.evergreen-ils.org Git - working/Evergreen.git/commit
LP#1037171 Removed Expert Search paramters from subject links user/ldw/lp1037171_subject_links_after_expert_search_eg23
authorLiam Whalen <whalen.ld@gmail.com>
Mon, 7 Oct 2013 07:17:37 +0000 (00:17 -0700)
committerLiam Whalen <whalen.ld@gmail.com>
Mon, 7 Oct 2013 07:17:37 +0000 (00:17 -0700)
commitae0d31f2ead8374c272966061f612ce480628339
treeb4f098d17afff161acf4fecede470e5f0f7137da
parentc45ffa4ec7afd1c7b14ac24e262d065f8e35745c
LP#1037171 Removed Expert Search paramters from subject links

After performing an Expert Search, if a user visits a record and then
clicks on one of the author or subject search links within that record,
then they are given the results of the Expert Search again
instead of the relevant subject or author search.

This is happening because the Expert Search parameters are
retained in the URLs via the TT2 MACRO mkurl.  In particular, the tag
parameter is used to identify an Expert Search, so if it is present in a URL,
than an Expert Search will be attempted regardless of which other
paramaters are in the URL.

To fix this, I created two varialbes within header.tt2 above the
definition of mkurl.  These variables group common URL paramters
for Expert Searches and General Search parameters together.  These
variables can be used wherever mkurl is used to strip out unneeded search
paramters.

There is a third variable that is already present within many of
these pages named stop_parms.  While I initially tried to modify this
variable, I found that there are some instances where the general
search parameters should be retained while the Expert Search parameters
must go.

This commit uses these three variables togehter as input into the
third arugment of the mkurl MACRO.  The third arugment specifies which
paramtes to remove from the previous URL before making a new URL
based on the pervious URL.

I also added the query parameter to the Place Hold's
hold_source_page URL variable.  I did this, so that the query terms would be
preserved once the user is done placing the hold or decides to cancle the
placing of the hold.

As well, I used the new variables to remove Expert Search
paramters from the Advanced Search links on the results and record pages.

Signed-off-by: Liam Whalen <whalen.ld@gmail.com>
Open-ILS/src/templates/opac/parts/header.tt2
Open-ILS/src/templates/opac/parts/record/authors.tt2
Open-ILS/src/templates/opac/parts/record/subjects.tt2
Open-ILS/src/templates/opac/parts/result/table.tt2
Open-ILS/src/templates/opac/parts/searchbar.tt2
Open-ILS/src/templates/opac/results.tt2