{% extends "layouts/content.html" %}
{% load i18n %}


{% block title %}{{ block.super }}| {% trans "Password change" %}{% endblock %}

{% block content %}
<h2>Password change</h2>

<div class="row">
<div class="col-md-12">
  <form class="form-horizontal" action="." method="post">
    {% csrf_token %}
    <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>
    <div class="form-group{% if form.old_password.errors %} has-error{% endif %}">
      <label class="col-md-2 control-label" for="id_old_password">{% trans "Old password" %}</label>
      <div class="col-md-4">
        {{ form.old_password }}
        {% for error in form.old_password.errors %}
        <p class="help-block">{{ error }}</p>
        {% endfor %}
      </div>
    </div>
    <div class="form-group{% if form.new_password1.errors %} has-error{% endif %}">
      <label class="col-md-2 control-label" for="id_new_password1">{% trans "New password" %}</label>
      <div class="col-md-4">
        {{ form.new_password1 }}
        {% for error in form.new_password1.errors %}
        <p class="help-block">{{ error }}</p>
        {% endfor %}
      </div>
    </div>
    <div class="form-group{% if form.new_password2.errors %} has-error{% endif %}">
      <label class="col-md-2 control-label" for="id_new_password2">{% trans "New password" %}</label>
      <div class="col-md-4">
        {{ form.new_password2 }}
        {% for error in form.new_password2.errors %}
        <p class="help-block">{{ error }}</p>
        {% endfor %}
      </div>
    </div>
    <div class="form-group">
      <div class="col-md-6 col-md-offset-2">
        <button class="btn btn-primary" type="submit">{% trans "Change" %}</button>
      </div>
    </div>
  </form>
</div>
</div>
{% endblock %}
