Project

General

Profile

0001-password-change-related-pages-adapted-to-site-design.patch

Serghei Mihai, 18 September 2014 12:43 AM

Download (3.8 KB)

View differences:

Subject: [PATCH] password change related pages adapted to site design

Closes #5449
 calebasse/static/css/accounts.css                  | 17 ++++++++++
 .../registration/password_change_done.html         | 20 +++++++++++
 .../registration/password_change_form.html         | 39 ++++++++++++++++++++++
 3 files changed, 76 insertions(+)
 create mode 100644 calebasse/static/css/accounts.css
 create mode 100644 calebasse/templates/registration/password_change_done.html
 create mode 100644 calebasse/templates/registration/password_change_form.html
calebasse/static/css/accounts.css
1
#password_change label {
2
    float: left;
3
    width: 15em;
4
}
5

  
6
#password_change div.form-row {
7
    margin: 1em 0;
8
}
9

  
10
.icon-warning:before {
11
    content: "\f071";
12
    color: orange;
13
}
14

  
15
ul.errorlist, ul.errorlist li {
16
    display: inline;
17
}
calebasse/templates/registration/password_change_done.html
1
{% extends "calebasse/base.html" %}
2
{% load i18n %}
3

  
4
{% load i18n static %}
5
{% block extrastyles %}
6
<link rel="stylesheet" type="text/css" href="{% static "css/accounts.css" %}" />
7
{% endblock extrastyles %}
8

  
9
{% block appbar %}
10
<h2>{% trans 'Password change' %}</h2>
11
    <a href="../../..">Retourner à l'accueil</a>
12
{% endblock %}
13

  
14
{% block title %}{% trans 'Password change successful' %}{% endblock %}
15

  
16
{% block content %}
17

  
18
<p>{% trans 'Your password was changed.' %}</p>
19

  
20
{% endblock %}
calebasse/templates/registration/password_change_form.html
1
{% extends "calebasse/base.html" %}
2
{% load i18n static %}
3
{% block extrastyles %}
4
<link rel="stylesheet" type="text/css" href="{% static "css/accounts.css" %}" />
5
{% endblock extrastyles %}
6

  
7
{% block title %}{% trans 'Password change' %}{% endblock %}
8
{% block appbar %}
9
<h2>{% trans 'Password change' %}</h2>
10
    <a href="../..">Retourner à l'accueil</a>
11
{% endblock %}
12

  
13
{% block content %}
14
<div id="password_change">
15

  
16
  <form method="post">{% csrf_token %}
17
    <div>
18
      <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>
19
      {% if form.errors %}
20
      <p class="icon-warning errornote">
21
        {% blocktrans count counter=form.errors.items|length %}Please correct the error below.{% plural %}Please correct the errors below.{% endblocktrans %}
22
      </p>
23
      {% endif %}
24
      <div class="form-row">
25
        <label for="id_old_password" class="required">{% trans 'Old password' %}:</label>{{ form.old_password }} {{ form.old_password.errors }}
26
      </div>
27
      <div class="form-row">
28
        <label for="id_new_password1" class="required">{% trans 'New password' %}:</label>{{ form.new_password1 }} {{ form.new_password1.errors }}
29
      </div>
30
      <div class="form-row">
31
        <label for="id_new_password2" class="required">{% trans 'Password (again)' %}:</label>{{ form.new_password2 }} {{ form.new_password2.errors }}
32
      </div>
33
      <div class="submit-row">
34
        <button>{% trans 'Change my password' %}</button>
35
      </div>
36
    </div>
37
  </form>
38
</div>
39
{% endblock %}
0
-