{% extends 'settings/find-pay-password.html.twig' %}
{% block title %}{{'user.fields.pay_password'|trans}} - {{'user.settings.security_menu'|trans}} - {{ parent() }}{% endblock %}

{% set stepTwo = true %}
{% set questionOptions = dict('secureQuestion') %}
{% do script(['libs/jquery-validation.js','app/js/settings/find_pay_password_by_sms/index.js'])%}


{% block panel_body %}
  <div class="hidden">
    {{ web_macro.flash_messages() }}
  </div>
  <form id="settings-find-pay-password-form" class="find-pay-password-form" method="post" data-url="{{ path('settings_update_pay_password') }}">

    <input type="text" id="mobile" name="mobile" class="hidden" data-role="mobile" value="{{verifiedMobile}}">

    <div class="form-group cd-form-group cd-form-group-mobile">
      <label>{{ 'user.settings.security.pay_password_find.by_mobile_current'|trans }}</label>
      <span class="color-primary">{{ blur_phone_number(verifiedMobile) }}</span>
      <a class="cd-link-assist" href="{{ path('settings_security') }}" target="_blank">{{ 'user.settings.security.pay_password_find.by_mobile.change'|trans }}</a>
    </div>

    {% if (setting('auth.captcha_enabled')|default(0)) == 1 %}
      <div class="form-group cd-mb24 js-drag-jigsaw hidden">
        {% include 'common/drag.html.twig' with { auth: true } %}
      </div>
    {% endif %}

    <div class="form-group cd-form-group cd-form-group-action cd-mt40">
      <label for="sms_code">{{'user.settings.security.sms_code'|trans}}</label>
      <input type="text" id="sms-code" name="sms_code" class="form-control" value="" data-url="{{path('edu_cloud_sms_check',{type:'sms_forget_pay_password'})}}">
      <div class="action-button">
        <button class="btn cd-btn cd-btn-ghost-primary btn-block js-sms-send {% if not verifiedMobile %}disabled{% endif %}" type="button" data-sms-url="{{ path('edu_cloud_sms_send_check_captcha') }}" data-sms-type="sms_forget_pay_password">
          <span id="js-time-left"></span>
          <span id="js-fetch-btn-text">{{'user.settings.security.get_sms_code_btn'|trans}}</span>
        </button>
      </div>
    </div>

    <button class="btn cd-btn cd-btn-primary cd-btn-lg btn-block" id="submit-btn" data-loading-text="{{'form.btn.submit.submiting'|trans}}" type="button">{{'form.btn.submit'|trans}}</button>

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

{% endblock %}