comparison ygroup/urls.py @ 1080:db8f5b3204b7

Fix Yahoo Group post view for V3 design.
author Brian Neal <bgneal@gmail.com>
date Sat, 23 Apr 2016 00:06:32 -0500
parents 5d208c3321ce
children
comparison
equal deleted inserted replaced
1079:75189bd9c4ba 1080:db8f5b3204b7
1 """ 1 """
2 urls.py - URLs for the ygroup application. 2 urls.py - URLs for the ygroup application.
3 3
4 """ 4 """
5 from django.conf.urls import url 5 from django.conf.urls import url
6 from django.views.generic import DetailView
7 6
8 from ygroup.models import Post 7 from ygroup.views import ThreadIndexView, ThreadView, PostView
9 from ygroup.views import ThreadIndexView, ThreadView
10 8
11 9
12 urlpatterns = [ 10 urlpatterns = [
13 url(r'^threads/$', 11 url(r'^threads/$',
14 ThreadIndexView.as_view(), 12 ThreadIndexView.as_view(),
15 name='ygroup-thread_index'), 13 name='ygroup-thread_index'),
16 url(r'^thread/(\d+)/$', 14 url(r'^thread/(\d+)/$',
17 ThreadView.as_view(), 15 ThreadView.as_view(),
18 name='ygroup-thread_view'), 16 name='ygroup-thread_view'),
19 url(r'^post/(?P<pk>\d+)/$', 17 url(r'^post/(?P<pk>\d+)/$',
20 DetailView.as_view(model=Post, context_object_name='post', 18 PostView.as_view(),
21 template_name='ygroup/v3/post.html'),
22 name='ygroup-post_view'), 19 name='ygroup-post_view'),
23 ] 20 ]