templates/elements/pharmacy/_show_pharmacy.html.twig line 1

Open in your IDE?
  1. {% set pharmacy = app.request.session.get('cart_pharmacy') %}
  2. {% if pharmacy is not null %}
  3.     {#    Tablette and pc size #}
  4.     <div class="d-none d-lg-block bg-primary-light py-2">
  5.         <div class="container pt-3">
  6.             <div class="row">
  7.                 <div class="col-sm-12 col-lg-8">
  8.                     <div class="d-flex align-items-center">
  9.                         <img src="{{ pharmacy.logoImage }}" alt="{{ pharmacy.id }}" class="img-fluid me-2"
  10.                              style="width: 50px; object-fit: contain">
  11.                         <div>
  12.                             <h4 class="m-0">
  13.                                 <a target="_blank"
  14.                                    href="{{ "https://pharmonline.ch/fr/pharmacies/" ~ pharmacy.id ~ "-" ~ pharmacy.name | slug }}">
  15.                                     {{ pharmacy.name }}
  16.                                 </a>
  17.                             </h4>
  18.                             <p class="m-0">{{ pharmacy.addressFull }}</p>
  19.                             <a class="text-primary fw-bold" href="{{ path('choose_pharmacy') }}">{{ "Changer de pharmacie" | trans }}</a>
  20.                         </div>
  21.                         <div class="ms-2">
  22.                             <button class="btn btn-outline-info" data-add-favorite="{{ pharmacy.id }}">
  23.                                 <i class="{{ (pharmacy.id | isPharmacyFavorite) ? "fa fa-heart text-primary" : "fa fa-heart-o" }}"
  24.                                    style="font-size: 20px" id="favorite-icon"></i>
  25.                             </button>
  26.                         </div>
  27.                     </div>
  28.                 </div>
  29.                 <div class="col-sm-12 col-lg-4 text-end">
  30.                     <div>
  31.                         Contact: <a href={{ "tel:+41" ~ pharmacy.phone | replace({' ': ''}) }}>{{ pharmacy.phone }}</a>
  32.                     </div>
  33.                     <div>
  34.                         Email: <a href={{ "mailto:" ~ pharmacy.email }}>{{ pharmacy.email }}</a>
  35.                     </div>
  36.                     <div class="dropdown">
  37.                         <a class="btn btn-outline-muted dropdown-toggle" href="#" role="button" id="dropdownMenuLink"
  38.                            data-bs-toggle="dropdown" aria-expanded="false">
  39.                             {{ "Horaire d'ouverture" | trans }}
  40.                         </a>
  41.                         <ul class="dropdown-menu p-2 shadow shadow-md dropdown-menu-end"
  42.                             aria-labelledby="dropdownMenuLink"
  43.                             style="z-index: 9999; min-width: 300px">
  44.                             {{ include('elements/pharmacy/_pharmacy_hours.html.twig', {pharmacy: pharmacy}) }}
  45.                         </ul>
  46.                     </div>
  47.                 </div>
  48.             </div>
  49.         </div>
  50.     </div>
  51.     {#    Mobile responsive #}
  52.     <div class="d-block d-lg-none bg-primary-light py-2">
  53.         <div class="container pt-3">
  54.             <div class="row">
  55.                 <div class="col-sm-12">
  56.                     <div class="d-flex justify-content-between">
  57.                         <img src="{{ pharmacy.logoImage }}" alt="{{ pharmacy.id }}" class="img-fluid me-2"
  58.                              style="width: 70px; object-fit: contain">
  59.                         <div class="dropdown">
  60.                             <a class="btn btn-outline-muted dropdown-toggle" href="#" role="button"
  61.                                id="dropdownMenuLink"
  62.                                data-bs-toggle="dropdown" aria-expanded="false">
  63.                                 {{ "Horaire d'ouverture" | trans }}
  64.                             </a>
  65.                             <ul class="dropdown-menu p-2 shadow shadow-md dropdown-menu-end"
  66.                                 aria-labelledby="dropdownMenuLink"
  67.                                 style="z-index: 9999; min-width: 300px">
  68.                                 {{ include('elements/pharmacy/_pharmacy_hours.html.twig', {pharmacy: pharmacy}) }}
  69.                             </ul>
  70.                         </div>
  71.                     </div>
  72.                     <div class="d-flex justify-content-between">
  73.                         <div>
  74.                             <h4 class="m-0">
  75.                                 {{ pharmacy.name }}
  76. {#                                <a target="_blank"#}
  77. {#                                   href="{{ "https://pharmonline.ch/fr/pharmacies/" ~ pharmacy.id ~ "-" ~ pharmacy.name | slug }}">#}
  78. {#                                    #}
  79. {#                                </a>#}
  80.                             </h4>
  81.                             <p class="m-0">{{ pharmacy.addressFull }}</p>
  82.                         </div>
  83.                         <div class="ms-2">
  84.                             <button class="btn btn-outline-info" data-add-favorite="{{ pharmacy.id }}">
  85.                                 <i class="{{ (pharmacy.id | isPharmacyFavorite) ? "fa fa-heart text-primary" : "fa fa-heart-o" }}"
  86.                                    style="font-size: 20px" id="favorite-icon"></i>
  87.                             </button>
  88.                         </div>
  89.                     </div>
  90.                     <div class="d-flex justify-content-between mt-1" style="font-size: 11px">
  91.                         <div>
  92.                             Contact: <a
  93.                                     href={{ "tel:+41" ~ pharmacy.phone | replace({' ': ''}) }}>{{ pharmacy.phone }}</a>
  94.                         </div>
  95.                         <div>
  96.                             Email: <a href={{ "mailto:" ~ pharmacy.email }}>{{ pharmacy.email }}</a>
  97.                         </div>
  98.                     </div>
  99.                     <a class="btn btn-primary w-100 btn-sm mt-3"
  100.                        href="{{ path('choose_pharmacy') }}">{{ "Changer de pharmacie" | trans }}</a>
  101.                 </div>
  102.             </div>
  103.         </div>
  104.     </div>
  105. {% endif %}