{% extends "base_rigs.html" %}
{% load i18n %}
{% load widget_tweaks %}


{% block breadcrumbs %}
<div class="breadcrumbs">
<a href="{% url 'admin:index' %}">{% trans 'Home' %}</a>
&rsaquo; {% trans 'Password reset confirmation' %}
</div>
{% endblock %}

{% block title %}{% trans 'Password reset' %}{% endblock %}

{% block content %}

{% if validlink %}
<div class="col-sm-12">

	<h1>{% trans 'Enter new password' %}</h1>
	
	<p>{% trans "Please enter your new password twice so we can verify you typed it in correctly." %}</p>
	
	<div class="col-sm-8 col-sm-offset-2 well">
		<form action="" method="post" role="form" class="">{% csrf_token %}
			{% if form.errors %}
				{% include 'form_errors.html' %}
			{% endif %}
			<div class="form-group">
				<label for="{{form.new_password1.id_for_label}}" class="col-sm-4 col-form-label">{{form.new_password1.label}}</label>
				<div class="col-sm-8">
					{% render_field form.new_password1 class+="form-control" %}
				</div>
			</div>
			<div class="form-group">
				<label for="{{form.new_password2.id_for_label}}" class="col-sm-4 col-form-label">{{form.new_password2.label}}</label>
				<div class="col-sm-8">
					{% render_field form.new_password2 class+="form-control" %}
				</div>
			</div>
			<div class="col-sm-12">
				<div class="pull-right">
					<div class="form-group">
						<input type="submit" value="{% trans 'Change my password' %}" class="btn btn-primary" />
					</div>
				</div>
			</div>
		</form>
	</div>
	
	{% else %}
	
	<h1>{% trans 'Password reset unsuccessful' %}</h1>
	
	<p>{% trans "The password reset link was invalid, possibly because it has already been used.  Please request a new password reset." %}</p>
	
</div>

{% endif %}

{% endblock %}
