{% extends "admin/base_site.html" %}
{% load i18n admin_urls admin_static admin_modify bootstrapped_goodies_tags %}

{% block extrahead %}{{ block.super }}
{% url 'admin:jsi18n' as jsi18nurl %}
<script type="text/javascript" src="{{ jsi18nurl|default:"../../../../jsi18n/" }}"></script>
{% endblock %}
{% block extrastyle %}{{ block.super }}<link rel="stylesheet" type="text/css" href="{% static "admin/css/forms.css" %}" />{% endblock %}
{% block bodyclass %}{{ block.super }} {{ opts.app_label }}-{{ opts.model_name }} change-form{% endblock %}
{% if not is_popup %}
{% block breadcrumbs %}
<ul class="breadcrumb">
<li><a href="{% url 'admin:index' %}">{% trans 'Home' %}</a></li>
<li><a href="{% url 'admin:app_list' app_label=opts.app_label %}">{{ opts.app_label|capfirst|escape }}</a></li>
<li><a href="{% url opts|admin_urlname:'changelist' %}">{{ opts.verbose_name_plural|capfirst }}</a></li>
<li><a href="{% url opts|admin_urlname:'changelist' %}{{ original.pk }}">{{ original|truncatewords:"18" }}</a></li>
<li>{% trans 'Change password' %}</li>
</ul>
{% endblock %}
{% endif %}
{% block content %}<div id="content-main">
<form class="form-horizontal" action="{{ form_url }}" method="post" id="{{ opts.model_name }}_form">{% csrf_token %}{% block form_top %}{% endblock %}
<div>
{% if is_popup %}<input type="hidden" name="_popup" value="1" />{% endif %}
{% if form.errors %}
    <p class="errornote">
        {% if form.errors.items|length == 1 %}{% trans "Please correct the error below." %}{% else %}{% trans "Please correct the errors below." %}{% endif %}
    </p>
{% endif %}

<p>{% blocktrans with username=original %}Enter a new password for the user <strong>{{ username }}</strong>.{% endblocktrans %}</p>

<fieldset class="_module _aligned">

<div class="fields">

<div class="row">
<div class="control-group">
<div class="col-md-12 form-group">
  {{ form.password1.errors }}
  <div class="control-label col-md-3">{{ form.password1.label_tag }}</div>
  <div class="controls col-md-9">
    {% dab_field_rendering form.password1 %}
    {% if form.password1.help_text %}
    <span class="help-block">{{ form.password1.help_text }}</span>
    {% endif %}
  </div>
</div>
</div>
</div>

<div class="row">
<div class="control-group">
<div class="col-md-12 form-group">
  {{ form.password2.errors }}
  <div class="control-label col-md-3">{{ form.password2.label_tag }}</div>
  <div class="controls col-md-9">
    {% dab_field_rendering form.password2 %}
    {% if form.password2.help_text %}
    <span class="help-block">{{ form.password2.help_text }}</span>
    {% endif %}
  </div>
</div>
</div>
</div>

</div>

</fieldset>

<div class="form-actions">
<div class="pull-right">
<input type="submit" value="{% trans 'Change password' %}" class="btn btn-primary default" />
</div>
</div>

<script type="text/javascript">document.getElementById("id_password1").focus();</script>
</div>
</form></div>
{% endblock %}
