16 admin.autodiscover() |
16 admin.autodiscover() |
17 |
17 |
18 # Blog & Admin |
18 # Blog & Admin |
19 urlpatterns = patterns( |
19 urlpatterns = patterns( |
20 '', |
20 '', |
21 url(r'^2009/$', direct_to_template, {"template": "home.html"}, name='home'), |
21 url(r'^$', direct_to_template, {"template": "home.html"}, name='home'), |
22 (r'^2009/feeds/(?P<url>.*)/$', 'django.contrib.syndication.views.feed', {'feed_dict': feeds}), |
22 (r'^feeds/(?P<url>.*)/$', 'django.contrib.syndication.views.feed', {'feed_dict': feeds}), |
23 (r'^2009/comments/', include('django.contrib.comments.urls')), |
23 (r'^comments/', include('django.contrib.comments.urls')), |
24 (r'^2009/admin/(.*)', admin.site.root), |
24 (r'^admin/(.*)', admin.site.root), |
25 ) |
25 ) |
26 |
26 |
27 # Talks, etc. |
27 # Talks, etc. |
28 urlpatterns += patterns('project.kiwipycon.talk.views', |
28 urlpatterns += patterns('project.kiwipycon.talk.views', |
29 url(r'^2009/talks/$', 'list_talks', name='list_talks'), |
29 url(r'^talks/$', 'list_talks', name='list_talks'), |
30 url(r'^2009/talks/talk/(?P<id>\d+)/$', 'talk', name='talk_detail'), |
30 url(r'^talks/talk/(?P<id>\d+)/$', 'talk', name='talk_detail'), |
31 url(r'^2009/submit-talk/$', 'submit_talk', name='kiwipycon_submit_talk'), |
31 url(r'^submit-talk/$', 'submit_talk', name='kiwipycon_submit_talk'), |
32 url(r'^2009/edit-talk/(?P<id>\d+)/$', 'edit_talk', name='kiwipycon_edit_talk'), |
32 url(r'^edit-talk/(?P<id>\d+)/$', 'edit_talk', name='kiwipycon_edit_talk'), |
33 url(r'^2009/talks-cfp/list-talks/(?P<id>\d+)/$', 'list_talks', |
33 url(r'^talks-cfp/list-talks/(?P<id>\d+)/$', 'list_talks', |
34 name='kiwipycon_list_talk'), |
34 name='kiwipycon_list_talk'), |
35 ) |
35 ) |
36 |
36 |
37 # Registration |
37 # Registration |
38 urlpatterns += patterns('project.kiwipycon.registration.views', |
38 urlpatterns += patterns('project.kiwipycon.registration.views', |
39 url(r'^2009/invoice/$', 'invoice', name='kiwipycon_invoice'), |
39 url(r'^invoice/$', 'invoice', name='kiwipycon_invoice'), |
40 url(r'^2009/pdf_invoice/$', 'pdf_invoice', name='kiwipycon_pdf_invoice'), |
40 url(r'^pdf_invoice/$', 'pdf_invoice', name='kiwipycon_pdf_invoice'), |
41 url(r'^2009/registrations/$', 'registrations', name='kiwipycon_registrations'), |
41 url(r'^registrations/$', 'registrations', name='kiwipycon_registrations'), |
42 url(r'^2009/submit-registration/$', 'submit_registration', name='kiwipycon_submit_registration'), |
42 url(r'^submit-registration/$', 'submit_registration', name='kiwipycon_submit_registration'), |
43 url(r'^2009/edit-registration/(?P<id>\d+)/$', 'edit_registration', |
43 url(r'^edit-registration/(?P<id>\d+)/$', 'edit_registration', |
44 name='kiwipycon_edit_registration'), |
44 name='kiwipycon_edit_registration'), |
45 url(r'^2009/download_csv/', 'download_csv', name="download_csv"), |
45 url(r'^download_csv/', 'download_csv', name="download_csv"), |
46 ) |
46 ) |
47 |
47 |
48 |
48 |
49 # Authentication and Profile |
49 # Authentication and Profile |
50 urlpatterns += patterns('project.kiwipycon.user.views', |
50 urlpatterns += patterns('project.kiwipycon.user.views', |
51 url(r'^2009/login/$', 'login', name='kiwipycon_login'), |
51 url(r'^login/$', 'login', name='kiwipycon_login'), |
52 url(r'^2009/logout/$', 'logout', name='kiwipycon_logout'), |
52 url(r'^logout/$', 'logout', name='kiwipycon_logout'), |
53 url(r'^2009/account/$', 'account', name='kiwipycon_account'), |
53 url(r'^account/$', 'account', name='kiwipycon_account'), |
54 url(r'^2009/password/$', 'password', name='kiwipycon_password'), # change pwd |
54 url(r'^password/$', 'password', name='kiwipycon_password'), # change pwd |
55 url(r'^2009/username/$', 'username', name='kiwipycon_username'), # change uname |
55 url(r'^username/$', 'username', name='kiwipycon_username'), # change uname |
56 url(r'^2009/edit-profile/$', 'edit_profile', name='kiwipycon_edit_profile'), |
56 url(r'^edit-profile/$', 'edit_profile', name='kiwipycon_edit_profile'), |
57 ) |
57 ) |
58 |
58 |
59 # Proceedings |
59 # Proceedings |
60 urlpatterns += patterns('project.kiwipycon.proceedings.views', |
60 urlpatterns += patterns('project.kiwipycon.proceedings.views', |
61 url(r'^2009/proceedings/submit/$', 'submit', name='kiwipycon_submit_proceedings'), |
61 url(r'^proceedings/submit/$', 'submit', name='kiwipycon_submit_proceedings'), |
62 url(r'^2009/proceedings/getusers/$', 'getUsers', name='kiwipycon_getusers_proceedings'), |
62 url(r'^proceedings/getusers/$', 'getUsers', name='kiwipycon_getusers_proceedings'), |
63 url(r'^2009/proceedings/edit/$', 'edit', name='kiwipycon_edit_proceedings'), |
63 url(r'^proceedings/edit/$', 'edit', name='kiwipycon_edit_proceedings'), |
64 ) |
64 ) |
65 |
65 |
66 # About pages and all other static html pages |
66 # About pages and all other static html pages |
67 urlpatterns += patterns('', |
67 urlpatterns += patterns('', |
68 url(r'^2009/about/accommodation/$', |
68 url(r'^about/accommodation/$', |
69 direct_to_template, {"template": "about/accommodation.html"}, |
69 direct_to_template, {"template": "about/accommodation.html"}, |
70 name='accommodation'), |
70 name='accommodation'), |
71 url(r'^2009/about/food/$', |
71 url(r'^about/food/$', |
72 direct_to_template, {"template": "about/food.html"}, name='food'), |
72 direct_to_template, {"template": "about/food.html"}, name='food'), |
73 url(r'^2009/about/venue/$', |
73 url(r'^about/venue/$', |
74 direct_to_template, {"template": "about/venue.html"}, name='venue'), |
74 direct_to_template, {"template": "about/venue.html"}, name='venue'), |
75 url(r'^2009/about/reaching/$', |
75 url(r'^about/reaching/$', |
76 direct_to_template, {"template": "about/reaching.html"}, |
76 direct_to_template, {"template": "about/reaching.html"}, |
77 name='reaching'), |
77 name='reaching'), |
78 url(r'^2009/talks-cfp/$', |
78 url(r'^talks-cfp/$', |
79 direct_to_template, {"template": "talk/talks-cfp.html"}, |
79 direct_to_template, {"template": "talk/talks-cfp.html"}, |
80 name='talks-cfp'), |
80 name='talks-cfp'), |
81 url(r'^2009/talks-cfp/schedule/$', |
81 url(r'^talks-cfp/schedule/$', |
82 direct_to_template, {"template": "talk/schedule.html"}, |
82 direct_to_template, {"template": "talk/schedule.html"}, |
83 name='schedule'), |
83 name='schedule'), |
84 url(r'^2009/talks-cfp/tutorial/$', |
84 url(r'^talks-cfp/tutorial/$', |
85 direct_to_template, {"template": "talk/tutorial-schedule.html"}, |
85 direct_to_template, {"template": "talk/tutorial-schedule.html"}, |
86 name='tutorial-schedule'), |
86 name='tutorial-schedule'), |
87 url(r'^2009/talks-cfp/sprint/$', |
87 url(r'^talks-cfp/sprint/$', |
88 direct_to_template, {"template": "talk/sprint-schedule.html"}, |
88 direct_to_template, {"template": "talk/sprint-schedule.html"}, |
89 name='sprint-schedule'), |
89 name='sprint-schedule'), |
90 url(r'^2009/talks-cfp/speakers/$', |
90 url(r'^talks-cfp/speakers/$', |
91 direct_to_template, {"template": "talk/speakers.html"}, |
91 direct_to_template, {"template": "talk/speakers.html"}, |
92 name='speakers'), |
92 name='speakers'), |
93 (r'^2009/accounts/', include('registration.urls')), |
93 (r'^accounts/', include('registration.urls')), |
94 ) |
94 ) |
95 |
95 |
96 # Password reset |
96 # Password reset |
97 urlpatterns += patterns('django.contrib.auth.views', |
97 urlpatterns += patterns('django.contrib.auth.views', |
98 url(r'^2009/password-reset/$', 'password_reset', name='kiwipycon_password_reset'), |
98 url(r'^password-reset/$', 'password_reset', name='kiwipycon_password_reset'), |
99 url(r'^2009/password-reset-done/$', 'password_reset_done'), |
99 url(r'^password-reset-done/$', 'password_reset_done'), |
100 url(r'^2009/password-reset-confirm/(?P<uidb36>[-\w]*)/(?P<token>[-\w]*)$', 'password_reset_confirm'), |
100 url(r'^password-reset-confirm/(?P<uidb36>[-\w]*)/(?P<token>[-\w]*)$', 'password_reset_confirm'), |
101 url(r'^2009/password-reset-complete/$', 'password_reset_complete'), |
101 url(r'^password-reset-complete/$', 'password_reset_complete'), |
102 ) |
102 ) |
103 |
103 |
104 # Serve static files in DEBUG = True mode |
104 # Serve static files in DEBUG = True mode |
105 if settings.DEBUG: |
105 if settings.DEBUG: |
106 urlpatterns += patterns('', |
106 urlpatterns += patterns('', |
107 (r'^2009/media/(?P<path>.*)$', 'django.views.static.serve', |
107 (r'^/2009/media/(?P<path>.*)$', 'django.views.static.serve', |
108 {'document_root': settings.MEDIA_ROOT}), |
108 {'document_root': settings.MEDIA_ROOT}), |
109 (r'^2009/static/(?P<path>.*)$', 'django.views.static.serve', |
109 (r'^/2009/static/(?P<path>.*)$', 'django.views.static.serve', |
110 {'document_root': settings.STATIC_ROOT}), |
110 {'document_root': settings.STATIC_ROOT}), |
111 ) |
111 ) |