From 8427da2f08ae590b427027abe36351018c685f8e Mon Sep 17 00:00:00 2001 From: prathamesh Date: Wed, 1 Feb 2017 13:00:34 +0530 Subject: Forgot Password and Reset Issue Resolved The problem was: We have included yaksh urls to the project urls with the namespace "yaksh". So whenever we call the url name i.e "yaksh:" a reverse match is made. But for Forgot Password and Change Password we are using django's in-built functionality, where the reverse url is hardcoded. So the reverse match fails as the namespace is not specified! To resolve this, created a urls_password_reset URL dispatcher file and included to the project urls. --- yaksh/urls.py | 26 -------------------------- 1 file changed, 26 deletions(-) (limited to 'yaksh/urls.py') diff --git a/yaksh/urls.py b/yaksh/urls.py index 629f8f5..5544088 100644 --- a/yaksh/urls.py +++ b/yaksh/urls.py @@ -1,33 +1,7 @@ from django.conf.urls import patterns, url from yaksh import views -from django.contrib.auth.views import password_reset, password_reset_confirm,\ - password_reset_done, password_reset_complete, password_change,\ - password_change_done -# app_name = 'yaksh' urlpatterns = [ - url(r'^forgotpassword/$', password_reset, - {'template_name': 'register/password_reset_form.html'}, - name="password_reset"), - url(r'^password_reset/(?P[0-9A-Za-z]+)-(?P.+)/$', - password_reset_confirm, - {'template_name': 'register/password_reset_confirm.html'}, - name='password_reset_confirm'), - url(r'^password_reset/mail_sent/$', password_reset_done, - {'template_name': 'register/password_reset_done.html'}, - name='password_reset_done'), - url(r'^password_reset/complete/$', password_reset_complete, - {'template_name': 'register/password_reset_complete.html'}, - name='password_reset_complete'), - url(r'^changepassword/$', password_change, - {'template_name': 'register/password_change_form.html'}, - name='password_change'), - url(r'^password_change/done/$', password_change_done, - {'template_name': 'register/password_change_done.html'}, - name='password_change_done'), -] - -urlpatterns += [ url(r'^$', views.index), url(r'^login/$', views.user_login, name='login'), url(r'^quizzes/$', views.quizlist_user, name='quizlist_user'), -- cgit