templates/product/index.html.twig line 1

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% block title %}Nos produits - Le Boutique Belge{% endblock %}
  3. {% block content %}
  4.     <h1>Nos produits</h1>
  5.     <div class="row product-container">         
  6.         {% for product in products %}
  7.             <div class="col-md-4">
  8.                 <div class="product-item text-center">
  9.                     <a href="{{ path('produit', { 'slug' : product.slug } ) }}"><img src="/uploads/{{ product.illustration }}" alt="{{ product.name }}" class="img-fluid"></a>
  10.                     <h5>{{ product.name }}</h5>
  11.                     <span class="product-subtitle">{{ product.subtitle }}</span>
  12.                     <span class="product-price">{{ (product.price / 100) | number_format(2, ',', '.') }}</span>
  13.                     <p class="mt-2">
  14.                         <div class="text-center">
  15.                             <a href="{{ path('add_to_wishlist', { 'id': product.id}) }}" class="btn btn-outline-warning">
  16.                                 <i class="fas fa-heart"></i>
  17.                             </a>
  18.                             <a href="{{ path('add_to_cart', { 'id': product.id}) }}" class="btn btn-outline-primary">
  19.                                 <i class="fas fa-cart-plus"></i>
  20.                             </a>
  21.                         </div>
  22.                     </p>
  23.                 </div>                                
  24.             </div>   
  25.         {% endfor %}
  26.     </div>
  27. {% endblock %}