first commit

This commit is contained in:
2026-02-22 12:29:18 +05:00
commit d34447d322
40 changed files with 585 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
<h2>Список автомобилей</h2>
<a href="{% url 'add_auto' %}" class="btn btn-success mb-3">Добавить автомобиль</a>
<table class="table table-striped">
<thead>
<tr>
<th>Марка</th>
<th>Модель</th>
<th>Год</th>
<th>Цвет</th>
</tr>
</thead>
<tbody>
{% for auto in autos %}
<tr>
<td>{{ auto.brand }}</td>
<td>{{ auto.model }}</td>
<td>{{ auto.year }}</td>
<td>{{ auto.color|default:"—" }}</td>
</tr>
{% empty %}
<tr><td colspan="4">Автомобили пока не добавлены</td></tr>
{% endfor %}
</tbody>
</table>