Files
specs/app/templates/specifications/list.html
2026-10-07 19:57:07 +00:00

66 lines
2.2 KiB
HTML
Raw Permalink 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="page-header">
<h1>Спецификации</h1>
<nav aria-label="breadcrumb">
<ol class="breadcrumb">
<li class="breadcrumb-item"><a href="{{ url_for('home') }}">Главная</a></li>
<li class="breadcrumb-item active">Спецификации</li>
</ol>
</nav>
</div>
{% if project_id %}
<div class="alert alert-info">
Фильтр: Проект #{{ project_id }}
<a href="{{ url_for('specifications_list') }}" class="btn btn-sm btn-link">Показать все</a>
</div>
{% endif %}
<div class="section-title">Список спецификаций</div>
<div class="table-responsive">
<table class="table table-striped">
<thead>
<tr>
<th>Номер</th>
<th>Дата</th>
<th>Договор</th>
<th>Проект</th>
<th>Позиций</th>
<th>Действие</th>
</tr>
</thead>
<tbody>
{% for spec in specifications %}
<tr>
<td><a href="{{ url_for('specification_detail', specification_id=spec.id) }}">{{ spec.specification_number }}</a></td>
<td>{{ spec.specification_date.strftime('%Y-%m-%d') if spec.specification_date else 'N/A' }}</td>
<td>{{ spec.contract.contract_number if spec.contract else 'N/A' }}</td>
<td>{{ spec.project.name if spec.project else 'N/A' }}</td>
<td>{{ spec.specification_items|length }}</td>
<td>
<a href="{{ url_for('specification_detail', specification_id=spec.id) }}" class="btn btn-sm btn-primary">
Открыть
</a>
</td>
</tr>
{% else %}
<tr>
<td colspan="6" class="text-center">Нет спецификаций</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<div class="mt-4">
<a href="{{ url_for('projects_list') }}" class="btn btn-secondary">
К проектам
</a>
</div>
{% endblock %}