From 2f2613ef6835749f7e85069c3668b465da6d2889 Mon Sep 17 00:00:00 2001 From: Bill Erickson <berick@esilibrary.com> Date: Fri, 2 Sep 2011 15:25:39 -0400 Subject: [PATCH] TPac: Multiple holds in staff client place-holds session Leave the patron_barcode cookie in place after holds placement succeeds from the embedded catalog so that the next hold request will use the same patron. This allows for multiple hold request to take place within one session. The negative is that the cookie sticks around even after a patron session is closed. This is normally not a problem, because each new patron sesion will update the cookie. (And when the cookie is not updated, staff still have the option to /not/ place a hold for the pre-selected user). However, it would be nice to have the staff client clear the cookie at the right time. Will look at that too. Signed-off-by: Bill Erickson <berick@esilibrary.com> --- Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm index e32cd93db4..92858eb59b 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm @@ -647,11 +647,20 @@ sub load_place_hold { sub post_hold_redirect { my $self = shift; + + # XXX: Leave the barcode cookie in place. Otherwise, it's not + # possible to place more than one hold for the patron within + # a staff/patron session. This does leave the barcode to linger + # longer than is ideal, but normal staff work flow will cause the + # cookie to be replaced with each new patron anyway. + # TODO: See about getting the staff client to clear the cookie + return $self->generic_redirect; # We also clear the patron_barcode (from the staff client) # cookie at this point (otherwise it haunts the staff user # later). XXX todo make sure this is best; also see that # template when staff mode calls xulG.opac_hold_placed() + return $self->generic_redirect( undef, $self->cgi->cookie( -- 2.11.0