annotate gpp/accounts/urls.py @ 76:eecbd00e092a

#25 Fix problem with redirect after changing password.
author Brian Neal <bgneal@gmail.com>
date Fri, 10 Jul 2009 23:50:06 +0000
parents dbd703f7d63a
children 4edfea7f8620
rev   line source
gremmie@1 1 """urls for the accounts application"""
gremmie@1 2 from django.conf.urls.defaults import *
bgneal@76 3 from django.conf import settings
gremmie@1 4
gremmie@1 5 urlpatterns = patterns('accounts.views',
gremmie@1 6 url(r'^register/$', 'register', name='accounts-register'),
gremmie@1 7 (r'^register/thanks/$', 'register_thanks'),
gremmie@1 8 (r'^register/confirm/(?P<username>\w{1,30})/(?P<key>[a-zA-Z0-9]{20})/$', 'register_confirm'),
gremmie@1 9 )
gremmie@1 10
gremmie@1 11 urlpatterns += patterns('',
gremmie@1 12 url(r'^login/',
gremmie@1 13 'django.contrib.auth.views.login',
gremmie@1 14 kwargs={'template_name': 'accounts/login.html'},
gremmie@1 15 name='accounts-login'),
gremmie@1 16 url(r'^logout/',
gremmie@1 17 'django.contrib.auth.views.logout',
gremmie@1 18 kwargs={'template_name': 'accounts/logout.html'},
gremmie@1 19 name='accounts-logout'),
gremmie@1 20 (r'^password/',
gremmie@1 21 'django.contrib.auth.views.password_change',
gremmie@1 22 {'template_name': 'accounts/password_change.html',
bgneal@76 23 'post_change_redirect': settings.LOGIN_REDIRECT_URL}),
gremmie@1 24 )
gremmie@1 25