From 6e5897117124cd60ae81efb1574c6347f48e60e5 Mon Sep 17 00:00:00 2001 From: luxagraf Date: Tue, 4 Jul 2023 11:13:11 -0500 Subject: fixed a bug with breadcrumb urls and src section --- app/posts/templates/posts/film_detail.html | 12 +----------- app/utils/views.py | 3 ++- 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/app/posts/templates/posts/film_detail.html b/app/posts/templates/posts/film_detail.html index d0108e9..5e44d7d 100644 --- a/app/posts/templates/posts/film_detail.html +++ b/app/posts/templates/posts/film_detail.html @@ -20,17 +20,7 @@ {%endblock%} {%block bodyid%}id="home" class="friends"{%endblock%} -{% block breadcrumbs %} -{% endblock %} +{% block breadcrumbs %}{% include "lib/breadcrumbs.html" with breadcrumbs=breadcrumbs %}{% endblock %} {% block primary %}
diff --git a/app/utils/views.py b/app/utils/views.py index 5b1e4fd..19ada6f 100644 --- a/app/utils/views.py +++ b/app/utils/views.py @@ -60,9 +60,10 @@ class LuxDetailView(DetailView): if self.object._meta.verbose_name_plural == 'posts': if self.object.get_post_type_display() != 'src': context['breadcrumbs'] = (self.object.get_post_type_display()+"s",) + context['crumb_url'] = "/%ss/" % slugify(self.object.get_post_type_display()) else: context['breadcrumbs'] = (self.object.get_post_type_display(),) - context['crumb_url'] = "/%ss/" % slugify(self.object.get_post_type_display()) + context['crumb_url'] = "/%s/" % slugify(self.object.get_post_type_display()) else: context['breadcrumbs'] = (self.object._meta.verbose_name_plural,) try: -- cgit v1.2.3-70-g09d2