{##
 # The form displayed when the user is resetting their password after clicking the reset link in their email.
 ##}

{% extends 'UserBundle::layout.html.twig' %}
{% block content %}
<section class="dp-portal-section dp-new-feedback-section">
	<header>
		<h1>{{ phrase('user.profile.reset_password') }}</h1>
	</header>
	<article>

		{% if errors['password.short'] %}<div class="dp-alert dp-alert-error">{{ phrase('user.profile.register_password_min_length') }}</div>{% endif %}
			{% if errors['password.mismatch'] %}<div class="dp-alert dp-alert-error">{{ phrase('user.profile.register_password_mismatch') }}</div>{% endif %}

		<form action="{{ path('user_login_resetpass_newpass', {'code': code}) }}" class="form login" method="post">
			{{ form_token() }}
			<input type="hidden" name="process" value="1" />
			<div class="dp-control-group">
				<div class="dp-control-label">
					<label>{{ phrase('user.profile.label_new_password') }}</label>
				</div>
				<div class="dp-controls">
					<input type="password" autocomplete="off" value="" name="password" id="password" size="40" />
				</div>
			</div>
			<div class="dp-control-group">
				<div class="dp-control-label">
					<label>{{ phrase('user.profile.label_repeat_password') }}</label>
				</div>
				<div class="dp-controls">
					<input type="password" autocomplete="off" value="" name="password2" id="password2" size="40" />
				</div>
			</div>

			<input class="btn primary" type="submit" value="{{ phrase('user.profile.reset_password') }}" />
		</form>
	</article>
</section>
{% endblock %}
