diff --git a/addons/account/account.py b/addons/account/account.py index 0f8c9575931..0c1f9f0f73c 100644 --- a/addons/account/account.py +++ b/addons/account/account.py @@ -312,7 +312,7 @@ class account_account(osv.osv): def _get_company_currency(self, cr, uid, ids, field_name, arg, context={}): result = {} for rec in self.browse(cr, uid, ids, context): - result[rec.id] = (rec.company_id.currency_id.id,rec.company_id.currency_id.code) + result[rec.id] = (rec.company_id.currency_id.id,rec.company_id.currency_id.symbol) return result def _get_child_ids(self, cr, uid, ids, field_name, arg, context={}): diff --git a/addons/account/account_unit_test.xml b/addons/account/account_unit_test.xml index e4178517361..c810e6a1080 100644 --- a/addons/account/account_unit_test.xml +++ b/addons/account/account_unit_test.xml @@ -1,7 +1,7 @@ - + @@ -19,8 +19,8 @@ 5.00 100.00 - - + + Basic computer with Dvorak keyboard and left-handed mouse @@ -34,19 +34,19 @@ 800 2 - - + + - EUR + - + - + - + open @@ -62,7 +62,7 @@ - + paid diff --git a/addons/account/invoice.py b/addons/account/invoice.py index e03e0035022..559b259057d 100644 --- a/addons/account/invoice.py +++ b/addons/account/invoice.py @@ -1232,7 +1232,7 @@ class account_invoice(osv.osv): if (not round(total,self.pool.get('decimal.precision').precision_get(cr, uid, 'Account'))) or writeoff_acc_id: self.pool.get('account.move.line').reconcile(cr, uid, line_ids, 'manual', writeoff_acc_id, writeoff_period_id, writeoff_journal_id, context) else: - code = invoice.currency_id.code + code = invoice.currency_id.symbol # TODO: use currency's formatting function msg = _("Invoice '%s' is paid partially: %s%s of %s%s (%s%s remaining)") % \ (name, pay_amount, code, invoice.amount_total, code, total, code) diff --git a/addons/account/report/account_general_ledger_landscape.rml b/addons/account/report/account_general_ledger_landscape.rml index a10f23f439a..a8404f5b2b3 100644 --- a/addons/account/report/account_general_ledger_landscape.rml +++ b/addons/account/report/account_general_ledger_landscape.rml @@ -301,7 +301,7 @@ [[ 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 '' ]] + [[ o.currency_id and formatLang(sum_currency_amount_account(o), digits=get_digits(dp='Account')) + o.currency_id.symbol or '' ]] diff --git a/addons/account/report/common_report_header.py b/addons/account/report/common_report_header.py index 35d0c1356ef..68c976cb4fe 100644 --- a/addons/account/report/common_report_header.py +++ b/addons/account/report/common_report_header.py @@ -136,7 +136,7 @@ class common_report_header(object): def _get_currency(self, data): if data.get('form', False) and data['form'].get('chart_account_id', False): - return pooler.get_pool(self.cr.dbname).get('account.account').browse(self.cr, self.uid, data['form']['chart_account_id']).company_id.currency_id.code - return '' + return pooler.get_pool(self.cr.dbname).get('account.account').browse(self.cr, self.uid, data['form']['chart_account_id']).company_id.currency_id.symbol + return '' #vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4: \ No newline at end of file