КОНТРОЛЫ/users.md


Исходный код

Twig код

{% for key, field in items %}
  <div class="widget_settings_block__input_field">
    <div class='widget_settings_block_{{ elem }}'>
      <div class='widget_settings_block_{{ elem }}__title_field widget_settings_block__title_field'>{{ field.username }}</div>
      
      {% if type == 'users_lp' %}
        {% include "interface/controls/input.twig" with {
          placeholder: lang.sip_user,
          class_name: class_name ~ ' widget_settings_block__controls__' ~ elem,
          value: value[key].login,
          name: field.name ~ '[login]',
          id: 'login_' ~ field.id,
          type: field.type
        } %}

        {% include "interface/controls/input.twig" with {
          placeholder: lang.password,
          class_name: class_name ~ ' widget_settings_block__controls__' ~ elem,
          value: value[key].password,
          name: field.name ~ '[password]',
          id: 'password_' ~ field.id,
          type: 'password'
        } %}
      {% elseif type == 'users' %}
        {% include "interface/controls/input.twig" with {
          class_name: class_name ~ 'widget_settings_block__controls__' ~ elem,
          value: value[key],
          name: field.name,
          id: field.id,
          type: type,
          placeholder: field.title
        } %}
      {% endif %}
    </div>
  </div>
{% endfor %}

Ссылка на вики репозиторий