2021-04-29 20:51:13 +01:00
|
|
|
{% extends 'stdgrid.html.twig' %}
|
2020-07-23 23:48:49 +01:00
|
|
|
|
|
|
|
{% block stylesheets %}
|
2020-07-28 17:08:08 +01:00
|
|
|
{{ parent() }}
|
2021-04-29 23:47:42 +01:00
|
|
|
<link rel='stylesheet' type='text/css' href="{{ asset('assets/css/security/security.css') }}">
|
2020-07-23 23:48:49 +01:00
|
|
|
{% endblock %}
|
2020-07-22 02:58:25 +01:00
|
|
|
|
2021-08-11 18:42:15 +01:00
|
|
|
{% block title %}{{ "Log in!" | trans }}{% endblock %}
|
2020-07-22 02:58:25 +01:00
|
|
|
|
2020-10-19 23:45:48 +01:00
|
|
|
{% block body %}
|
2021-09-15 00:25:16 +01:00
|
|
|
<section class="section-widget">
|
|
|
|
<form class="section-form" method="post">
|
|
|
|
<fieldset>
|
|
|
|
<legend class="section-form-legend">{{ "Login" | trans }}</legend>
|
|
|
|
|
|
|
|
{% if error %}
|
2021-09-15 14:47:29 +01:00
|
|
|
<label class="alert alert-danger">
|
|
|
|
{{ error.getMessage() }}
|
|
|
|
</label>
|
2021-09-15 00:25:16 +01:00
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
{% if app.user %}
|
2021-12-27 19:04:30 +00:00
|
|
|
<h2>
|
2021-09-15 00:25:16 +01:00
|
|
|
{{ "You are logged in as" | trans }} {{ app.user.username }}.
|
|
|
|
<button class="btn btn-lg btn-primary">
|
|
|
|
<a href="{{ path('app_logout') }}">{{ "Logout" | trans }}</a>
|
|
|
|
</button>
|
2021-12-27 19:04:30 +00:00
|
|
|
</h2>
|
2021-09-15 00:25:16 +01:00
|
|
|
{% else %}
|
2021-12-27 19:04:30 +00:00
|
|
|
<div class="form-row">
|
2021-11-16 14:48:18 +00:00
|
|
|
<label class="section-form-label" for="inputNicknameOrEmail">{{ "Nickname or Email" | trans }}</label>
|
2021-11-16 14:48:18 +00:00
|
|
|
<input type="text" value="{{ last_login_id }}" name="_username" id="inputNicknameOrEmail" class="form-control" required autofocus>
|
2021-10-10 17:41:30 +01:00
|
|
|
<p class="help-text">{{ "Your nickname or email address." | trans }}</p>
|
2021-09-15 00:25:16 +01:00
|
|
|
</div>
|
2021-12-27 19:04:30 +00:00
|
|
|
<div class="form-row">
|
2021-09-15 00:25:16 +01:00
|
|
|
<label class="section-form-label" for="inputPassword">{{ "Password" | trans }}</label>
|
2021-11-16 14:48:18 +00:00
|
|
|
<input type="password" name="_password" id="inputPassword" class="form-control" required>
|
2021-09-15 00:25:16 +01:00
|
|
|
<p class="help-text">{{ "Your account's password." | trans }}</p>
|
|
|
|
</div>
|
|
|
|
|
2021-12-27 19:04:30 +00:00
|
|
|
<span class="form-row-checkbox">
|
2021-11-16 14:48:18 +00:00
|
|
|
<label for="inputRememberMe">{{ "Remember me" | trans }}</label>
|
|
|
|
<input type="checkbox" name="_remember_me" id="inputRememberMe">
|
2021-09-15 00:25:16 +01:00
|
|
|
</span>
|
|
|
|
|
2021-11-16 14:48:18 +00:00
|
|
|
<input type="hidden" name="_csrf_token" value="{{ csrf_token('authenticate') }}">
|
2021-09-15 00:25:16 +01:00
|
|
|
<div>
|
|
|
|
<button class="btn btn-lg btn-primary" type="submit">Sign in</button>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
{% endif %}
|
|
|
|
</fieldset>
|
|
|
|
</form>
|
|
|
|
</section>
|
2020-10-19 23:22:31 +01:00
|
|
|
{% endblock body %}
|
2020-10-19 23:45:48 +01:00
|
|
|
|
|
|
|
{% block javascripts %}{% endblock %}
|