X-Git-Url: https://git.mdrn.pl/edumed.git/blobdiff_plain/0b7c6a7b88888fe948faa33edc988ba10d62b7c5..0029595caa78abc831724d22b4c1b45b9867cec0:/catalogue/templatetags/catalogue_tags.py diff --git a/catalogue/templatetags/catalogue_tags.py b/catalogue/templatetags/catalogue_tags.py index 4485e18..a8d69e6 100755 --- a/catalogue/templatetags/catalogue_tags.py +++ b/catalogue/templatetags/catalogue_tags.py @@ -49,14 +49,15 @@ def section_box(section): @register.inclusion_tag("catalogue/snippets/lesson_nav.html") def lesson_nav(lesson): - if lesson.type in ('course', 'project'): + if lesson.type == 'course': root = lesson.section siblings = Lesson.objects.filter(type='course', level=lesson.level, section=root) mark_level = False + link_other_level = True else: root = None siblings = Lesson.objects.filter(type=lesson.type) - mark_level = True + mark_level = link_other_level = lesson.type == 'course' return { "lesson": lesson, "root": root,