機能を追加するには、django
ビルトインの認証ビューをユーザーにしようとしています。Djangoのデフォルトのpassword_changeはもう動作しませんか?
は、私が 'ユーザ' という名前のアプリを作成し、以下のようなurls.py
を設定:
をそして私は、あまりにも、users/password_change_form.html
、users/password_change_done.html
作成します。
しかし、それはエラーが発生します。
[20/Aug/2016 13:55:00] "GET /accounts/password_change/ HTTP/1.1" 500 106496
Internal Server Error: /accounts/password_change/
Traceback (most recent call last):
File "/Users/Chois/.pyenv/versions/chacha_dabang/lib/python3.5/site-packages/django/core/handlers/base.py", line 149, in get_response
response = self.process_exception_by_middleware(e, request)
File "/Users/Chois/.pyenv/versions/chacha_dabang/lib/python3.5/site-packages/django/core/handlers/base.py", line 147, in get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/Users/Chois/.pyenv/versions/chacha_dabang/lib/python3.5/site-packages/django/views/decorators/debug.py", line 76, in sensitive_post_parameters_wrapper
return view(request, *args, **kwargs)
File "/Users/Chois/.pyenv/versions/chacha_dabang/lib/python3.5/site-packages/django/utils/decorators.py", line 149, in _wrapped_view
response = view_func(request, *args, **kwargs)
File "/Users/Chois/.pyenv/versions/chacha_dabang/lib/python3.5/site-packages/django/contrib/auth/decorators.py", line 23, in _wrapped_view
return view_func(request, *args, **kwargs)
File "/Users/Chois/.pyenv/versions/chacha_dabang/lib/python3.5/site-packages/django/contrib/auth/views.py", line 49, in inner
return func(*args, **kwargs)
File "/Users/Chois/.pyenv/versions/chacha_dabang/lib/python3.5/site-packages/django/contrib/auth/views.py", line 308, in password_change
post_change_redirect = reverse('password_change_done')
File "/Users/Chois/.pyenv/versions/chacha_dabang/lib/python3.5/site-packages/django/core/urlresolvers.py", line 600, in reverse
return force_text(iri_to_uri(resolver._reverse_with_prefix(view, prefix, *args, **kwargs)))
File "/Users/Chois/.pyenv/versions/chacha_dabang/lib/python3.5/site-packages/django/core/urlresolvers.py", line 508, in _reverse_with_prefix
(lookup_view_s, args, kwargs, len(patterns), patterns))
django.core.urlresolvers.NoReverseMatch: Reverse for 'password_change_done' with arguments '()' and keyword arguments '{}' not found. 0 pattern(s) tried: []
はあなたの助けを必要としています。ありがとう:)