From 9a96b0e198c66a68d334ed86c2cb7754b1a28fb1 Mon Sep 17 00:00:00 2001 From: tetragon Date: Sat, 28 Oct 2006 18:29:12 +0000 Subject: Adjust BP/bp to run git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@361 4979c152-3d1c-0410-bac9-87ea11338e46 --- LedgerSMB/BP.pm | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'LedgerSMB/BP.pm') diff --git a/LedgerSMB/BP.pm b/LedgerSMB/BP.pm index 0a084798..d15dc018 100755 --- a/LedgerSMB/BP.pm +++ b/LedgerSMB/BP.pm @@ -75,7 +75,7 @@ sub get_vc { $sth = $dbh->prepare($query); $sth->execute($form->{type}); - ($n) = $sth->fetchrow_array($query); + ($n) = $sth->fetchrow_array; $count += $n; } @@ -97,7 +97,7 @@ sub get_vc { WHERE s.formname = ? AND s.spoolfile IS NOT NULL|; $union = "UNION"; - push @queryags, $form->{type}; + push @queryargs, $form->{type}; } $sth = $dbh->prepare($query); @@ -199,14 +199,14 @@ sub get_spoolfiles { $union SELECT a.id, vc.name, a.$invnumber AS invnumber, a.transdate, a.ordnumber, a.quonumber, $invoice AS invoice, - ? AS module, s.spoolfile + '$item' AS module, s.spoolfile FROM $item a, $form->{vc} vc, status s WHERE s.trans_id = a.id AND s.spoolfile IS NOT NULL AND s.formname = ? AND a.$form->{vc}_id = vc.id|; - push (@queryargs, $item, $form->{type}); + push (@queryargs, $form->{type}); if ($form->{"$form->{vc}_id"}) { $query .= qq| AND a.$form->{vc}_id = $form->{"$form->{vc}_id"}|; } else { -- cgit v1.2.3