X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=purchasing%2Fincludes%2Fdb%2Fsupp_trans_db.inc;h=aa9490afc707e048723376ab87c05c1704a1fff1;hb=2f3375b4493c1b1e0b17c2801298275f22f8d76e;hp=8a2f85a9701b4acf2117bbf896abe80360f15dba;hpb=d30707a90159ed1f421ad064720306c4fb34bba0;p=fa-stable.git diff --git a/purchasing/includes/db/supp_trans_db.inc b/purchasing/includes/db/supp_trans_db.inc index 8a2f85a9..aa9490af 100644 --- a/purchasing/includes/db/supp_trans_db.inc +++ b/purchasing/includes/db/supp_trans_db.inc @@ -131,7 +131,7 @@ function get_supp_payment_before($supplier_id, $date) . TB_PREF . "bank_trans," . TB_PREF . "bank_accounts " . "WHERE " - . TB_PREF . "supp_trans.supplier_id=" . $supplier_id . " " + . TB_PREF . "supp_trans.supplier_id='" . $supplier_id . "' " . "AND " . TB_PREF . "supp_trans.tran_date<'" . $date . "' " . "AND " . TB_PREF . "supp_trans.type=" . ST_SUPPAYMENT . " " . "AND " . TB_PREF . "supp_trans.trans_no=" . TB_PREF . "bank_trans.trans_no "