From 9a9974f5c3875f0b70e66169a7f2a98fc7f70418 Mon Sep 17 00:00:00 2001 From: Rohit Waghchaure Date: Tue, 7 Aug 2018 16:51:56 +0530 Subject: [PATCH] [Fix] 'ascii' codec can't encode error in balance sheet report --- erpnext/accounts/report/financial_statements.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/accounts/report/financial_statements.py b/erpnext/accounts/report/financial_statements.py index 46417b8dd1..1ede508ef2 100644 --- a/erpnext/accounts/report/financial_statements.py +++ b/erpnext/accounts/report/financial_statements.py @@ -217,7 +217,7 @@ def prepare_data(accounts, balance_must_be, period_list, company_currency): "year_end_date": year_end_date, "currency": company_currency, "opening_balance": d.get("opening_balance", 0.0) * (1 if balance_must_be=="Debit" else -1), - "account_name": ('{} - {}'.format(_(d.account_number), _(d.account_name)) + "account_name": ('%s - %s' %(_(d.account_number), _(d.account_name)) if d.account_number else _(d.account_name)) }) for period in period_list: