From: Joe Hunt Date: Sun, 2 May 2021 21:37:48 +0000 (+0200) Subject: bug 5429: balance sheet report sometimes prints lines with zero amounts. Fixed. X-Git-Url: https://delta.frontaccounting.com/gitweb/?p=fa-stable.git;a=commitdiff_plain;h=e72f0b009f8e0bbfe4b42aba11aded7f0d2b8c41 bug 5429: balance sheet report sometimes prints lines with zero amounts. Fixed. --- diff --git a/gl/includes/db/gl_db_trans.inc b/gl/includes/db/gl_db_trans.inc index eed94384..ebea4c1d 100644 --- a/gl/includes/db/gl_db_trans.inc +++ b/gl/includes/db/gl_db_trans.inc @@ -289,7 +289,7 @@ function get_gl_balance_from_to($from_date, $to_date, $account, $dimension=0, $d $result = db_query($sql, "The starting balance for account $account could not be calculated"); $row = db_fetch_row($result); - return $row[0]; + return round2($row[0], user_price_dec()); } //-------------------------------------------------------------------------------- @@ -313,7 +313,7 @@ function get_gl_trans_from_to($from_date, $to_date, $account, $dimension=0, $dim $result = db_query($sql, "Transactions for account $account could not be calculated"); $row = db_fetch_row($result); - return (float)$row[0]; + return round2($row[0], user_price_dec()); } //----------------------------------------------------------------------------------------------------