annotate accounts/urls.py @ 989:2908859c2fe4

Smilies now use relative links. This is for upcoming switch to SSL. Currently we do not need absolute URLs for smilies. If this changes we can add it later.
author Brian Neal <bgneal@gmail.com>
date Thu, 29 Oct 2015 20:54:34 -0500
parents be233ba7ca31
children 5ba2508939f7
rev   line source
gremmie@1 1 """urls for the accounts application"""
bgneal@574 2 from django.conf.urls import patterns, url
bgneal@76 3 from django.conf import settings
bgneal@659 4 from django.views.generic import TemplateView
gremmie@1 5
gremmie@1 6 urlpatterns = patterns('accounts.views',
gremmie@1 7 url(r'^register/$', 'register', name='accounts-register'),
bgneal@905 8 url(r'^register/1/$', 'register1', name='accounts-register1'),
bgneal@905 9 url(r'^register/2/$', 'register2', name='accounts-register2'),
bgneal@905 10 url(r'^register/code/$', 'get_code', name='accounts-code'),
bgneal@905 11 url(r'^register/thanks/$', 'register_thanks', name='accounts-register_thanks'),
bgneal@905 12 url(r'^register/confirm/(?P<username>[\w.@+-]{1,30})/(?P<key>[a-zA-Z0-9]{20})/$',
bgneal@905 13 'register_confirm',
bgneal@905 14 name='accounts-register_confirm'),
gremmie@1 15 )
gremmie@1 16
gremmie@1 17 urlpatterns += patterns('',
bgneal@78 18 url(r'^login/$',
gremmie@1 19 'django.contrib.auth.views.login',
gremmie@1 20 kwargs={'template_name': 'accounts/login.html'},
gremmie@1 21 name='accounts-login'),
bgneal@78 22 url(r'^logout/$',
gremmie@1 23 'django.contrib.auth.views.logout',
gremmie@1 24 kwargs={'template_name': 'accounts/logout.html'},
bgneal@289 25 name='accounts-logout'),
bgneal@289 26 (r'^password/$',
bgneal@289 27 'django.contrib.auth.views.password_change',
gremmie@1 28 {'template_name': 'accounts/password_change.html',
bgneal@76 29 'post_change_redirect': settings.LOGIN_REDIRECT_URL}),
bgneal@289 30 url(r'^password/reset/$',
bgneal@289 31 'django.contrib.auth.views.password_reset',
bgneal@78 32 kwargs={'template_name': 'accounts/password_reset.html',
bgneal@78 33 'email_template_name': 'accounts/password_reset_email.txt',
bgneal@78 34 'post_reset_redirect': '/accounts/password/reset/sent/'},
bgneal@78 35 name='accounts-password_reset'),
bgneal@78 36 url(r'^password/reset/sent/$',
bgneal@78 37 'django.contrib.auth.views.password_reset_done',
bgneal@78 38 kwargs={'template_name': 'accounts/password_reset_sent.html'},
bgneal@78 39 name='accounts-password_reset_sent'),
bgneal@752 40 url(r'^password/reset/confirm/(?P<uidb64>[0-9A-Za-z_\-]+)/(?P<token>[0-9a-z]+-\w+)/$',
bgneal@78 41 'django.contrib.auth.views.password_reset_confirm',
bgneal@78 42 kwargs={
bgneal@78 43 'template_name': 'accounts/password_reset_confirm.html',
bgneal@78 44 'post_reset_redirect': '/accounts/password/reset/success/',
bgneal@78 45 },
bgneal@78 46 name='accounts-password_reset_confirm'),
bgneal@78 47 url(r'^password/reset/success/$',
bgneal@78 48 'django.contrib.auth.views.password_reset_complete',
bgneal@78 49 kwargs={'template_name': 'accounts/password_reset_complete.html'},
bgneal@78 50 name='accounts-password_reset_success'),
bgneal@659 51 url(r'^username/query/$',
bgneal@659 52 'accounts.views.username_query',
bgneal@659 53 name='accounts-username_query'),
bgneal@659 54 url(r'^username/sent/$',
bgneal@659 55 TemplateView.as_view(template_name='accounts/username_sent.html'),
bgneal@659 56 name='accounts-username_sent'),
gremmie@1 57 )
gremmie@1 58