From 5b36140893a73a26927f0ec4a4a4487f2985c69e Mon Sep 17 00:00:00 2001 From: Lyon3 Team Date: Thu, 9 Jan 2014 13:49:05 +0100 Subject: [PATCH] Bug 11507 - add the possibility to filter order by parent_ordernumber in receipt After a transfer of order in a new basket, the ordernumber is changing. Sometimes, we keep a track the old ordernumber so it can be usefull to be able to retrieve the order by the old ordernumber. This patch add the possibility, when receiving shipment, to enter the old ordernumber and to retrieve the order. Test plan : - choose an order and notes its ordernumber - transfer it to a new a basket and notes the new ordernumber _ in receipt page, in the filter box, enter the older ordernumber or the new ordernumber: you can find the order --- C4/Acquisition.pm | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/C4/Acquisition.pm b/C4/Acquisition.pm index 99933e4..9a01b6e 100644 --- a/C4/Acquisition.pm +++ b/C4/Acquisition.pm @@ -1708,8 +1708,8 @@ sub SearchOrders { } if ( $ordernumber ) { - $query .= ' AND (aqorders.ordernumber=?)'; - push @args, $ordernumber; + $query .= ' AND (aqorders.ordernumber=? OR aqorders.parent_ordernumber=?)'; + push @args, $ordernumber,$ordernumber; } if( $search ) { $query .= ' AND (biblio.title LIKE ? OR biblio.author LIKE ? OR biblioitems.isbn LIKE ?)'; -- 1.7.2.5