annotate gpp/accounts/urls.py @ 260:3a4bbf9c2cce

Fixing #107. Apparently some signal handlers were getting connected twice (double import?) and thus saving a forum post would cause 2 email notifications to go out to the post topic's subscribers. Use the dispatch_uid parameter in the connect call to work around this issue.
author Brian Neal <bgneal@gmail.com>
date Wed, 22 Sep 2010 00:24:59 +0000
parents 4edfea7f8620
children 0dd8989abef2
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('',
bgneal@78 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'),
bgneal@78 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'),
bgneal@78 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}),
bgneal@78 24 url(r'^password/reset/$',
bgneal@78 25 'django.contrib.auth.views.password_reset',
bgneal@78 26 kwargs={'template_name': 'accounts/password_reset.html',
bgneal@78 27 'email_template_name': 'accounts/password_reset_email.txt',
bgneal@78 28 'post_reset_redirect': '/accounts/password/reset/sent/'},
bgneal@78 29 name='accounts-password_reset'),
bgneal@78 30 url(r'^password/reset/sent/$',
bgneal@78 31 'django.contrib.auth.views.password_reset_done',
bgneal@78 32 kwargs={'template_name': 'accounts/password_reset_sent.html'},
bgneal@78 33 name='accounts-password_reset_sent'),
bgneal@78 34 url(r'^password/reset/confirm/(?P<uidb36>[0-9a-z]+)/(?P<token>[0-9a-z]+-\w+)/$',
bgneal@78 35 'django.contrib.auth.views.password_reset_confirm',
bgneal@78 36 kwargs={
bgneal@78 37 'template_name': 'accounts/password_reset_confirm.html',
bgneal@78 38 'post_reset_redirect': '/accounts/password/reset/success/',
bgneal@78 39 },
bgneal@78 40 name='accounts-password_reset_confirm'),
bgneal@78 41 url(r'^password/reset/success/$',
bgneal@78 42 'django.contrib.auth.views.password_reset_complete',
bgneal@78 43 kwargs={'template_name': 'accounts/password_reset_complete.html'},
bgneal@78 44 name='accounts-password_reset_success'),
gremmie@1 45 )
gremmie@1 46