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