From: erickson Date: Wed, 6 Sep 2006 18:11:48 +0000 (+0000) Subject: finding maxfines items for renew X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=4eb5d7b756e3f05a7ecb74f500387cae1c30d81e;p=Evergreen.git finding maxfines items for renew git-svn-id: svn://svn.open-ils.org/ILS/trunk@6003 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm b/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm index df1d561c30..25af8fabb6 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm @@ -1656,6 +1656,16 @@ sub do_renew { my $circ = $self->editor->search_action_circulation( { target_copy => $self->copy->id, stop_fines => undef } )->[0]; + if(!$circ) { + $circ = $self->editor->search_action_circulation( + { + target_copy => $self->copy->id, + stop_fines => OILS_STOP_FINES_MAX_FINES, + checkin_time => undef + } + )->[0]; + } + return $self->bail_on_events($self->editor->event) unless $circ; $self->push_events(OpenILS::Event->new('MAX_RENEWALS_REACHED'))