{% extends 'layout/user_base.html.twig' %}{% set translated = product|translate %}{% set promotion = product.inPromotion %}{% set showCustomMetadescription = (translated.metaDescription is not null or translated.metaDescription != "") %}{% set showCustomMetakeyword= (translated.metaKeyword is not null or translated.metaKeyword != "") %}{% block meta %} <meta name="description" content="{{ showCustomMetadescription ? translated.metaDescription : appText.meta.HEADER_DESCRIPTION[app.request.locale] }}"> <meta name="keyword" content="{{ showCustomMetakeyword ? translated.metaKeyword : appText.meta.HEADER_KEYWORD[app.request.locale] }}">{% endblock %}{% block title %} {{ translated.name ~ " - " ~ translated.brand.name }}{% endblock %}{% block body %} <div class="container mt-5"> <div class="row"> {# <div class="col-lg-0"> #} {# {{ render(controller('App\\Controller\\App\\WidgetController::onlineShopFilter', {linkMode: true})) }} #} {# </div> #} <div class="col-lg-12"> <nav class="mb-3"> <ol class="breadcrumb mb-0"> {% for category in categories %} <li class="breadcrumb-item"> <a href="{{ path('app_shop', { categories: [category.id]|json_encode, "brands": [], "min": 1.00, "max": 100.00 }) }}" class="text-dark">{{ category.name }}</a> </li> {% endfor %} </ol> </nav> </div> <div class="col-lg-12 mt-4 mt-lg-0"> <div class="products-list main"> <div class="row"> <section class="bg-white shadow-sm"> <div class=""> <div class="row"> <aside class="col-lg-5"> <article class="gallery-wrap"> <div class="img-big-wrap img-thumbnail position-relative" style="height: auto"> {# Brand crumb arborescence #} <img src="{{ vich_uploader_asset(translated) }}" class="img-fluid product-image" alt="{{ product.name }}" > {% if promotion %} {% set promotionValue = calculPromotionPercent(product) %} {% if promotionValue > 0 %} <div class="product-promotion"> - {{ promotionValue }}% </div> {% endif %} {% endif %} </div> </article> <div> {{ render(controller('App\\Controller\\App\\WidgetController::giftsProduct', {product: product.id})) }} </div> </aside> <div class="col-lg-7"> <article class="ps-lg-3"> <h4 class="title text-dark position-relative"> {{ translated.name }} </h4> <div class="text-muted"> <p>{{ "Marque:" | trans }} {{ product.brand.name }} / {{ "Pharmacode:" | trans }} {{ product.pharmacode }}</p> </div> <div class="mb-3 d-flex"> {% if promotion %} <h3 class="price h4 text-primary2">CHF <span id="product_promotion_price" data-promotion="{{ calculPromotionPercent(product) }}">{{ (product.price - product.pricePromotion) | number_format(2) }}</span> </h3> <h3 class="price h4 text-decoration-line-through ps-4"> CHF <span id="product_price">{{ product.price | number_format(2) }}</span> </h3> {% else %} <h3 class="price h4"> CHF <span id="product_price">{{ product.price | number_format(2) }}</span> </h3> {% endif %} </div> <hr> <div class="row g-2 mt-3"> <div class="col-lg-12"> <div class="d-flex align-items-center"> <span class="rounded-circle text-primary" style="width: 30px"> <i class="fa fa-check-circle"></i> </span> <p class="title m-0 fw-bolder">{{ "Click and collect" | trans }}</p> </div> </div> <div class="col-lg-12"> <div class="d-flex align-items-center"> <span class="rounded-circle text-primary" style="width: 30px"> <i class="fa fa-shipping-fast"></i> </span> <div class="pe-lg-4"> <p class="title m-0 fw-bolder">{{ "Approvisionnement rapide" | trans }}</p> </div> </div> </div> <div class="col-lg-12"> {{ include('elements/pagesElements/products/_product_stock.html.twig', {product: product}) }} </div> </div> <div class="row mt-4 align-items-center"> {# <div class="col-sm-12 col-lg-5"> #} {# <label for="" class="fw-bold">{{ "VARIETE" | trans }}: </label> #} {# <select name="" id="product_attribute_list" #} {# class="form-select rounded-pill"> #} {# <option disabled selected>{{ "Choix variété" | trans }}</option> #} {# {% for title, terms in attributs %} #} {# <option disabled>{{ title }}</option> #} {# {% for term in terms %} #} {# <option value="{{ term['id'] }}" #} {# data-attribut-id="{{ term['id'] }}" #} {# data-price="{{ term['price'] ? term['price'] | number_format(2) : product.price | number_format(2) }}" #} {# data-product="{{ product.id }}" #} {# > #} {# {{ term['term'] }} #} {# </option> #} {# {% endfor %} #} {# {% endfor %} #} {# </select> #} {# </div> #} <div class="col-sm-12 col-lg-3 mt-3 mt-lg-0"> <label for="" class="fw-bold">{{ "QUANTITE" | trans }}: </label> <div class="d-flex align-items-center py-1"> <div class="qt-item" data-qt-down data-product="{{ product.id }}"> <i class="fas fa-minus"></i> </div> <div class="qt-count" style="user-select: none">1</div> <div class="qt-item" data-qt-up data-product="{{ product.id }}"> <i class="fas fa-plus"></i> </div> </div> </div> <div class="col-sm-12 col-lg-4 mt-3 mt-lg-0"> {{ include('elements/pagesElements/products/_product_add_cart_btn.html.twig', {small: false, product: product, disabled: product.stock < 1}) }} </div> </div> {% set produtPrestations = product.productsPrestations %} {% if produtPrestations|length > 0 %} <hr> <h6>{{ "Listes des prestations associé" | trans }}</h6> <div class="row mt-3 g-3"> {% for service in produtPrestations %} <div class="col-4 col-lg-4 text-center product_prestations_item cursor-pointer" data-icon="{{ service.prestation.icon }}" data-title="{{ service.prestation.name }}" data-description="{{ service.prestation.description }}" > <img src="{{ service.prestation.icon }}" alt="{{ service.prestation.id }}" height="32"> <p class="m-0">{{ service.prestation.name }}</p> </div> {% endfor %} </div> {% endif %} </article> {# Service lié à afficher #} </div> </div> </div> </section> </div> </div> {{ include('elements/pagesElements/products/_products_detail_information.html.twig') }} {{ include('elements/pagesElements/products/_products_buyed_with.html.twig') }} {{ include('elements/pagesElements/products/_products_detail_recommanded.html.twig') }} </div> </div> </div> {{ include('elements/pagesElements/products/_product_modal_prestation.html.twig') }}{% endblock %}{% block javascripts %} {{ parent() }} {{ encore_entry_script_tags('online_shop') }}{% endblock %}