Docs: начальная структура проекта
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
30
app/templates/references/reference_list.html
Normal file
30
app/templates/references/reference_list.html
Normal file
@@ -0,0 +1,30 @@
|
||||
{% extends "base.html" %}
|
||||
{% block title %}{{ title }} — ERP WaterSurf{% endblock %}
|
||||
{% block content %}
|
||||
<h2>{{ title }}</h2>
|
||||
<p><a href="{% url create_url_name %}" class="btn btn-primary">Добавить</a></p>
|
||||
<table class="table table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>#</th>
|
||||
{% block table_headers %}<th>Название</th>{% endblock %}
|
||||
<th></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for item in items %}
|
||||
<tr>
|
||||
<td>{{ item.pk }}</td>
|
||||
{% block table_cells %}<td>{{ item }}</td>{% endblock %}
|
||||
<td>
|
||||
<a href="{% block edit_url %}{% url update_url_name item.pk %}{% endblock %}">Изменить</a>
|
||||
|
|
||||
<a href="{% block delete_url %}{% url delete_url_name item.pk %}{% endblock %}" class="text-danger">Удалить</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% empty %}
|
||||
<tr><td colspan="3">Нет записей.</td></tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user