# HG changeset patch # User Brian Neal # Date 1334433314 18000 # Node ID 4fc5dfe04b3000cbdd6cd0e8b0f55178bb3b1784 # Parent 0f8ad2d97cda022fe48e82f637ba112f3c161219 For Django 1.4, add a password reset feature to the admin. diff -r 0f8ad2d97cda -r 4fc5dfe04b30 madeira/urls.py --- a/madeira/urls.py Sat Apr 14 14:37:21 2012 -0500 +++ b/madeira/urls.py Sat Apr 14 14:55:14 2012 -0500 @@ -7,19 +7,27 @@ admin.autodiscover() urlpatterns = patterns('', - url(r'^$', - TemplateView.as_view(template_name='index.html'), - name='home'), - (r'^', include('band.urls')), - (r'^gigs/', include('gigs.urls')), - (r'^mail/', include('email_list.urls')), - (r'^news/', include('news.urls')), - (r'^press/', include('articles.urls')), - (r'^songs/', include('mp3.urls')), - (r'^videos/', include('videos.urls')), - (r'^admin/doc/', include('django.contrib.admindocs.urls')), - (r'^admin/', include(admin.site.urls)), - (r'^photologue/', include('photologue.urls')), + url(r'^$', + TemplateView.as_view(template_name='index.html'), + name='home'), + (r'^', include('band.urls')), + (r'^gigs/', include('gigs.urls')), + (r'^mail/', include('email_list.urls')), + (r'^news/', include('news.urls')), + (r'^press/', include('articles.urls')), + (r'^songs/', include('mp3.urls')), + (r'^videos/', include('videos.urls')), + (r'^admin/doc/', include('django.contrib.admindocs.urls')), + url(r'^admin/password_reset/$', + 'django.contrib.auth.views.password_reset', + name='admin_password_reset'), + (r'^admin/password_reset/done/$', + 'django.contrib.auth.views.password_reset_done'), + (r'^reset/(?P[0-9A-Za-z]+)-(?P.+)/$', + 'django.contrib.auth.views.password_reset_confirm'), + (r'^reset/done/$', 'django.contrib.auth.views.password_reset_complete'), + (r'^admin/', include(admin.site.urls)), + (r'^photologue/', include('photologue.urls')), ) # For serving media files in development only: