]> git.evergreen-ils.org Git - Evergreen.git/commit
Fix LP1175711, OPAC can't renew item on booking resource list
authorSteven Chan <schan@sitka.bclibraries.ca>
Thu, 19 Sep 2013 19:51:35 +0000 (12:51 -0700)
committerKathy Lussier <klussier@masslnc.org>
Tue, 17 Nov 2015 17:08:45 +0000 (12:08 -0500)
commit64057435cd776c1a4f12b32ea3363127832f2047
tree3bac7ff9bfc5e3cbaa19c5562984c65e1dffdc1a
parentbac5b646a52cedec5f5152ff69070611bfbba96a
Fix LP1175711, OPAC can't renew item on booking resource list

A test sequence to show the behaviour before and after the fix:

1. Using staff client, check out an item to test account.
2. Go to Copy Details on the OPAC, click Book Now, and cancel the form;
the side effect is to put the item on the Resource list.
3. Using the OPAC on a web browser, log in with test account.
4. Go to Items Checked Out, select the item in the list and click Renew
Selected Items.

Before the fix, we saw the OPAC spin forever, and we saw the Javascript
console of the web browser log the error noted in previous comments.

With the fix, we see an error prompt saying, 'The system is unable to
renew the selected item at this time.  This usually means the item is
needed to fulfill a hold.  Please see a librarian for further help.'

Note: A patron with the normal group of permissions will not be able to
renew an item on resource list.

The fix is to check for an error object emitted by the function
Booking.pm/reservation_list_by_filters(), and to propagate it back to
the client, by returning a call to bail_on_events().

We also clarify the coding of the function's parameter list and how the
function checks for mandatory parameters.

Signed-off-by: Steven Chan <schan@sitka.bclibraries.ca>
Signed-off-by: Josh Stompro <stomproj@larl.org>
Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Open-ILS/src/perlmods/lib/OpenILS/Application/Booking.pm
Open-ILS/src/perlmods/lib/OpenILS/Application/Circ/Circulate.pm