{% extends 'settings/layout.html.twig' %}
{% block title %}{{'支付密码'|trans}} - {{'安全设置'|trans}} - {{ parent() }}{% endblock %}
{% set side_nav = 'security' %}
{% do script(['libs/jquery-validation.js','app/js/settings/update-pay-password/index.js'])%}

{% block main %}
 {% embed "bootstrap/panel.html.twig" with {class:'panel-col'} %}
    {% block heading %}{{'安全设置'|trans}}{% endblock %}
    {% block body %}

      <ul class="breadcrumb">
        <li><a href="{{ path('settings_security') }}">{{'安全设置'|trans}}</a></li>
        <li class="active">{{'找回支付密码'|trans}}</li>
      </ul>

    {{ web_macro.flash_messages() }}

      <form id="pay-password-reset-update-form" class="form-horizontal" method="post" action="{{ path('settings_update_pay_password') }}">

        {{ web_macro.flash_messages() }}

        <div class="form-group">
          <div class="col-md-3 control-label">
            {{ form_label(form.payPassword, '新支付密码'|trans) }}
          </div>
          <div class="col-md-8 controls">
            {{ form_widget(form.payPassword, {attr:{class:'form-control'}}) }}
            <p class="help-block">{{'请输入支付密码'|trans}}</p>
          </div>
        </div>

        <div class="form-group">
          <div class="col-md-3 control-label">
            {{ form_label(form.confirmPayPassword, '确认支付密码'|trans) }}
          </div>
          <div class="col-md-8 controls">
            {{ form_widget(form.confirmPayPassword, {attr:{class:'form-control'}}) }}
            <p class="help-block">{{'请再输入一次支付密码'|trans}}</p>
          </div>
        </div>

        <div class="form-group">
          <div class="col-md-3 control-label">
            {{ form_label(form.currentUserLoginPassword, '用户登录密码'|trans) }}
          </div>
          <div class="col-md-8 controls">
            {{ form_widget(form.currentUserLoginPassword, {attr:{class:'form-control'}}) }}
            <p class="help-block">{{'请输入用户登录密码'|trans}}</p>
          </div>
        </div>

        <div class="form-group">
          <div class="col-md-offset-3 col-md-8">
            {{ form_rest(form) }}
            <button  id="payPassword-save-btn" type="button" class="btn btn-primary">{{'重设支付密码'|trans}}</button>
          </div>
        </div>

        <input type="hidden" name="token" value="{{ token.token }}">
        <input type="hidden" name="_csrf_token" value="{{ csrf_token('site') }}">

      </form>


    {% endblock %}
  {% endembed %}
{% endblock %}