From: Joe Hunt Date: Sun, 30 Jul 2017 11:15:04 +0000 (+0200) Subject: 0003954: RB not correct in Customer Transactions Inquiry. Removed RB from customer... X-Git-Tag: v2.4.2~2 X-Git-Url: https://delta.frontaccounting.com/gitweb/?p=fa-stable.git;a=commitdiff_plain;h=09f11ae8dda656ddc48b3d6916f34b93033d9136 0003954: RB not correct in Customer Transactions Inquiry. Removed RB from customer transactions. --- diff --git a/sales/includes/db/cust_trans_db.inc b/sales/includes/db/cust_trans_db.inc index 5cba6490..52fce9e2 100644 --- a/sales/includes/db/cust_trans_db.inc +++ b/sales/includes/db/cust_trans_db.inc @@ -320,8 +320,8 @@ function get_sql_for_customer_inquiry($from, $to, $cust_id = ALL_TEXT, $filter = debtor.debtor_no, IF(prep_amount, prep_amount, trans.ov_amount + trans.ov_gst + trans.ov_freight + trans.ov_freight_tax + trans.ov_discount) AS TotalAmount, "; - if ($filter != ALL_TEXT) - $sql .= "@bal := @bal+IF(prep_amount, prep_amount, trans.ov_amount + trans.ov_gst + trans.ov_freight + trans.ov_freight_tax + trans.ov_discount), "; +// if ($filter != ALL_TEXT) +// $sql .= "@bal := @bal+IF(prep_amount, prep_amount, trans.ov_amount + trans.ov_gst + trans.ov_freight + trans.ov_freight_tax + trans.ov_discount), "; // else // $sql .= "IF(trans.type=".ST_CUSTDELIVERY.",'', IF(trans.type=".ST_SALESINVOICE." OR trans.type=".ST_BANKPAYMENT.",@bal := @bal+ diff --git a/sales/inquiry/customer_inquiry.php b/sales/inquiry/customer_inquiry.php index 7a1cc62b..d6851aa0 100644 --- a/sales/inquiry/customer_inquiry.php +++ b/sales/inquiry/customer_inquiry.php @@ -186,7 +186,7 @@ $sql = get_sql_for_customer_inquiry(get_post('TransAfterDate'), get_post('TransT get_post('customer_id'), get_post('filterType')); //------------------------------------------------------------------------------------------------ -db_query("set @bal:=0"); +//db_query("set @bal:=0"); $cols = array( _("Type") => array('fun'=>'systype_name', 'ord'=>''), @@ -199,7 +199,7 @@ $cols = array( _("Branch") => array('ord'=>''), _("Currency") => array('align'=>'center'), _("Amount") => array('align'=>'right', 'fun'=>'fmt_amount'), - _("RB") => array('align'=>'right', 'type'=>'amount'), +// _("RB") => array('align'=>'right', 'type'=>'amount'), array('insert'=>true, 'fun'=>'gl_view'), array('insert'=>true, 'fun'=>'credit_link'), array('insert'=>true, 'fun'=>'edit_link'),