revert: restrict app in apps page if no access to FCRM module
This commit is contained in:
parent
2b395a05ea
commit
0bd448a399
@ -63,10 +63,10 @@ def check_app_permission():
|
|||||||
if frappe.session.user == "Administrator":
|
if frappe.session.user == "Administrator":
|
||||||
return True
|
return True
|
||||||
|
|
||||||
allowed_modules = frappe.utils.modules.get_modules_from_all_apps_for_user()
|
# allowed_modules = frappe.utils.modules.get_modules_from_all_apps_for_user()
|
||||||
allowed_modules = [x["module_name"] for x in allowed_modules]
|
# allowed_modules = [x["module_name"] for x in allowed_modules]
|
||||||
if "FCRM" not in allowed_modules:
|
# if "FCRM" not in allowed_modules:
|
||||||
return False
|
# return False
|
||||||
|
|
||||||
roles = frappe.get_roles()
|
roles = frappe.get_roles()
|
||||||
if any(
|
if any(
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user