2024-11-21 15:11:11 +01:00
|
|
|
{% extends 'base.html.twig' %}
|
|
|
|
|
|
|
|
{% block title %}Plats index{% endblock %}
|
|
|
|
{% block stylesheets %}
|
2024-11-21 17:03:32 +01:00
|
|
|
<link rel="stylesheet" href="{{ asset('css/ControllerVues/list.css') }}"> <!-- Ajout du fichier CSS -->
|
2024-11-21 15:11:11 +01:00
|
|
|
|
|
|
|
{% endblock %}
|
|
|
|
{% block body %}
|
|
|
|
<h1>Plats index</h1>
|
|
|
|
|
|
|
|
<table class="table">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
|
|
|
<th>Id</th>
|
|
|
|
<th>Nom</th>
|
|
|
|
<th>Description</th>
|
|
|
|
<th>Prix</th>
|
|
|
|
<th>Categorie</th>
|
|
|
|
<th>Statut</th>
|
|
|
|
<th>Nb_de_commande</th>
|
|
|
|
<th>actions</th>
|
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<tbody>
|
|
|
|
{% for plat in plats %}
|
|
|
|
<tr>
|
|
|
|
<td>{{ plat.id }}</td>
|
|
|
|
<td>{{ plat.Nom }}</td>
|
|
|
|
<td>{{ plat.Description }}</td>
|
|
|
|
<td>{{ plat.Prix }}</td>
|
|
|
|
<td>{{ plat.Categorie }}</td>
|
|
|
|
<td>{{ plat.Statut ? 'Yes' : 'No' }}</td>
|
|
|
|
<td>{{ plat.NbDeCommande }}</td>
|
|
|
|
<td>
|
|
|
|
<a href="{{ path('app_plats_edit', {'id': plat.id}) }}">edit</a>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
{% else %}
|
|
|
|
<tr>
|
|
|
|
<td colspan="8">pas de plats disponible</td>
|
|
|
|
</tr>
|
|
|
|
{% endfor %}
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
|
|
|
|
<a href="{{ path('app_plats_new') }}">Créer un nouveaux plat</a>
|
|
|
|
{% endblock %}
|