Bugzilla – Attachment 44996 Details for
Bug 15062
Holds queue with Transport Cost Matrix will transfer item even if transfers disabled
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15062 - Holds queue with Transport Cost Matrix will transfer item even if transfers disabled
Bug-15062---Holds-queue-with-Transport-Cost-Matrix.patch (text/plain), 2.14 KB, created by
Kyle M Hall (khall)
on 2015-11-19 12:55:12 UTC
(
hide
)
Description:
Bug 15062 - Holds queue with Transport Cost Matrix will transfer item even if transfers disabled
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2015-11-19 12:55:12 UTC
Size:
2.14 KB
patch
obsolete
>From fdd7b4cc88270ef8a53c2520fd86303e34d2d371 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Mon, 26 Oct 2015 08:30:57 -0400 >Subject: [PATCH] Bug 15062 - Holds queue with Transport Cost Matrix will > transfer item even if transfers disabled >MIME-Version: 1.0 >Content-Type: text/plain; charset=UTF-8 >Content-Transfer-Encoding: 8bit > >If the transfer of an item from Library A to Library B is disabled in >the Transport Cost Matrix, but the only item on a record is from Library >A, the holds queue will request a transfer of that item from Library A >to Library B even though the rules state such a transfer is not allowed! > >Test Plan: >1) Enable the transport cost matrix >2) For simplicity, leave all cells disabled on it, save this state. > This state means that only items at each location should fill > holds where the pickup library is that same location. >3) Create a record with one item, set its home and holding branch > to Library A >4) Create a hold for pickup at Library B >5) Rebuild the holds queue >6) Note the transfer request for the item to Library B >7) Apply this patch >8) Rebuild the holds queue >9) Note the transfer request is gone > >Signed-off-by: Andreas Hedström Mace <andreas.hedstrom.mace@sub.su.se> >--- > C4/HoldsQueue.pm | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/C4/HoldsQueue.pm b/C4/HoldsQueue.pm >index 08f6307..f5a9be7 100755 >--- a/C4/HoldsQueue.pm >+++ b/C4/HoldsQueue.pm >@@ -446,7 +446,7 @@ sub MapItemsToHoldRequests { > } > } > else { >- warn "No transport costs for $pickup_branch"; >+ next; > } > } > >@@ -618,7 +618,7 @@ sub least_cost_branch { > > # Nothing really spectacular: supply to branch, a list of potential from branches > # and find the minimum from - to value from the transport_cost_matrix >- return $from->[0] if @$from == 1; >+ return $from->[0] if ( @$from == 1 && $transport_cost_matrix->{$to}{$from->[0]}->{disable_transfer} != 1 ); > > # If the pickup library is in the list of libraries to pull from, > # return that library right away, it is obviously the least costly >-- >1.7.10.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 15062
:
43984
|
44202
|
44993
|
44994
|
44995
|
44996
|
45041
|
45042