fix(report): prevent standard report creation when developer mode is off
This commit is contained in:
parent
54145369f4
commit
15966a78a6
1 changed files with 3 additions and 0 deletions
|
|
@ -77,6 +77,9 @@ class Report(Document):
|
|||
if frappe.session.user != "Administrator":
|
||||
frappe.throw(_("Only Administrator can save a standard report. Please rename and save."))
|
||||
|
||||
if not cint(getattr(frappe.local.conf, "developer_mode", 0)):
|
||||
frappe.throw(_("Standard reports can only be created in developer mode."))
|
||||
|
||||
if self.report_type == "Report Builder":
|
||||
self.update_report_json()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue