summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoreinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2007-07-27 17:01:13 +0000
committereinhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>2007-07-27 17:01:13 +0000
commitae5befb9467acb2de59691a26856b11574abeae0 (patch)
tree3031a1602038d5bca276e36f9acba50dbf1b7cb1
parentd9408a1947a99f2d6f60623374776ad30e36cf8b (diff)
Fixing a large number of SQL errors in certain circumstances
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@1449 4979c152-3d1c-0410-bac9-87ea11338e46
-rw-r--r--LedgerSMB/OE.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/LedgerSMB/OE.pm b/LedgerSMB/OE.pm
index 3288fe94..2ba55866 100644
--- a/LedgerSMB/OE.pm
+++ b/LedgerSMB/OE.pm
@@ -2105,7 +2105,7 @@ sub transfer {
my $query = qq|
INSERT INTO inventory
(warehouse_id, parts_id, qty, shippingdate, employee_id)
- VALUES (?, ?, ?, '$shippingdate', $form->{employee_id})|;
+ VALUES (?, ?, ?, ?, ?)|;
$sth = $dbh->prepare($query) || $form->dberror($query);
my $qty;
@@ -2128,7 +2128,8 @@ sub transfer {
# from warehouse
if ( $form->{"warehouse_id_$i"} ) {
$sth->execute( $form->{"warehouse_id_$i"},
- $form->{"id_$i"}, $qty * -1 )
+ $form->{"id_$i"}, $qty * -1, $shippingdate,
+ $form->{employee_id})
|| $form->dberror;
$sth->finish;
}