fix for tag page
This commit is contained in:
@@ -33,7 +33,12 @@ def index(request):
|
||||
|
||||
def tags(request, tag=""):
|
||||
posts = deque(Post.objects.filter(tags__name=tag))
|
||||
return render(request, 'posts/index.html', {"posts": posts, "tags_list": None})
|
||||
featured_post = Post.objects.filter(slug=tag).first()
|
||||
context= {
|
||||
"posts": posts,
|
||||
"featured_post":featured_post,
|
||||
"tags_list": None}
|
||||
return render(request, 'posts/tag.html',context)
|
||||
|
||||
|
||||
def show(request, id=None):
|
||||
|
||||
Reference in New Issue
Block a user