-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
in upy.contrib.tree.tpl.* the node.level to calculate if applying before or after parameters counts always starting from the root, and not the relative-depth of the menu tree.
Ex:
root
|--- menu
|-------- submenu
|-------------- node
this:
menu_node = Node.objects.get(name="menu")
menu = Menu(request, menu_node, upy_context, menu_depth=3)
vars_dict['menu'] = menu.as_ul(before_1="<div>", after_1="</div>",)whil apply the 'before' tags correctly on submenu,
but this:
menu_node = Node.objects.get(name="submenu")
menu = Menu(request, menu_node, upy_context, menu_depth=3)
vars_dict['menu'] = menu.as_ul(before_1="<div>", after_1="</div>",)will not apply any 'before', because it counts always node.level <= 2