templates/areas/loginbox/view.html.twig line 1

Open in your IDE?
  1. {% extends 'areas/loginbox/editables.html.twig' %}
  2. {% block view %}
  3.   <div class="c-loginbox {% if componentMargin is defined %}{{componentMargin}}{% endif %}">
  4.       {% for error in app.flashes(['error_auth']) %}
  5.                 {% if error is defined and error is not empty %}
  6.                 <div class="c-login__alert">{{ error[0].messageKey|trans(error[0].messageData, 'security') }}</div> 
  7.                 {% endif %}
  8.         {% endfor %}
  9.     {% if editmode %}
  10.       Only in Frontend
  11.      {% elseif not editmode and app.user is not null %}
  12.       <div class="c-wysiwyg e-rte spacing-component-padding-none-left-right spacing-component-padding-none-top-bottom spacing-component-margin-bottom-none background-none">
  13.         <h2 style="text-align:center">Sie sind bereits eingeloggt.</h2>
  14.           <p class="e-large" style="text-align:center">
  15.             <p style="text-align:center">
  16.               <a class="e-button" href="/de/portal/logout">Logout</a>
  17.             </p>
  18.           </p>
  19.       </div>
  20.       {% else %}
  21.       <div class="c-wysiwyg e-rte spacing-component-padding-none-left-right spacing-component-padding-none-top-bottom spacing-component-margin-bottom-none background-none"><h2>Login</h2></div><br>
  22.       <form action="{{ path('mvk_login') }}" method="post">
  23.         <label for="username">{{'mvk_doc_fe_Loginbox_username' | trans }}</label>
  24.         <input type="text" id="username" name="_username" value="{% if lastUsername %}{{ lastUsername }}{% endif %}" required>
  25.         <label for="password">{{'mvk_doc_fe_Loginbox_password' | trans }}</label>
  26.         <input type="password" id="password" name="_password">
  27.         <div class="check-wrapper">
  28.           <input type="checkbox" id="remember" name="_remember_me">
  29.           <label for="remember">{{'mvk_doc_fe_Loginbox_stay_logged_in' | trans }}</label>
  30.         </div>
  31.         {# If you want to control the URL the user is redirected to on success
  32.         <input type="hidden" name="_target_path" value="/account"> #}
  33.         <input type="hidden" name="_csrf_token" value="{{ csrf_token('authenticate') }}">
  34.         <button type="submit">{{'mvk_doc_fe_Loginbox_button' | trans }}</button>
  35.         
  36.       </form>
  37.     {% endif %}
  38.   </div>
  39. {% endblock %}