diff options
Diffstat (limited to 'app/resume/views.py')
-rw-r--r-- | app/resume/views.py | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/app/resume/views.py b/app/resume/views.py new file mode 100644 index 0000000..bdfd01b --- /dev/null +++ b/app/resume/views.py @@ -0,0 +1,31 @@ +from django.views.generic.detail import DetailView +from django.views.generic.base import TemplateView +from utils.views import PaginatedListView + +from .models import PubItem +from pages.models import Page + + +class PublisherListView(PaginatedListView): + template_name = 'archives/resume-pubs.html' + + def get_queryset(self): + return PubItem.objects.all() + + +class PubItemDetailView(DetailView): + model = PubItem + template_name = "details/resume.html" + slug_field = "slug" + + +class PageView(DetailView): + model = Page + slug_field = "slug" + + def get_template_names(self): + return ["details/%s.html" % self.object.slug, 'details/page.html'] + + +class BaseView(TemplateView): + template_name = "archives/resume.html" |