diff options
Diffstat (limited to 'app/links/views.py')
-rw-r--r-- | app/links/views.py | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/app/links/views.py b/app/links/views.py index 4beff5d..e95cff4 100644 --- a/app/links/views.py +++ b/app/links/views.py @@ -20,21 +20,17 @@ class LinkTagListView(PaginatedListView): model = Link def get_queryset(self): - print(self.kwargs['slug']) - return Link.objects.filter(tags__slug=self.kwargs['slug']) + return Link.objects.filter(tags__name__in=[self.kwargs['slug']]) def get_context_data(self, **kwargs): # Call the base implementation first to get a context context = super(LinkTagListView, self).get_context_data(**kwargs) context['tag'] = Tag.objects.get(slug__exact=self.kwargs['slug']) context['tags'] = Link.tags.all() + context['breadcrumbs'] = ('Links',) return context class LinkDetailView(DetailView): model = Link slug_field = "id" - - -class LinkDetailViewTXT(LinkDetailView): - template_name = "details/entry.txt" |