caisse-bliss/app/Resources/views/product/index.html.twig

46 lines
1.3 KiB
Twig
Executable File

{% extends 'base.html.twig' %}
{% block body %}
<h1>Products list</h1>
<table>
<thead>
<tr>
<th>Id</th>
<th>Name</th>
<th>Image</th>
<th>Price</th>
<th>Comment</th>
<th>Actions</th>
</tr>
</thead>
<tbody>
{% for product in products %}
<tr>
<td><a href="{{ path('product_show', { 'id': product.id }) }}">{{ product.id }}</a></td>
<td>{{ product.name }}</td>
<td>{{ product.image }}</td>
<td>{{ product.price }}</td>
<td>{{ product.comment }}</td>
<td>
<ul>
<li>
<a href="{{ path('product_show', { 'id': product.id }) }}">show</a>
</li>
<li>
<a href="{{ path('product_edit', { 'id': product.id }) }}">edit</a>
</li>
</ul>
</td>
</tr>
{% endfor %}
</tbody>
</table>
<ul>
<li>
<a href="{{ path('product_new') }}">Create a new product</a>
</li>
</ul>
{% endblock %}