From 33e82e8676ebbccf7da17fcb0fb9f2b33abe78de Mon Sep 17 00:00:00 2001 From: Ross Date: Thu, 9 Jun 2022 18:15:42 +0100 Subject: [PATCH] . --- templates/index.html | 2 +- .../registration/password_change_done.html | 9 ++++ .../registration/password_change_form.html | 53 +++++++++++++++++++ .../registration/password_reset_confirm.html | 3 +- 4 files changed, 65 insertions(+), 2 deletions(-) create mode 100644 templates/registration/password_change_done.html create mode 100644 templates/registration/password_change_form.html diff --git a/templates/index.html b/templates/index.html index 85e85e9c..8ee2096d 100644 --- a/templates/index.html +++ b/templates/index.html @@ -4,7 +4,7 @@

PENRA Courses

{% if not request.user.is_authenticated %} - Log in + Log in
Reset password {% else %} Atlas diff --git a/templates/registration/password_change_done.html b/templates/registration/password_change_done.html new file mode 100644 index 00000000..e9a2ce3f --- /dev/null +++ b/templates/registration/password_change_done.html @@ -0,0 +1,9 @@ +{% extends 'base.html' %} +{% load i18n %}. + +{% block title %}Password change{% endblock %} + +{% block content %} +

Password changed

+

{% translate 'Your password was changed.' %}

+{% endblock %} \ No newline at end of file diff --git a/templates/registration/password_change_form.html b/templates/registration/password_change_form.html new file mode 100644 index 00000000..9f301b83 --- /dev/null +++ b/templates/registration/password_change_form.html @@ -0,0 +1,53 @@ + +{% extends 'base.html' %} +{% load i18n %}. + +{% block title %}Password change{% endblock %} + +{% block content %}
+

Password change

+ +
{% csrf_token %} +
+ {% if form.errors %} +

+ {% if form.errors.items|length == 1 %}{% translate "Please correct the error below." %}{% else %}{% translate "Please correct the errors below." %}{% endif %} +

+ {% endif %} + + +

{% translate 'Please enter your old password, for security’s sake, and then enter your new password twice so we can verify you typed it in correctly.' %}

+ +
+ +
+ {{ form.old_password.errors }} + {{ form.old_password.label_tag }} {{ form.old_password }} +
+ +
+ {{ form.new_password1.errors }} + {{ form.new_password1.label_tag }} {{ form.new_password1 }} + {% if form.new_password1.help_text %} +
{{ form.new_password1.help_text|safe }}
+ {% endif %} +
+ +
+ {{ form.new_password2.errors }} + {{ form.new_password2.label_tag }} {{ form.new_password2 }} + {% if form.new_password2.help_text %} +
{{ form.new_password2.help_text|safe }}
+ {% endif %} +
+ +
+ +
+ +
+ +
+
+ +{% endblock %} \ No newline at end of file diff --git a/templates/registration/password_reset_confirm.html b/templates/registration/password_reset_confirm.html index ca27124e..3a1c9937 100644 --- a/templates/registration/password_reset_confirm.html +++ b/templates/registration/password_reset_confirm.html @@ -1,5 +1,5 @@ -{% extends "base.html" %} +{% extends "../base.html" %} {% block title %}Enter new password{% endblock %} @@ -15,6 +15,7 @@ {% else %} +

Invalid link

The password reset link was invalid, possibly because it has already been used. Please request a new password reset.