Browsing and showing comment documents
[edumed.git] / comment / views.py
1 from django.views.generic import ListView, DetailView
2 from django.conf import settings
3
4 from .models import CommentDocument
5
6
7 class CommentDocumentList(ListView):
8     model = CommentDocument
9
10
11 class CommentDocument(DetailView):
12     model = CommentDocument
13
14     def get_context_data(self, **kwargs):
15         context = super(CommentDocument, self).get_context_data(**kwargs)
16         context['comment_url'] = settings.COMMENT_URL
17         return context