Added sketches to the nav-bar on install

This commit is contained in:
Anand Chitipothu
2021-05-05 12:56:27 +05:30
parent e330f45adc
commit 041bed7e9d

View File

@@ -6,6 +6,7 @@ import frappe
def after_install():
set_app_name()
disable_signup()
add_header_items()
add_footer_items()
def set_app_name():
@@ -16,6 +17,16 @@ def set_app_name():
def disable_signup():
frappe.db.set_value("Website Settings", None, "disable_signup", 1)
def add_header_items():
items = [
{"label": "Sketches", "url": "/sketches"},
]
doc = frappe.get_doc("Website Settings", None)
doc.update({
"top_bar_items": items
})
doc.save()
def add_footer_items():
items = [
{"label": "About", "url": "/about"},