2019-01-30 11:48:39 +05:30
|
|
|
import frappe
|
|
|
|
|
2021-09-02 16:44:59 +05:30
|
|
|
|
2019-01-30 11:48:39 +05:30
|
|
|
def execute():
|
2022-03-28 18:52:46 +05:30
|
|
|
if "Education" in frappe.get_active_domains() and not frappe.db.exists("Role", "Guardian"):
|
2019-01-30 17:45:48 +05:30
|
|
|
doc = frappe.new_doc("Role")
|
2022-03-28 18:52:46 +05:30
|
|
|
doc.update({"role_name": "Guardian", "desk_access": 0})
|
2019-01-30 17:45:48 +05:30
|
|
|
|
|
|
|
doc.insert(ignore_permissions=True)
|