Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class ArticleListView(generic.ListView):
- model = Article
- template_name = 'blog/article_list.html'
- context_object_name = 'articles'
- queryset = Article.objects.all()
- def get_context_data(self, *, object_list=None, **kwargs):
- context = super().get_context_data()
- context['one'] = "blog:article-create"
- return context
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement