107 lines
3.0 KiB
HTML
107 lines
3.0 KiB
HTML
{% extends "admin/change_form.html" %}
|
||
{% load i18n admin_urls static admin_modify fournée_modify %}
|
||
|
||
{% if save_on_top %}{% block submit_buttons_top %}{% fournée_submit_row %}{% endblock %}{% endif %}
|
||
|
||
{% block submit_buttons_bottom %}{% fournée_submit_row %}{% endblock %}
|
||
|
||
{% block after_field_sets %}
|
||
{% if commandes %}
|
||
<h2>Résumé des commandes</h2>
|
||
<ul>
|
||
{% for commande in commandes %}
|
||
<li>{{ commande }}</li>
|
||
{% endfor %}
|
||
</ul>
|
||
{% endif %}
|
||
{% endblock %}
|
||
|
||
{% block after_related_objects %}
|
||
{% if coulées %}
|
||
<h2>Résumé des coulées</h2>
|
||
<table>
|
||
<thead>
|
||
<tr>
|
||
<th></th>
|
||
{% for i in ingrédients %}
|
||
<th scope="col" style="text-align:center;{% if i.couleur != '#FFFFFF' %} background-color: {{ i.couleur }};{% endif %}">{{ i.nom }}</th>
|
||
{% endfor %}
|
||
</tr>
|
||
</thead>
|
||
<tbody>
|
||
<tr>
|
||
{% for p in totaux_coulées %}
|
||
{% if forloop.first %}
|
||
<th>Total pain : {{p}} kg</th>
|
||
{% else %}
|
||
<th scope="col" style="text-align:center">{{ p }}</th>
|
||
{% endif %}
|
||
{% endfor %}
|
||
</tr>
|
||
</tbody>
|
||
</table>
|
||
<div style="display:inline-grid">
|
||
{% for problems, ingrédients, quantités in coulées %}
|
||
<h3 style="margin-top: 2em;{% if problems %} color: var(--delete-button-hover-bg);{% endif %}">{{ quantités.0 }}{% if problems %} ({{ problems }}){% endif %}</h3>
|
||
<table>
|
||
<thead>
|
||
<tr>
|
||
<th></th>
|
||
{% for i, c in ingrédients %}
|
||
<th scope="col" style="text-align:center;{% if c != '#FFFFFF' %} background-color: {{ c }};{% endif %}">{{ i }}</th>
|
||
{% endfor %}
|
||
</tr>
|
||
</thead>
|
||
<tbody>
|
||
<tr>
|
||
{% for q in quantités %}
|
||
{% if forloop.first %}
|
||
<th scope="row">{{ q.pâte.nom }}</th>
|
||
{% else %}
|
||
<td style="text-align:center">{{ q }}</td>
|
||
{% endif %}
|
||
{% endfor %}
|
||
</tr>
|
||
</tbody>
|
||
</table>
|
||
{% endfor %}
|
||
</div>
|
||
{% endif %}
|
||
{% if divisions %}
|
||
<hr>
|
||
<h2>Résumé des divisions</h2>
|
||
<table>
|
||
<thead>
|
||
<tr>
|
||
<th></th>
|
||
{% for problems, p in pains %}
|
||
<th scope="col" style="text-align:center{% if problems %}; color: var(--delete-button-hover-bg);{% endif %}">{{ p }}{% if problems %}<br>Sans coulée !!{% endif %}</th>
|
||
{% endfor %}
|
||
</tr>
|
||
</thead>
|
||
<tr>
|
||
{% for p in totaux_divisions %}
|
||
{% if forloop.first %}
|
||
<th>Total pain : {{p}} kg</th>
|
||
{% else %}
|
||
<th scope="col" style="text-align:center">{{ p }}</th>
|
||
{% endif %}
|
||
{% endfor %}
|
||
</tr>
|
||
<tbody>
|
||
<tr></tr>
|
||
{% for commande in divisions %}
|
||
<tr>
|
||
{% for p in commande %}
|
||
{% if forloop.first %}<th scope="row">{% else %}<td style="text-align:center">{% endif %}
|
||
{{ p }}
|
||
{% if forloop.first %}</th>{% else %}</td>{% endif %}
|
||
{% endfor %}
|
||
</tr>
|
||
{% endfor %}
|
||
</tbody>
|
||
</table>
|
||
<p></p>
|
||
{% endif %}
|
||
{% endblock %}
|