From: Llewellyn Marshall Date: Thu, 25 Aug 2022 21:16:34 +0000 (-0400) Subject: add documentation & return active date to y-m-d X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=refs%2Fheads%2Fuser%2Flew%2Fthaw_on_open;p=working%2FEvergreen.git add documentation & return active date to y-m-d --- 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 9396ed9a6f..352497fbf0 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Account.pm @@ -1549,13 +1549,16 @@ sub load_place_hold { } } elsif ($cgi->param('hold_suspend') =~ /p/) { + # suspend hold for pickup library. + # if library is closed, suspend until + # the next day the library operates. eval { my $thaw_date_str = $U->simplereq( 'open-ils.actor', - 'open-ils.actor.org_unit.next_operating_hour', $cgi->param('pickup_lib') || $self->ctx->{search_ou}); - #my $thaw_dt = DateTime::Format::ISO8601->parse_datetime($thaw_date_str); - $ctx->{thaw_date} = $thaw_date_str; - $ctx->{frozen} = 1; + 'open-ils.actor.org_unit.next_operating_hour', $cgi->param('pickup_lib') || $self->ctx->{search_ou}); + my $thaw_dt = DateTime::Format::ISO8601->parse_datetime($thaw_date_str); + $ctx->{thaw_date} = $thaw_dt->ymd; + $ctx->{frozen} = 1; }; if ($@) { $logger->warn("ignoring next_open_time when placing hold request");