diff options
Diffstat (limited to 'app/posts/views/photo_essay_views.py')
-rw-r--r-- | app/posts/views/photo_essay_views.py | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/app/posts/views/photo_essay_views.py b/app/posts/views/photo_essay_views.py index 4f08910..8c35621 100644 --- a/app/posts/views/photo_essay_views.py +++ b/app/posts/views/photo_essay_views.py @@ -14,13 +14,11 @@ from taxonomy.models import Category class PhotoEssayListView(PaginatedListView): model = Post # TODO: change this when I have an actual archive to show - template_name = "photo_essay_detail.html" + template_name = "photo_essay_list.html" def get_queryset(self): queryset = super(PhotoEssayListView, self).get_queryset() - return queryset.get(slug="dawn") - # real queryset - #return queryset.filter(site__domain='luxagraf.net').filter(post_type__in=[PostType.PHOTO_ESSAY]).filter(status__exact=1).order_by('-pub_date').prefetch_related('location').prefetch_related('featured_image') + return queryset.filter(site__domain='luxagraf.net').filter(post_type__in=[PostType.PHOTO_ESSAY]).filter(status__exact=1).order_by('-pub_date').prefetch_related('location').prefetch_related('featured_image') def get_context_data(self, **kwargs): ''' @@ -48,10 +46,10 @@ class PhotoEssayDetailView(LuxDetailView): related.append(model.objects.get(slug=obj.slug, pub_date=obj.pub_date)) context['related'] = related context['breadcrumbs'] = ('Photos',) - context['crumb_url'] = reverse('posts:photo-essay-list') + context['crumb_url'] = reverse('photo_essay:list') return context def get_template_names(self): obj = self.get_object() - return ["film_detail.html"] + return ["photo_essay_detail.html"] |