X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=reporting%2Frep301.php;h=4ef14f1ca9d4210d6f0129cfff93bb4b1b34db18;hb=495ac5fbc5f98dde51645d1691e13dc37654f771;hp=ac6694923a02d2348866085aea3dfd2ab15cd738;hpb=d8c20899e75cfa22aec62b1ad1c46a74c0bb5edc;p=fa-stable.git diff --git a/reporting/rep301.php b/reporting/rep301.php index ac669492..4ef14f1c 100644 --- a/reporting/rep301.php +++ b/reporting/rep301.php @@ -62,7 +62,7 @@ function getAverageCost($stock_id, $location, $to_date) LEFT JOIN ".TB_PREF."debtor_trans cust_trans ON cust_trans.trans_no=move.trans_no AND cust_trans.type=move.type LEFT JOIN ".TB_PREF."debtors_master debtor ON cust_trans.debtor_no=debtor.debtor_no WHERE stock_id=".db_escape($stock_id)." - AND move.tran_date < '$to_date' AND standard_cost > 0.001 AND qty <> 0 AND move.type <> ".ST_LOCTRANSFER; + AND move.tran_date <= '$to_date' AND standard_cost > 0.001 AND qty <> 0 AND move.type <> ".ST_LOCTRANSFER; if ($location != 'all') $sql .= " AND move.loc_code = ".db_escape($location);