diff --git a/erpnext/accounts/report/financial_statements.py b/erpnext/accounts/report/financial_statements.py index 629d306f76b..22c72c0b614 100644 --- a/erpnext/accounts/report/financial_statements.py +++ b/erpnext/accounts/report/financial_statements.py @@ -129,7 +129,7 @@ def get_data( accounts, accounts_by_name, parent_children_map = filter_accounts(accounts) - company_currency = frappe.db.get_value("Company", company, "default_currency") + company_currency = get_appropriate_currency(filters, company) gl_entries_by_account = {} for root in frappe.db.sql("""select lft, rgt from tabAccount @@ -155,6 +155,13 @@ def get_data( return out +def get_appropriate_currency(filters, company): + if filters.get("presentation_currency"): + return filters["presentation_currency"] + else: + return frappe.db.get_value("Company", company, "default_currency") + + def calculate_values( accounts_by_name, gl_entries_by_account, period_list, accumulated_values, ignore_accumulated_values_for_fy): for entries in gl_entries_by_account.values():