From 7c9f2c7debe6103fb6ce742f29120c0ef751094e Mon Sep 17 00:00:00 2001 From: rohitwaghchaure Date: Mon, 3 Jul 2017 12:29:49 +0530 Subject: [PATCH] [enahnce] Fetch doctype's roles in report if developer mode is on or is standard is no (#3591) * [enahnce] Fetch doctype's role in report if developer mode is on or is standard is no * Update report.py lets not keep separate rules for developer_mode! - this is not discoverable by a new developer --- frappe/core/doctype/report/report.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frappe/core/doctype/report/report.py b/frappe/core/doctype/report/report.py index 6151890183..7c18d5fd27 100644 --- a/frappe/core/doctype/report/report.py +++ b/frappe/core/doctype/report/report.py @@ -49,7 +49,7 @@ class Report(Document): delete_custom_role('report', self.name) def set_doctype_roles(self): - if not self.get('roles'): + if not self.get('roles') and self.is_standard == 'No': meta = frappe.get_meta(self.ref_doctype) roles = [{'role': d.role} for d in meta.permissions if d.permlevel==0] self.set('roles', roles)