Merge branch 'version-12-hotfix' into release-notes-fixes
This commit is contained in:
commit
6bd50b1e20
@ -69,8 +69,7 @@ class ItemGroup(NestedSet, WebsiteGenerator):
|
|||||||
"items": get_product_list_for_group(product_group = self.name, start=start,
|
"items": get_product_list_for_group(product_group = self.name, start=start,
|
||||||
limit=context.page_length + 1, search=frappe.form_dict.get("search")),
|
limit=context.page_length + 1, search=frappe.form_dict.get("search")),
|
||||||
"parents": get_parent_item_groups(self.parent_item_group),
|
"parents": get_parent_item_groups(self.parent_item_group),
|
||||||
"title": self.name,
|
"title": self.name
|
||||||
"products_as_list": cint(frappe.db.get_single_value('Products Settings', 'products_as_list'))
|
|
||||||
})
|
})
|
||||||
|
|
||||||
if self.slideshow:
|
if self.slideshow:
|
||||||
|
@ -22,6 +22,7 @@ def after_install():
|
|||||||
add_all_roles_to("Administrator")
|
add_all_roles_to("Administrator")
|
||||||
create_default_cash_flow_mapper_templates()
|
create_default_cash_flow_mapper_templates()
|
||||||
create_default_success_action()
|
create_default_success_action()
|
||||||
|
add_company_to_session_defaults()
|
||||||
frappe.db.commit()
|
frappe.db.commit()
|
||||||
|
|
||||||
|
|
||||||
@ -84,3 +85,10 @@ def create_default_success_action():
|
|||||||
if not frappe.db.exists('Success Action', success_action.get("ref_doctype")):
|
if not frappe.db.exists('Success Action', success_action.get("ref_doctype")):
|
||||||
doc = frappe.get_doc(success_action)
|
doc = frappe.get_doc(success_action)
|
||||||
doc.insert(ignore_permissions=True)
|
doc.insert(ignore_permissions=True)
|
||||||
|
|
||||||
|
def add_company_to_session_defaults():
|
||||||
|
settings = frappe.get_single("Session Default Settings")
|
||||||
|
settings.append("session_defaults", {
|
||||||
|
"ref_doctype": "Company"
|
||||||
|
})
|
||||||
|
settings.save()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user