fmartingr
/
shelfzilla
Archived
1
0
Fork 0
This repository has been archived on 2021-06-29. You can view files and clone it, but cannot push or open issues or pull requests.
shelfzilla/shelfzilla/apps/faq/views.py

27 lines
670 B
Python

# coding: utf-8
# django
from django.views.generic import View
from django.template import RequestContext
from django.shortcuts import render_to_response
from django.db.models import Count
from django.contrib.auth import get_user_model
# shelfzilla.faq
from .models import QuestionAnswerCategory
class FaqListView(View):
template = 'faq/list.html'
def get(self, request):
data = {
'categories': QuestionAnswerCategory.objects.all(),
'navigation': {
'section': 'faqs',
},
}
ctx = RequestContext(request, data)
return render_to_response(self.template, context_instance=ctx)