fix: dont make dashboards if company is not set (#18975)

* fix: dont make dashboardss if company is not set

* fix: function call

* Update dashboard_charts.py
This commit is contained in:
Shivam Mishra
2019-09-10 14:08:31 +05:30
committed by Nabin Hait
parent 88e8688a4b
commit e851346b4c
2 changed files with 17 additions and 2 deletions

View File

@@ -501,6 +501,11 @@ def install_defaults(args=None):
make_records(records)
def add_dashboards():
from erpnext.setup.setup_wizard.data.dashboard_charts import get_company_for_dashboards
if not get_company_for_dashboards():
return
from erpnext.setup.setup_wizard.data.dashboard_charts import get_default_dashboards
from frappe.modules.import_file import import_file_by_path