59 lines
2.9 KiB
HTML
59 lines
2.9 KiB
HTML
{% extends "base.html" %}
|
||
|
||
{% block title %}КС-3 проекта {{ project.name }}{% endblock %}
|
||
|
||
{% block content %}
|
||
<div class="container mt-4">
|
||
<nav class="mb-3">
|
||
<a href="/projects/{{ project.id }}" class="btn btn-outline-secondary btn-sm">← К проекту</a>
|
||
</nav>
|
||
|
||
<div class="row">
|
||
<div class="col-12">
|
||
<h2>КС-3 проекта {{ project.name }}</h2>
|
||
<a href="/projects/{{ project.id }}/ks3/new" class="btn btn-primary mb-3">Создать КС-3</a>
|
||
|
||
<div class="table-responsive">
|
||
<table class="table table-striped">
|
||
<thead>
|
||
<tr>
|
||
<th>Номер</th>
|
||
<th>Дата</th>
|
||
<th>Период</th>
|
||
<th>Статус</th>
|
||
<th>КС-2</th>
|
||
<th class="text-end text-nowrap">Сумма</th>
|
||
<th>Действия</th>
|
||
</tr>
|
||
</thead>
|
||
<tbody>
|
||
{% for row in rows %}
|
||
<tr class="clickable-row" data-url="/projects/{{ project.id }}/ks3/{{ row.document.id }}">
|
||
<td>{{ row.document.number }}</td>
|
||
<td>{{ row.document.date.strftime('%d.%m.%Y') }}</td>
|
||
<td>{% if row.document.reporting_period_from and row.document.reporting_period_to %}{{ row.document.reporting_period_from.strftime('%d.%m.%Y') }} — {{ row.document.reporting_period_to.strftime('%d.%m.%Y') }}{% endif %}</td>
|
||
<td>
|
||
{% if row.document.status == 'cancelled' %}
|
||
<span class="badge bg-danger">Сторнирован</span>
|
||
{% elif row.document.status == 'issued' %}
|
||
<span class="badge bg-success">Проведён</span>
|
||
{% else %}
|
||
<span class="badge bg-secondary">Черновик</span>
|
||
{% endif %}
|
||
</td>
|
||
<td>{{ row.ks2_count }}</td>
|
||
<td class="text-end text-nowrap money-value">{{ row.amount | money }}</td>
|
||
<td>
|
||
<a href="/projects/{{ project.id }}/ks3/{{ row.document.id }}" class="btn btn-sm btn-outline-primary">Просмотр</a>
|
||
</td>
|
||
</tr>
|
||
{% else %}
|
||
<tr><td colspan="7" class="text-center text-muted py-4">КС-3 пока нет.</td></tr>
|
||
{% endfor %}
|
||
</tbody>
|
||
</table>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
{% endblock %} |