From 2f59f1c2e4e83ec2b2e35d3633ee7efad22945c6 Mon Sep 17 00:00:00 2001 From: Ryan Higgins Date: Fri, 20 Jun 2008 15:56:40 -0500 Subject: [PATCH] Another API call fix to get the vendor name. Signed-off-by: Joshua Ferraro --- acqui/parcel.pl | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/acqui/parcel.pl b/acqui/parcel.pl index fb95c55e64..5823554857 100755 --- a/acqui/parcel.pl +++ b/acqui/parcel.pl @@ -66,8 +66,7 @@ use strict; my $input=new CGI; my $supplierid=$input->param('supplierid'); -my @booksellers=GetBookSeller($supplierid); -my $count = scalar @booksellers; +my $bookseller=GetBookSellerFromId($supplierid); my $invoice=$input->param('invoice') || ''; my $freight=$input->param('freight'); @@ -121,8 +120,6 @@ for (my $i=0;$i<$countlines;$i++){ if ( $i > 0 && $totalfreight != $parcelitems[$i]->{'freight'}) { warn "FREIGHT CHARGE MISMATCH!!"; } - $totalfreight=$parcelitems[$i]->{'freight'}; - #$totalfreight+=$parcelitems[$i]->{'freight'}; $totalfreight=$parcelitems[$i]->{'freight'}; $totalquantity+=$parcelitems[$i]->{'quantityreceived'}; $tototal+=$total; @@ -163,14 +160,14 @@ for (my $i=0;$i<$countpendings;$i++){ push @loop_orders, \%line; } $freight = $totalfreight unless $freight; -$totalfreight=$freight; +#$totalfreight=$freight; $tototal=$tototal+$freight; $template->param(invoice => $invoice, datereceived => $datereceived->output('iso'), invoicedatereceived => $datereceived->output('iso'), formatteddatereceived => $datereceived->output(), - name => $booksellers[0]->{'name'}, + name => $bookseller->{'name'}, supplierid => $supplierid, gst => $gst, freight => $freight, -- 2.39.5