|
@@ -1,37 +1,51 @@
|
|
|
-{% extends "admin/base_site.html" %}
|
|
|
+{% extends "base.html" %}
|
|
|
{% load i18n %}
|
|
|
|
|
|
-{% block breadcrumbs %}
|
|
|
-<div class="breadcrumbs">
|
|
|
-<a href="{% url 'admin:index' %}">{% trans 'Home' %}</a>
|
|
|
-› {% trans 'Password reset confirmation' %}
|
|
|
-</div>
|
|
|
-{% endblock %}
|
|
|
+{% block content %}
|
|
|
|
|
|
-{% block title %}{% trans 'Password reset' %}{% endblock %}
|
|
|
+<div class="row">
|
|
|
+ <div class="large-12 columns">
|
|
|
|
|
|
-{% block content %}
|
|
|
+ {% if validlink %}
|
|
|
+
|
|
|
+ <h2>{% trans 'Enter new password' %}</h2>
|
|
|
|
|
|
-{% if validlink %}
|
|
|
+<!-- <p>{% trans "Please enter your new password twice so we can verify you typed it in correctly." %}</p> -->
|
|
|
|
|
|
-<h1>{% trans 'Enter new password' %}</h1>
|
|
|
|
|
|
-<p>{% trans "Please enter your new password twice so we can verify you typed it in correctly." %}</p>
|
|
|
|
|
|
-<form action="" method="post">{% csrf_token %}
|
|
|
-{{ form.new_password1.errors }}
|
|
|
-<p class="aligned wide"><label for="id_new_password1">{% trans 'New password:' %}</label>{{ form.new_password1 }}</p>
|
|
|
-{{ form.new_password2.errors }}
|
|
|
-<p class="aligned wide"><label for="id_new_password2">{% trans 'Confirm password:' %}</label>{{ form.new_password2 }}</p>
|
|
|
-<p><input type="submit" value="{% trans 'Change my password' %}" /></p>
|
|
|
-</form>
|
|
|
+ {% if form.errors %}
|
|
|
+ <div class="alert-box alert">
|
|
|
+ {% if form.errors.items|length == 1 %}{% trans "Please correct the error below." %}{% else %}{% trans "Please correct the errors below." %}{% endif %}
|
|
|
+ </div>
|
|
|
+ {% endif %}
|
|
|
|
|
|
-{% else %}
|
|
|
+ <form action="" method="post">{% csrf_token %}
|
|
|
+ <label {% if form.new_password1.errors %}class="error"{% endif %}>{% trans 'Password' %}
|
|
|
+ {{ form.new_password1 }}
|
|
|
+ </label>
|
|
|
+ {% if form.new_password1.errors %}
|
|
|
+ <span class="error">{% for error in form.new_password1.errors %}{{ error|escape }}{% endfor %}</span>
|
|
|
+ {% endif %}
|
|
|
|
|
|
-<h1>{% trans 'Password reset unsuccessful' %}</h1>
|
|
|
+ <label {% if form.new_password2.errors %}class="error"{% endif %}>{% trans 'Password (again)' %}
|
|
|
+ {{ form.new_password2 }}
|
|
|
+ </label>
|
|
|
+ {% if form.new_password2.errors %}
|
|
|
+ <span class="error">{% for error in form.new_password2.errors %}{{ error|escape }}{% endfor %}</span>
|
|
|
+ {% endif %}
|
|
|
|
|
|
-<p>{% trans "The password reset link was invalid, possibly because it has already been used. Please request a new password reset." %}</p>
|
|
|
+ <input type="submit" value="{% trans 'Change my password' %}" class="button radius" />
|
|
|
+ </form>
|
|
|
|
|
|
-{% endif %}
|
|
|
+ {% else %}
|
|
|
+
|
|
|
+ <h2>{% trans 'Password reset unsuccessful' %}</h2>
|
|
|
+
|
|
|
+ <p>{% trans "The password reset link was invalid, possibly because it has already been used. Please request a new password reset." %}</p>
|
|
|
+
|
|
|
+ {% endif %}
|
|
|
+ </div>
|
|
|
+</div>
|
|
|
|
|
|
{% endblock %}
|