Пример #1
0
def get_breadcrumb(s, n=0):
    depth = section.get_depth(s['path'])
    return [[s, get_breadcrumb(section.get(s['parent_path'])) if depth > n else []]]
Пример #2
0
def get_breadcrumb(s, n=0):
    depth = section.get_depth(s['path'])
    return [[s, get_breadcrumb(section.get(s['parent_path'])) if depth > n else []]]
Пример #3
0
 def view_breadcrumb(self, params=None):
     n = int(params[0]) if params else 0
     hierarchy = get_breadcrumb(section.get(self.section.path), n)
     self.section.css.append('nav-breadcrumb.css')
     return list_ul(self.section.path, hierarchy, 'breadcrumb')
Пример #4
0
 def view_breadcrumb(self, params=None):
     n = int(params[0]) if params else 0
     hierarchy = get_breadcrumb(section.get(self.section.path), n)
     self.section.css.append('nav-breadcrumb.css')
     return list_ul(self.section.path, hierarchy, 'breadcrumb')