Make opac/results.tt2 remember facet when sorting, etc.
authorJason Stephenson <jstephenson@mvlc.org>
Wed, 25 Jul 2012 17:43:38 +0000 (13:43 -0400)
committerDan Scott <dscott@laurentian.ca>
Mon, 13 Aug 2012 14:52:24 +0000 (10:52 -0400)
Add a hidden field in the search form and set its value to the value
of the CGI 'facet' param if the facet parameter is set.  This appears
to work for multiple facets.  Clearing a facet is as simple as clicking
on the gray-backgounded facet name.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
Open-ILS/src/templates/opac/results.tt2

index 7b2917e..e5612cc 100644 (file)
@@ -18,6 +18,9 @@
     PROCESS get_library;
 %]
     <form action="[% ctx.opac_root %]/results" method="GET">
+    [% IF CGI.param('facet') %]
+    <input type="hidden" name="facet" value="[% CGI.param('facet') %]" />
+    [% END %]
     <div id="search-wrapper">
         [% INCLUDE "opac/parts/searchbar.tt2" took_care_of_form=1 %]
     </div>