From: Jason Stephenson Date: Mon, 22 Oct 2018 19:17:14 +0000 (-0400) Subject: Lp 1799272: Limit SIP2 hold items to available hold items. X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=refs%2Fheads%2Fuser%2Fdyrcona%2Flp1799272-limit-sip2-hold-items-to-available;p=working%2FEvergreen.git Lp 1799272: Limit SIP2 hold items to available hold items. Only inlcude holds that are available for pickup in the hold items count and hold items fields of the SIP2 patron information response. Given some confusion over the purpose of this field, that there is also a field to list unavailable holds, and that a list of holds avaialable for pickup would be more useful than a list of all holds to a patron using a self-check, this seems like a good change. Signed-off-by: Jason Stephenson --- diff --git a/Open-ILS/src/perlmods/lib/OpenILS/SIP/Patron.pm b/Open-ILS/src/perlmods/lib/OpenILS/SIP/Patron.pm index 3b458cb784..67bc8ef007 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/SIP/Patron.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/SIP/Patron.pm @@ -514,18 +514,19 @@ sub too_many_billed { # -# List of outstanding holds placed +# List of available holds # sub hold_items { my ($self, $start, $end, $ids_only) = @_; syslog('LOG_DEBUG', 'OILS: Patron->hold_items()'); - # all of my open holds + # all of my available holds my $holds = $self->{editor}->search_action_hold_request({ - usr => $self->{user}->id, - fulfillment_time => undef, - cancel_time => undef + usr => $self->{user}->id, + fulfillment_time => undef, + cancel_time => undef, + current_shelf_lib => {'=' => {'+ahr' => 'pickup_lib'}} }); return $holds if $ids_only;