templates/website/user/receiver/receiver-form-step-info.html.twig line 1

Open in your IDE?
  1. {% from 'utils.html.twig' import ico %}
  2. {# MODO DE EXIBIÇÃO TIPO PESSOA #}
  3. {% if infoType is not defined %}
  4.     {% set infoType = '' %}
  5. {% endif %}
  6. {% set infoTypeEdit = (
  7.     receiverEdit ? (infoType ? receiverPartnerEdit : receiverEdit) : false
  8. ) %}
  9. <div class="cp-cols">
  10.     {% if infoType is empty %}
  11.         {# KIND #}
  12.         <div class="cp cp-3">
  13.             <label for="receiver-person-type">{{ getLanguage('person', 'receiver') }}{{ req|raw }}</label>
  14.             {# EDIT #}
  15.             {% if infoTypeEdit %}
  16.                 {% if infoTypeEdit.personType == enum('ReceiverEnum::PERSON') %}
  17.                     {% set key = 'natural' %}
  18.                 {% elseif infoTypeEdit.personType == enum('ReceiverEnum::COMPANY') %}
  19.                     {% set key = 'juridical' %}
  20.                 {% endif %}
  21.                 <select class="js--input-disabled" disabled>
  22.                     <option>{{ getLanguage(key, 'receiver') }}</option>
  23.                 </select>
  24.             {# REGISTER #}
  25.             {% else %}
  26.                 <select id="receiver-person-type" name="personType" class="js--tipo-pessoa-select custom-select" required>
  27.                     <option value="{{ enum('ReceiverEnum::PERSON') }}">{{ getLanguage('natural', 'receiver') }}</option>
  28.                     <option value="{{ enum('ReceiverEnum::COMPANY')}}">{{ getLanguage('juridical', 'receiver') }}</option>
  29.                 </select>
  30.             {% endif %}
  31.         </div>
  32.     {% endif %}
  33.     {# DOCUMENT NUMBER #}
  34.     <div id="document-type-person" class="cp cp-3">
  35.         <label for="{{ (infoType) ? 'partner-' }}receiver-document">
  36.             <span>CPF{{ req|raw }}</span>
  37.             <span>CNPJ{{ req|raw }}</span>
  38.             &emsp;
  39.         </label>
  40.         <input type="text" id="{{ (infoType) ? 'partner-' }}receiver-document" 
  41.         name="documentNumber{{ infoType }}" class="js--input-form js--input-disabled" class="mask-cpf-cnpj" 
  42.         placeholder="{{ getLanguage('enter_the_number', 'receiver') }}" 
  43.         value="{{ infoTypeEdit? infoTypeEdit.documentNumber }}" 
  44.         {{ infoTypeEdit and infoTypeEdit.documentNumber is not empty ? 'readonly' }} required>
  45.     </div>
  46.     {# BIRTH DATE #}
  47.     {% if ((infoTypeEdit and receiverEdit.personType == enum('ReceiverEnum::PERSON')) or infoType is not empty)
  48.     or not infoTypeEdit %}
  49.         <div id="birthdate-type-person" class="cp cp-3">
  50.             <label for="{{ (infoType) ? 'partner-' }}receiver-birth-date">{{ getLanguage('birth_date', 'receiver') }}{{ req|raw }}</label>
  51.             <input type="text" id="{{ (infoType) ? 'partner-' }}receiver-birth-date" 
  52.             name="birthDate{{ infoType }}" class="mask-date js--input-form js--input-disabled" 
  53.             value="{{ infoTypeEdit? infoTypeEdit.birthDate }}" 
  54.             {{ infoTypeEdit and infoTypeEdit.birthDate is not empty ? 'readonly' }} required>
  55.         </div>
  56.     {% endif %}
  57. </div>
  58. {# CONFIRMED #}
  59. <div id="wrap-analisis" class="cp-cols" data-status="hidden">
  60.     {# LOADING #}
  61.     {% if not infoTypeEdit %}
  62.         <div class="box-form-warning box-loading">
  63.             <p>{{ getLanguage('data_analysing_wait', 'receiver') }}&hellip;</p>
  64.             <i class="loader">{{ ico('loader-wish') }}</i>
  65.         </div>
  66.         <div class="box-form-warning box-response">
  67.             <p id="analyze_error_response">&hellip;</p>
  68.         </div>
  69.     {% endif %}
  70.     {# FULL NAME #}
  71.     <div id="name-type-person" class="cp cp-2">
  72.         <label for="{{ (infoType) ? 'partner-' }}receiver-name">
  73.             <span>{{ getLanguage('full_name', 'receiver') }}{{ req|raw }}</span>
  74.             <span>{{ getLanguage('company_name', 'receiver') }}{{ req|raw }}</span>
  75.             &emsp;
  76.         </label>
  77.         <input type="text" id="{{ (infoType) ? 'partner-' }}receiver-name" 
  78.         name="legalName{{ infoType }}" class="js--input-form js--input-disabled" 
  79.         placeholder="{{ getLanguage('receiver_name', 'receiver') }}" 
  80.         value="{{ infoTypeEdit? infoTypeEdit.legalName }}" 
  81.         {{ infoTypeEdit and infoTypeEdit.legalName is not empty ? 'readonly' }} required>
  82.     </div>
  83.     {% if ((infoTypeEdit and receiverEdit.personType == enum('ReceiverEnum::COMPANY')) and infoType is empty)
  84.     or ( not infoTypeEdit and infoType is empty ) %}
  85.         {# FANTASY NAME #}
  86.         <div id="trading-name-type-person" class="cp cp-2">
  87.             <label for="receiver-trading-name">{{ getLanguage('trading_name', 'receiver') }}{{ req|raw }}</label>
  88.             <input type="text" id="receiver-trading-name" 
  89.             name="tradingName" class="js--input-form" 
  90.             placeholder="{{ getLanguage('enter_the_trading_name', 'receiver') }}" 
  91.             value="{{ infoTypeEdit? infoTypeEdit.tradingName }}" required>
  92.         </div>
  93.     {% endif %}
  94.     {# EMAIL #}
  95.     <div id="email-type-person" class="cp cp-2">
  96.         <label for="{{ (infoType) ? 'partner-' }}receiver-email">E-mail{{ req|raw }}</label>
  97.         <input type="email" id="{{ (infoType) ? 'partner-' }}receiver-email" 
  98.         name="email{{ infoType }}" class="js--input-form" 
  99.         placeholder="{{ getLanguage('enter_the_email', 'receiver') }}" 
  100.         value="{{ infoTypeEdit? infoTypeEdit.email }}" data-rule-email required>
  101.     </div>
  102.     {# TELEPHONE #}
  103.     <div class="cp cp-3">
  104.         <label for="{{ (infoType) ? 'partner-' }}receiver-ddd-phone">{{ getLanguage('phone', 'receiver') }}{{ req|raw }}</label>
  105.         <input type="text" id="{{ (infoType) ? 'partner-' }}receiver-ddd" name="ddd{{ infoType }}" class="phone-ddd js--input-form" placeholder="14" value="{{ infoTypeEdit? infoTypeEdit.ddd }}" required>
  106.         <input type="text" id="{{ (infoType) ? 'partner-' }}receiver-phone" 
  107.         name="phone{{ infoType }}" class="phone-number js--input-form" 
  108.         placeholder="96123-4567" value="{{ infoTypeEdit? infoTypeEdit.phone }}" required>
  109.     </div>
  110.     {% if ((infoTypeEdit and receiverEdit.personType == enum('ReceiverEnum::PERSON')) or infoType is not empty)
  111.     or not infoTypeEdit %}
  112.         {# OCCUPATION #}
  113.         <div id="{{ (infoType) ? 'partner-' }}occupation-type-person" class="cp cp-3">
  114.             <label for="receiver-occupation">{{ getLanguage('occupation', 'receiver') }}{{ req|raw }}</label>
  115.             <input type="text" id="{{ (infoType) ? 'partner-' }}receiver-occupation" 
  116.             name="occupation{{ infoType }}" class="js--input-form" 
  117.             placeholder="{{ getLanguage('enter_the_occupation', 'receiver') }}" 
  118.             value="{{ infoTypeEdit? infoTypeEdit.occupation }}" required>
  119.         </div>
  120.         {# MONTHLY INCOME #}
  121.         <div id="{{ (infoType) ? 'partner-' }}monthly-income-type-person" class="cp cp-3">
  122.             <label for="{{ (infoType) ? 'partner-' }}receiver-monthly-income">{{ getLanguage('monthly_income', 'receiver') }}{{ req|raw }}</label>
  123.             <input type="text" id="{{ (infoType) ? 'partner-' }}receiver-monthly-income" 
  124.             name="monthlyIncome{{ infoType }}" class="js--input-form" 
  125.             placeholder="{{ getLanguage('enter_the_monthly_income', 'receiver') }}" 
  126.             value="{{ infoTypeEdit? infoTypeEdit.monthlyIncome }}" required>
  127.         </div>
  128.     {% endif %}
  129.     {% if ((infoTypeEdit and receiverEdit.personType == enum('ReceiverEnum::COMPANY')) and infoType is empty)
  130.     or ( not infoTypeEdit and infoType is empty ) %}
  131.         {# ANNUAL REVENUE #}
  132.         <div id="annual-revenue-type-person" class="cp cp-2">
  133.             <label for="receiver-annual-revenue">{{ getLanguage('annual_revenue', 'receiver') }}{{ req|raw }}</label>
  134.             <input type="text" id="receiver-annual-revenue" name="annualRevenue" 
  135.             class="js--input-form" placeholder="{{ getLanguage('enter_the_annual_revenue', 'receiver') }}" 
  136.             value="{{ infoTypeEdit? infoTypeEdit.annualRevenue }}" required>
  137.         </div>
  138.         {# WEBSITE #}
  139.         {% set getDomain = not infoTypeEdit or infoTypeEdit and infoTypeEdit.website is empty ? true : false %}
  140.         {% set www = getDomain ? "https://" : "" %}
  141.         {% set url = getDomain ? eadDomain : infoTypeEdit.website %}
  142.         <div id="website-type-person" class="cp cp-2">
  143.             <label for="receiver-website">Website{{ req|raw }}</label>
  144.             <input type="text" id="receiver-website" name="website" 
  145.             class="js--input-form" placeholder="{{ getLanguage('enter_the_website', 'receiver') }}" 
  146.             value="{{ www }}{{ url }}" required>
  147.         </div>
  148.     {% endif %}
  149. </div>