[Koha-patches] [Signed off 3.2] Bug 6366 - Corrects GetSuppliersWithLateIssues

Colin Campbell colin.campbell at ptfs-europe.com
Fri May 20 12:48:58 CEST 2011


From: Frédérick Capovilla <frederick.capovilla at sys-tech.net>

GetSuppliersWithLateIssues returned every supplier with an order with a
planneddate in the past, even if the order was received.
I modified the query so it doesn't see a received order as "late".
---
 C4/Serials.pm |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/C4/Serials.pm b/C4/Serials.pm
index 3fcbac6..f2f1894 100644
--- a/C4/Serials.pm
+++ b/C4/Serials.pm
@@ -96,7 +96,7 @@ sub GetSuppliersWithLateIssues {
     FROM            subscription
     LEFT JOIN       serial ON serial.subscriptionid=subscription.subscriptionid
     LEFT JOIN aqbooksellers ON subscription.aqbooksellerid = aqbooksellers.id
-    WHERE id > 0 AND (planneddate < now() OR serial.STATUS = 3 OR serial.STATUS = 4) ORDER BY name|;
+    WHERE id > 0 AND ((planneddate < now() AND serial.STATUS =1) OR serial.STATUS = 3 OR serial.STATUS = 4) ORDER BY name|;
     return $dbh->selectall_arrayref($query, { Slice => {} });
 }
 
-- 
1.7.4.4



More information about the Koha-patches mailing list