[hotfix] item group set_parent_website_route

This commit is contained in:
Anand Doshi 2015-04-16 20:45:54 -04:00
parent 2182cd5487
commit 63ea99e929

View File

@ -41,9 +41,8 @@ class ItemGroup(NestedSet, WebsiteGenerator):
Only set `parent_website_route` if parent is visble.
e.g. If `show_in_website` is set for Products then url should be `/products`"""
if self.parent_item_group and frappe.db.get_value("Item Group",
self.parent_item_group, "show_in_website"):
super(WebsiteGenerator, self)()
if self.parent_item_group and frappe.db.get_value("Item Group", self.parent_item_group, "show_in_website"):
WebsiteGenerator.set_parent_website_route(self)
else:
self.parent_website_route = ""