Pass token so that we can view our own bookbags
authorJeff Godin <jgodin@tadl.org>
Thu, 22 May 2014 17:11:26 +0000 (13:11 -0400)
committerJeff Godin <jgodin@tadl.org>
Tue, 7 Apr 2015 15:29:56 +0000 (11:29 -0400)
Pass an auth token (if available) to the container() search when
searching for bookbags -- this allows us to HTML view our own lists.

Signed-off-by: Jeff Godin <jgodin@tadl.org>
Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm

index 19f3a25..33f0daa 100644 (file)
@@ -88,7 +88,10 @@ sub _prepare_biblio_search {
     }
 
     if ($cgi->param("bookbag")) {
-        $query = "container(bre,bookbag," . int($cgi->param("bookbag")) . ") $query";
+        # Pass an auth token if we have one, so that we can search for our own bookbags
+
+        my $container_token = $ctx->{authtoken} || '';
+        $query = "container(bre,bookbag," . int($cgi->param("bookbag")) . "," . $container_token . ") $query";
     }
 
     # Journal title hackery complete