[open-ils-commits] r18515 - branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Circ (senator)
svn at svn.open-ils.org
svn at svn.open-ils.org
Wed Oct 27 17:21:35 EDT 2010
Author: senator
Date: 2010-10-27 17:21:30 -0400 (Wed, 27 Oct 2010)
New Revision: 18515
Modified:
branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm
Log:
Backport r18514 from trunk, more circ speedups when booking not in play
Modified: branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm
===================================================================
--- branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm 2010-10-27 21:20:53 UTC (rev 18514)
+++ branches/rel_2_0/Open-ILS/src/perlmods/OpenILS/Application/Circ/Circulate.pm 2010-10-27 21:21:30 UTC (rev 18515)
@@ -2323,23 +2323,27 @@
if(!$self->noop) { # /not/ a no-op checkin, capture for hold or put item into transit
if (!$self->remote_hold) {
- my $potential_hold = $self->hold_capture_is_possible;
- my $potential_reservation = $self->use_booking && $self->reservation_capture_is_possible;
+ if ($self->use_booking) {
+ my $potential_hold = $self->hold_capture_is_possible;
+ my $potential_reservation = $self->reservation_capture_is_possible;
- if ($potential_hold and $potential_reservation) {
- $logger->info("circulator: item could fulfill either hold or reservation");
- $self->push_events(new OpenILS::Event(
- "HOLD_RESERVATION_CONFLICT",
- "hold" => $potential_hold,
- "reservation" => $potential_reservation
- ));
- return if $self->bail_out;
- } elsif ($potential_hold) {
- $needed_for_something =
- $self->attempt_checkin_hold_capture;
- } elsif ($potential_reservation) {
- $needed_for_something =
- $self->attempt_checkin_reservation_capture;
+ if ($potential_hold and $potential_reservation) {
+ $logger->info("circulator: item could fulfill either hold or reservation");
+ $self->push_events(new OpenILS::Event(
+ "HOLD_RESERVATION_CONFLICT",
+ "hold" => $potential_hold,
+ "reservation" => $potential_reservation
+ ));
+ return if $self->bail_out;
+ } elsif ($potential_hold) {
+ $needed_for_something =
+ $self->attempt_checkin_hold_capture;
+ } elsif ($potential_reservation) {
+ $needed_for_something =
+ $self->attempt_checkin_reservation_capture;
+ }
+ } else {
+ $needed_for_something = $self->attempt_checkin_hold_capture;
}
}
return if $self->bail_out;
More information about the open-ils-commits
mailing list