Include calculated 0-prox locations in the stalling interval for op capture
authorMike Rylander <mrylander@gmail.com>
Fri, 7 Feb 2014 21:00:01 +0000 (16:00 -0500)
committerBen Shum <bshum@biblio.org>
Sun, 9 Feb 2014 12:22:51 +0000 (07:22 -0500)
Signed-off-by: Mike Rylander <mrylander@gmail.com>
Signed-off-by: Ben Shum <bshum@biblio.org>
Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Publisher/action.pm

index acfd245..912996d 100644 (file)
@@ -548,7 +548,7 @@ sub nearest_hold {
                 ON ( csp.id = ausp.standing_penalty AND csp.block_list LIKE '%CAPTURE%' )
             $addl_join
           WHERE hm.target_copy = ?
-            AND (AGE(NOW(),h.request_time) >= CAST(? AS INTERVAL) OR p.prox = 0)
+            AND (AGE(NOW(),h.request_time) >= CAST(? AS INTERVAL) OR hm.proximity = 0 OR p.prox = 0)
             AND h.capture_time IS NULL
             AND h.cancel_time IS NULL
             AND (h.expire_time IS NULL OR h.expire_time > NOW())