X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=reporting%2Frep302.php;h=8e5bb6ddfd2e39e0898149e167842b5d82295df1;hb=8ea6c4dd0d9b31b3456d012b0c94339b801bee0c;hp=611e214b0aa98da3779a6c4c5aa405504ba8ecf7;hpb=80dd97a37f674cc3691fa04af4c29607067566b2;p=fa-stable.git diff --git a/reporting/rep302.php b/reporting/rep302.php index 611e214b..8e5bb6dd 100644 --- a/reporting/rep302.php +++ b/reporting/rep302.php @@ -44,9 +44,9 @@ function getTransactions($category, $location) WHERE ".TB_PREF."stock_master.category_id=".TB_PREF."stock_category.category_id AND (".TB_PREF."stock_master.mb_flag='B' OR ".TB_PREF."stock_master.mb_flag='M')"; if ($category != 0) - $sql .= " AND ".TB_PREF."stock_master.category_id = '$category'"; + $sql .= " AND ".TB_PREF."stock_master.category_id = ".db_escape($category); if ($location != 'all') - $sql .= " AND IF(".TB_PREF."stock_moves.stock_id IS NULL, '1=1',".TB_PREF."stock_moves.loc_code = '$location')"; + $sql .= " AND IF(".TB_PREF."stock_moves.stock_id IS NULL, '1=1',".TB_PREF."stock_moves.loc_code = ".db_escape($location).")"; $sql .= " GROUP BY ".TB_PREF."stock_master.category_id, ".TB_PREF."stock_category.description, ".TB_PREF."stock_master.stock_id,