Initial commit: Django inventory system

This commit is contained in:
2025-10-22 01:11:06 +03:00
commit d78c43d9a9
93 changed files with 9204 additions and 0 deletions

View File

@@ -0,0 +1,41 @@
{% extends 'base.html' %}
{% block title %}Регистрация{% endblock %}
{% block content %}
<div class="container">
<div class="form-container">
<h2 class="text-center mb-4">Регистрация</h2>
<div class="tab-content">
<div class="tab-pane fade show active" id="register">
<form method="post" action="{% url 'accounts:register' %}">
{% csrf_token %}
<div class="mb-3">
<label for="{{ form.name.id_for_label }}" class="form-label">Имя</label>
{{ form.name }}
{% if form.name.errors %}
<div class="text-danger">{{ form.name.errors }}</div>
{% endif %}
</div>
<div class="mb-3">
<label for="{{ form.email.id_for_label }}" class="form-label">Email</label>
{{ form.email }}
{% if form.email.errors %}
<div class="text-danger">{{ form.email.errors }}</div>
{% endif %}
</div>
{% include 'accounts/password_input.html' with field_name=form.password1.id_for_label field_label='Пароль' required=True field_errors=form.password1.errors %}
{% include 'accounts/password_input.html' with field_name=form.password2.id_for_label field_label='Подтверждение пароля' required=True field_errors=form.password2.errors %}
<button type="submit" class="btn btn-primary w-100">Зарегистрироваться</button>
</form>
<!-- Ссылка на вход -->
<div class="text-center mt-3">
<a href="{% url 'accounts:login' %}" class="text-decoration-none">Уже есть аккаунт? Войти</a>
</div>
</div>
</div>
</div>
</div>
{% endblock %}