Wrong presentation in customer/supplier balance if using bank payments for customers and bank deposits for suppliers (very rare)
! -> Note
$ -> Affected files
+18-Jul-2009 Joe Hunt
+# When saving a Payment to a Customer in Bank Payments (normally payment to suppliers) it was saved with wrong sign in debtor_trans (very rare).
+$ /sales/includes/db/cust_trans_db.inc
+# Wrong presentation in customer/supplier balance if using bank payments for customers and bank deposits for suppliers (very rare)
+$ /reporting/rep101.php
+ /reporting/rep201.php
+
13-Jul-2009 Joe Hunt
# Bug in Tax Inquiry and Tax Report when entering in Journal Entry
$ /gl/includes/db/gl_db_banking.inc
else
$item[3] = ($trans['TotalAmount'] + $trans['Allocated']) * $rate;
*/
- if ($trans['type'] == 10)
+ if ($trans['type'] == 10 || $trans['type'] == 1)
$item[3] = $item[0] + $item[1] - $item[2];
else
$item[3] = $item[0] - $item[1] + $item[2];
else
$item[3] = ($trans['TotalAmount'] + $trans['Allocated']) * $rate;
*/
- if ($trans['type'] == 20)
+ if ($trans['type'] == 20 || $trans['type'] == 2)
$item[3] = $item[0] + $item[1] - $item[2];
else
$item[3] = $item[0] - $item[1] + $item[2];
$SQLDueDate = "000-00-00";
else
$SQLDueDate = date2sql($due_date);
-
+
+ if ($trans_type == systypes::bank_payment())
+ $Total = -$Total;
if ($trans_no==0) {
$trans_no = get_next_trans_no($trans_type);