{% extends 'base.html.twig' %}
{% block title %}Nos produits{% endblock %}
{% block body %}
<!-- Navbar Start -->
<div class="container-fluid position-relative p-0">
<div class="container-fluid bg-primary py-5 bg-header" style="margin-bottom: 90px;">
<div class="row py-5">
<div class="col-12 pt-lg-5 mt-lg-5 text-center">
<h1 class="display-4 text-white animated zoomIn">Notre Boutique</h1>
<a href="{{ path('home') }}" class="h5 text-white">Accueil</a>
<i class="far fa-circle text-white px-2"></i>
<a href="" class="h5 text-white">Boutique</a>
</div>
</div>
</div>
</div>
<!-- Navbar End -->
<!-- Shop Start -->
<div class="container-fluid pt-5">
<div class="row px-xl-5">
<!-- Shop Sidebar Start -->
<div class="col-lg-3 col-md-12">
{{ form(form) }}
</div>
<!-- Shop Product Start -->
<div class="col-lg-9 col-md-12">
<div class="row pb-3">
<div class="col-12 pb-1">
<div class="d-flex align-items-center justify-content-between mb-4">
<form action="">
<div class="input-group">
<input type="text" class="form-control" placeholder="Search by name">
<div class="input-group-append">
<span class="input-group-text bg-transparent text-primary">
<i class="fa fa-search"></i>
</span>
</div>
</div>
</form>
</div>
</div>
{% for product in products %}
<div class="col-lg-4 col-md-6 col-sm-12 pb-1">
<div class="card product-item border-0 mb-4">
<div class="card-header product-img position-relative overflow-hidden bg-transparent border p-0">
<img class="img-fluid w-100" src="/uploads/{{product.image}}" alt="{{product.name}}" alt="">
</div>
<div class="card-body border-left border-right text-center p-0 pt-4 pb-3">
<h6 class="text-truncate mb-3">{{ product.name}}</h6>
<span class="product-subtitle text-center">{{product.subtitle}}</span>
<div class="d-flex justify-content-center">
<h6>{{(product.price / 100 )|number_format(2,',', '.')}} FCFA </h6>
</div>
</div>
<div class="card-footer d-flex justify-content-between bg-light border">
<a href="{{ path('product_show', {slug: product.slug}) }}" class="btn btn-sm text-dark p-0"><i class="fas fa-eye text-primary mr-1"></i>Voir détails</a>
<a href="{{ path('add_to_cart', {id: product.id}) }}" class="btn btn-sm text-dark p-0"><i class="fas fa-shopping-cart text-primary mr-1"></i>Ajout panier</a>
</div>
</div>
</div>
{% endfor %}
<div class="col-12 pb-1">
<nav aria-label="Page navigation">
<ul class="pagination justify-content-center mb-3">
<li class="page-item disabled">
<a class="page-link" href="#" aria-label="Previous">
<span aria-hidden="true">«</span>
<span class="sr-only">Préc</span>
</a>
</li>
<li class="page-item active"><a class="page-link" href="#">1</a></li>
<li class="page-item"><a class="page-link" href="#">2</a></li>
<li class="page-item"><a class="page-link" href="#">3</a></li>
<li class="page-item">
<a class="page-link" href="#" aria-label="Next">
<span aria-hidden="true">»</span>
<span class="sr-only">Suiv</span>
</a>
</li>
</ul>
</nav>
</div>
</div>
</div>
<!-- Shop Product End -->
</div>
</div>
<!-- Shop End -->
{% endblock %}