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');
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;
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,