fix: key error on p/l and balance sheet reports on foreign currency

This commit is contained in:
ruthra kumar 2022-12-06 13:44:54 +05:30
parent 19db7e2989
commit a6794c3606

View File

@ -28,7 +28,7 @@ def get_currency(filters):
filters["presentation_currency"] if filters.get("presentation_currency") else company_currency
)
report_date = filters.get("period_end_date")
report_date = filters.get("to_date") or filters.get("period_end_date")
if not report_date:
fiscal_year_to_date = get_from_and_to_date(filters.get("to_fiscal_year"))["to_date"]