Commit 7fb5a647 authored by Jeremy Kerr's avatar Jeremy Kerr
Browse files

templates: use custom templates for password change



Add a couple of templates to keep the password change flow in the same
look & feel as the rest of the site.
Signed-off-by: default avatarJeremy Kerr <jk@ozlabs.org>
parent ec565d23
......@@ -393,7 +393,7 @@ table.form tr td.submitrow {
text-align: center;
}
table.registerform {
table.registerform, table.passwordform {
margin-left: auto;
margin-right: auto;
}
......@@ -410,6 +410,9 @@ table.loginform {
padding-left: 0.2em;
margin: 0em;
}
.error {
color: red;
}
/* generic table with header columns on the left */
table.horizontal {
......
{% extends "base.html" %}
{% block title %}Password Change Complete{% endblock %}
{% block heading %}Password Change Complete{% endblock %}
{% block body %}
<p>Your password has been changed sucessfully.</p>
{% endblock %}
{% extends "base.html" %}
{% block title %}Password Change{% endblock %}
{% block heading %}Password Change{% endblock %}
{% block body %}
<p>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.</p>
<form method="post">
{% csrf_token %}
<table class="form passwordform">
{% if form.errors %}
<tr>
<td colspan="2" class="error">Please correct the errors below.</p>
</tr>
{% endif %}
{% for field in form %}
<tr>
<td>{{ field.label_tag }}</td>
<td>
{{ field.errors }}
{{ field }}
{% if field.help_text %}
<div class="help_text"/>{{ field.help_text }}</div>
{% endif %}
</td>
</tr>
{% endfor %}
<tr>
<td colspan="2" class="error">
<input type="submit" value="Change my password" class="default" />
</td>
</tr>
</table>
</form>
{% endblock %}
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment