Files
octopus/myproject/templates/home.html

51 lines
2.2 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{% extends 'base.html' %}
{% block title %}Вход{% endblock %}
{% block content %}
<div class="container d-flex align-items-center justify-content-center" style="min-height: 70vh;">
<div class="card shadow-sm" style="max-width: 420px; width: 100%;">
<div class="card-body p-4">
<!-- Заголовок -->
<div class="text-center mb-4">
<h3 class="fw-bold mb-2">Добро пожаловать</h3>
<p class="text-muted mb-0">Войдите в систему</p>
</div>
<!-- Сообщения об ошибках -->
{% if messages %}
{% for message in messages %}
{% if 'danger' in message.tags or 'error' in message.tags %}
<div class="alert alert-danger alert-dismissible fade show" role="alert">
{{ message }}
<button type="button" class="btn-close" data-bs-dismiss="alert"></button>
</div>
{% endif %}
{% endfor %}
{% endif %}
<!-- Форма входа -->
<form method="post" action="{% url 'accounts:login' %}">
{% csrf_token %}
<div class="mb-3">
<label for="email" class="form-label">Email</label>
<input type="email" class="form-control" id="email" name="email" required autofocus>
</div>
<div class="mb-3">
<label for="password" class="form-label">Пароль</label>
<input type="password" class="form-control" id="password" name="password" required>
</div>
<button type="submit" class="btn btn-primary w-100 py-2 mb-3">Войти</button>
<!-- Ссылка "Забыли пароль?" -->
<div class="text-center">
<a href="{% url 'accounts:password_reset' %}" class="text-decoration-none text-muted">
<small>Забыли пароль?</small>
</a>
</div>
</form>
</div>
</div>
</div>
{% endblock %}