From 78736c910db22542e9896a542f9ed889f8bde99c Mon Sep 17 00:00:00 2001
From: "olt@tinyerp.com" <>
Date: Fri, 1 Oct 2010 13:58:16 +0200
Subject: [PATCH] [IMP] account: 'account_general_ledger' report now uses
decimal_precicion
bzr revid: olt@tinyerp.com-20101001115816-ez0lzvu9ywo3858q
---
.../account/report/account_general_ledger.py | 2 +-
.../account_general_ledger_landscape.rml | 26 +++++++++----------
2 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/addons/account/report/account_general_ledger.py b/addons/account/report/account_general_ledger.py
index d8ab573b083..2d31a97049b 100644
--- a/addons/account/report/account_general_ledger.py
+++ b/addons/account/report/account_general_ledger.py
@@ -97,7 +97,7 @@ class general_ledger(rml_parse.rml_parse, common_report_header):
FROM account_move_line l \
WHERE l.account_id = %s AND %s '%(account.id, self.init_query))
sum_currency += self.cr.fetchone()[0] or 0.0
- return str(sum_currency)
+ return sum_currency
def get_children_accounts(self, account):
res = []
diff --git a/addons/account/report/account_general_ledger_landscape.rml b/addons/account/report/account_general_ledger_landscape.rml
index 163d5cb5f2c..1321bdea750 100644
--- a/addons/account/report/account_general_ledger_landscape.rml
+++ b/addons/account/report/account_general_ledger_landscape.rml
@@ -266,10 +266,10 @@
| [[ '..'*(o.level-1) ]][[ o.code ]] [[ o.name ]] |
|
- [[formatLang(sum_debit_account(o)) ]] |
- [[formatLang(sum_credit_account(o)) ]] |
- [[formatLang(sum_balance_account(o)) ]] [[ company.currency_id.symbol ]] |
- [[ o.currency_id and sum_currency_amount_account(o) +o.currency_id.code or '' ]] |
+ [[ formatLang(sum_debit_account(o), digits=get_digits(dp='Account')) ]] |
+ [[ formatLang(sum_credit_account(o), digits=get_digits(dp='Account')) ]] |
+ [[ formatLang(sum_balance_account(o), digits=get_digits(dp='Account')) ]] [[ company.currency_id.symbol ]] |
+ [[ o.currency_id and formatLang(sum_currency_amount_account(o), digits=get_digits(dp='Account')) + o.currency_id.code or '' ]] |
@@ -292,9 +292,9 @@
[[ line['move'] ]] |
[[ line['lname'] ]] |
[[ strip_name(line['line_corresp'].replace(', ',','),40) ]] |
- [[ formatLang(line['debit']) ]] |
- [[ formatLang(line['credit']) ]] |
- [[ formatLang(line['progress']) ]] [[ company.currency_id.symbol ]] |
+ [[ formatLang(line['debit'], digits=get_digits(dp='Account')) ]] |
+ [[ formatLang(line['credit'], digits=get_digits(dp='Account')) ]] |
+ [[ formatLang(line['progress'], digits=get_digits(dp='Account')) ]] [[ company.currency_id.symbol ]] |
[[ formatLang(line['amount_currency'] or '')]] [[ line['currency_code'] or '' ]] |
@@ -327,9 +327,9 @@
| [[ '..'*(o.level-1) ]][[ o.code ]] [[ o.name ]] |
|
- [[formatLang(sum_debit_account(o)) ]] |
- [[formatLang(sum_credit_account(o)) ]] |
- [[formatLang(sum_balance_account(o)) ]] [[ company.currency_id.symbol ]] |
+ [[ formatLang(sum_debit_account(o), digits=get_digits(dp='Account')) ]] |
+ [[ formatLang(sum_credit_account(o), digits=get_digits(dp=Account)) ]] |
+ [[ formatLang(sum_balance_account(o), digits=get_digits(dp='Account')) ]] [[ company.currency_id.symbol ]] |
@@ -352,9 +352,9 @@
[[ line['move'] ]] |
[[ line['lname'] ]] |
[[ strip_name(line['line_corresp'],15) ]] |
- [[ formatLang(line['debit']) ]] |
- [[ formatLang(line['credit']) ]] |
- [[ formatLang(line['progress']) ]] [[ company.currency_id.symbol ]] |
+ [[ formatLang(line['debit'], dp='Account') ]] |
+ [[ formatLang(line['credit'], dp='Account') ]] |
+ [[ formatLang(line['progress'], dp='Account') ]] [[ company.currency_id.symbol ]] |