fix: error in report when data is not available to load chart in report (#36842)

This commit is contained in:
ViralKansodiya 2023-08-28 18:14:52 +05:30 committed by GitHub
parent eb5c61be1e
commit 3a2933db4d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -156,6 +156,8 @@ def get_data(filters):
def prepare_chart_data(data, filters):
if not data:
return
labels_values_map = {}
if filters.filter_based_on not in ("Date Range", "Fiscal Year"):
filters_filter_based_on = "Date Range"