password change related pages adapted to site design

Closes #5449
This commit is contained in:
Serghei Mihai 2014-09-18 00:38:58 +02:00
parent 563749730f
commit a1ea93302a
3 changed files with 76 additions and 0 deletions

View File

@ -0,0 +1,17 @@
#password_change label {
float: left;
width: 15em;
}
#password_change div.form-row {
margin: 1em 0;
}
.icon-warning:before {
content: "\f071";
color: orange;
}
ul.errorlist, ul.errorlist li {
display: inline;
}

View File

@ -0,0 +1,20 @@
{% extends "calebasse/base.html" %}
{% load i18n %}
{% load i18n static %}
{% block extrastyles %}
<link rel="stylesheet" type="text/css" href="{% static "css/accounts.css" %}" />
{% endblock extrastyles %}
{% block appbar %}
<h2>{% trans 'Password change' %}</h2>
<a href="../../..">Retourner à l'accueil</a>
{% endblock %}
{% block title %}{% trans 'Password change successful' %}{% endblock %}
{% block content %}
<p>{% trans 'Your password was changed.' %}</p>
{% endblock %}

View File

@ -0,0 +1,39 @@
{% extends "calebasse/base.html" %}
{% load i18n static %}
{% block extrastyles %}
<link rel="stylesheet" type="text/css" href="{% static "css/accounts.css" %}" />
{% endblock extrastyles %}
{% block title %}{% trans 'Password change' %}{% endblock %}
{% block appbar %}
<h2>{% trans 'Password change' %}</h2>
<a href="../..">Retourner à l'accueil</a>
{% endblock %}
{% block content %}
<div id="password_change">
<form method="post">{% csrf_token %}
<div>
<p>{% trans "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>
{% if form.errors %}
<p class="icon-warning errornote">
{% blocktrans count counter=form.errors.items|length %}Please correct the error below.{% plural %}Please correct the errors below.{% endblocktrans %}
</p>
{% endif %}
<div class="form-row">
<label for="id_old_password" class="required">{% trans 'Old password' %}:</label>{{ form.old_password }} {{ form.old_password.errors }}
</div>
<div class="form-row">
<label for="id_new_password1" class="required">{% trans 'New password' %}:</label>{{ form.new_password1 }} {{ form.new_password1.errors }}
</div>
<div class="form-row">
<label for="id_new_password2" class="required">{% trans 'Password (again)' %}:</label>{{ form.new_password2 }} {{ form.new_password2.errors }}
</div>
<div class="submit-row">
<button>{% trans 'Change my password' %}</button>
</div>
</div>
</form>
</div>
{% endblock %}