From 2007ce3a25c2ef720a065ba278169800c1e04f57 Mon Sep 17 00:00:00 2001 From: Henri-Damien LAURENT Date: Thu, 20 Mar 2008 16:08:33 +0100 Subject: [PATCH] Some Bugfixing for Acquisitions : ModOrderReceive would create 2 lines in baskets And titles were displayed twice in parcel.tmpl Signed-off-by: Joshua Ferraro --- C4/Acquisition.pm | 16 +++++++--------- .../prog/en/modules/acqui/parcel.tmpl | 1 - 2 files changed, 7 insertions(+), 10 deletions(-) diff --git a/C4/Acquisition.pm b/C4/Acquisition.pm index 2b2f001986..e7547fd8a5 100644 --- a/C4/Acquisition.pm +++ b/C4/Acquisition.pm @@ -506,22 +506,23 @@ sub ModOrder { $ordnum, $bibnum ); $sth->finish; + my $branchcode; $query = " UPDATE aqorderbreakdown - SET bookfundid=? + SET bookfundid=?,branchcode=? WHERE ordernumber=? "; $sth = $dbh->prepare($query); - unless ( $sth->execute( $bookfund, $ordnum ) ) + unless ( $sth->execute( $bookfund,$branchcode, $ordnum ) ) { # zero rows affected [Bug 734] my $query =" INSERT INTO aqorderbreakdown - (ordernumber,bookfundid) - VALUES (?,?) + (ordernumber,branchcode,bookfundid) + VALUES (?,?,?) "; $sth = $dbh->prepare($query); - $sth->execute( $ordnum, $bookfund ); + $sth->execute( $ordnum,$branchcode, $bookfund ); } $sth->finish; } @@ -626,10 +627,7 @@ sub ModReceiveOrder { $order->{'listprice'},$order->{'booksellerid'},$order->{'authorisedby'},$order->{'notes'}, $order->{'bookfundid'},$order->{'biblioitemnumber'},$order->{'rrp'},$order->{'ecost'},$order->{'gst'}, $order->{'budget'},$order->{'unitcost'},$order->{'sub'},'',$order->{'sort1'},$order->{'sort2'},$order->{'purchaseordernumber'}); - - $sth=$dbh->prepare(" insert into aqorderbreakdown (ordernumber, branchcode, bookfundid) values (?,?,?)"); - $sth->execute($newOrder,$order->{branch},$order->{bookfundid}); - } else { + } else { $sth=$dbh->prepare("update aqorders set quantityreceived=?,datereceived=?,booksellerinvoicenumber=?, unitprice=?,freight=?,rrp=? diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tmpl b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tmpl index e3f8509422..645e1d7031 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tmpl +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/parcel.tmpl @@ -120,7 +120,6 @@ "> "> -
ISBN:
author :
Publisher : -- 2.39.5