templates/home/index.html.twig line 1

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% block title %}Meilleur Agence de voyages en Tunisie - Rustica Voyages{% endblock %}
  3. {% block stylesheets %}
  4.     <link rel="stylesheet" type="text/css" href="{{ asset('front/style/single_listing_style.css') }}">
  5.     <link rel="stylesheet" type="text/css" href="{{ asset('front/style/single_listing_responsive.css') }}">
  6.     <link rel="stylesheet" type="text/css" href="{{ asset('front/style/blog_style.css') }}">
  7.     <link rel="stylesheet" type="text/css" href="{{ asset('front/style/blog_responsive.css') }}">
  8.     <link href="{{ asset('front/searchbar/vendor/mdi-font/css/material-design-iconic-font.min.css') }}" rel="stylesheet" media="all">
  9.     <link href="{{ asset('front/searchbar/vendor/font-awesome-4.7/css/font-awesome.min.css') }}" rel="stylesheet" media="all">
  10.     <!-- Font special for pages-->
  11.     <link href="https://fonts.googleapis.com/css?family=Roboto:100,100i,300,300i,400,400i,500,500i,700,700i,900,900i" rel="stylesheet">
  12.     <!-- Vendor CSS-->
  13.     <link href="{{ asset('front/searchbar/vendor/select2/select2.min.css') }}" rel="stylesheet" media="all">
  14.     <link href="{{ asset('front/searchbar/vendor/datepicker/daterangepicker.css') }}" rel="stylesheet" media="all">
  15.     <!-- Main CSS-->
  16.     <link href="{{ asset('front/searchbar/css/main.css') }}" rel="stylesheet" media="all">
  17.     <!-- Modal Css -->
  18.     <link rel="stylesheet" href="{{ asset('front/modals/fonts/icomoon/stylecommons.css') }}">
  19.     <!-- Bootstrap CSS -->
  20.     <link rel="stylesheet" href="{{ asset('front/modals/css/bootstrapcss.min.css') }}">
  21.     <link rel="stylesheet" type="text/css" href="{{ asset('front/plugins/OwlCarousel2-2.2.1/owl.carousel.css') }}">
  22.     <link rel="stylesheet" type="text/css" href="{{ asset('front/plugins/OwlCarousel2-2.2.1/owl.theme.default.css') }}">
  23.     <link rel="stylesheet" type="text/css" href="{{ asset('front/plugins/OwlCarousel2-2.2.1/animate.css') }}">
  24.         <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/assets/owl.carousel.min.css">
  25.     
  26.     <!-- Style -->
  27.     {#    <link rel="stylesheet" href="{{ asset('front/modals/css/stylemodals.css') }}">#}
  28.         <style>
  29.         .owl-theme .owl-dots {
  30.             text-align: center;
  31.             -webkit-tap-highlight-color: transparent;
  32.             display: none;
  33.         }
  34.         .owl-theme .owl-nav {
  35.             margin-top: 10px;
  36.             text-align: center;
  37.             -webkit-tap-highlight-color: transparent;
  38.             z-index: 10000;
  39.             background: red;
  40.             display: none;
  41.         }
  42.         .cta {
  43.             padding-top: 190px;
  44.             padding-bottom: 183px;
  45.             background: linear-gradient(to right, #b29b63, #0093a9);
  46.         }
  47.         .search_tab.active {
  48.             background: linear-gradient(to right, #b29b63, #0093a9);
  49.             color: #FFFFFF;
  50.         }
  51.         .search_tab:hover {
  52.             background: linear-gradient(to right, #0093a9, #b29b63);
  53.             color: #FFFFFF;
  54.         }
  55.         .content {
  56.             max-height: 3em; /* Limite initiale de hauteur en fonction du nombre de lignes */
  57.             overflow: hidden;
  58.         }
  59.         .expanded {
  60.             max-height: none; /* Agrandir la hauteur lorsque le paragraphe est étendu */
  61.         }
  62.         .read-more {
  63.             cursor: pointer;
  64.             color: blue;
  65.         }
  66.         .home_slider_background {
  67.             height: 80;
  68.             width: 100%;
  69.             background-size: cover;
  70.             background-position: center center;
  71.             background-repeat: no-repeat;
  72.             margin-top:40px;
  73.         }
  74.         .offers_price {
  75.             display: inline-block;
  76.             font-size: 29px;
  77.             font-weight: 700;
  78.             color: #ff9100;
  79.             line-height: 25px;
  80.         }
  81.         .offers_price a{
  82.             display: inline-block;
  83.             font-size: 22px;
  84.             font-weight: 700;
  85.             color: #0093a9;
  86.             line-height: 25px;
  87.         }
  88.         .offer_name{
  89.             display: block;
  90.             font-size: 22px;
  91.             font-weight: 700;
  92.             background: #0093a9;
  93.             color: #FFFFFF;
  94.             width: 310px;
  95.             line-height: 35px;
  96.             padding-left: 12px;
  97.         }
  98.         .offers_item {
  99.             border-radius: 12px;
  100.             overflow: hidden;
  101.             position: relative;
  102.             box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12), 0 1px 2px rgba(0, 0, 0, 0.24);
  103.             transition: all 300ms;
  104.         }
  105.         .offers_item:hover {
  106.             transform: translateY(-2px);
  107.             box-shadow: 0 14px 28px rgba(0, 0, 0, 0.25), 0 10px 10px rgba(0, 0, 0, 0.22);
  108.         }
  109.         .offers_image_background {
  110.             position: relative;
  111.             margin: auto;
  112.             overflow: hidden;
  113.         }
  114.         .offers_image_background img {
  115.             max-width: 100%;
  116.             transition: all 0.3s;
  117.             display: block;
  118.             transform: scale(1);
  119.         }
  120.         .offers_image_background:hover img {
  121.             transform: scale(1.1);
  122.         }
  123.         .offers_content {
  124.             margin-top: 22px;
  125.             margin-left: 17px;
  126.             margin-bottom: 22px;
  127.             margin-right: 17px;
  128.         }
  129.         .offers_link {
  130.             margin-top: 24px;
  131.         }
  132.          .intro_price {
  133.              font-size: 20px;
  134.              font-weight: 600;
  135.              color: #FFFFFF;
  136.              margin-top: -4px;
  137.          }
  138.          
  139.          .intro{
  140.             padding-bottom: 50px;
  141.          }
  142.         .button a:hover {
  143.             background-color: #ff9100;
  144.             color: white;
  145.         }
  146.         .ctaBackground {
  147.             position: absolute;
  148.             top: 0;
  149.             left: 0;
  150.             width: 100%;
  151.             height: 210%;
  152.             background-repeat: no-repeat;
  153.             background-size: cover;
  154.             background-position: center center;
  155.             opacity: 0.27;
  156.         }
  157.         img {
  158.             max-width: 100%;
  159.             height: 100%;
  160.         }
  161.         .container {
  162.             max-width: 1440px!important;
  163.         }
  164.         .main_nav_item a {
  165.             font-family: 'Open Sans', sans-serif;
  166.             font-size: 15px;
  167.             font-weight: 700;
  168.             color: #0093a9!important;
  169.             text-transform: uppercase;
  170.             padding-bottom: 10px;
  171.             padding-top: 10px;
  172.         }
  173.         .main_nav_item::after {
  174.             display: block;
  175.             position: absolute;
  176.             left: -1px;
  177.             bottom: -11px;
  178.             width: calc(100% + 2px);
  179.             height: 2px;
  180.             background: linear-gradient(to right, #b29b63, #0093a9)!important;
  181.             content: '';
  182.             opacity: 0;
  183.             -webkit-transition: all 200ms ease;
  184.             -moz-transition: all 200ms ease;
  185.             -ms-transition: all 200ms ease;
  186.             -o-transition: all 200ms ease;
  187.             transition: all 200ms ease;
  188.         }
  189.         .section-title h2 {
  190.             text-align: center;
  191.             font-size: 18px;
  192.             font-weight: 600;
  193.             text-transform: uppercase;
  194.             padding-bottom: 6px;
  195.             color: #000;
  196.             letter-spacing: 0.3px;
  197.             padding: 0;
  198.         }
  199.         .section-title::after {
  200.             content: "";
  201.             height: 3px;
  202.             background: #fbb900;
  203.             width: 80px;
  204.             position: absolute;
  205.             left: 0;
  206.             right: 0;
  207.             margin: auto;
  208.         }
  209.         /****************/
  210.         /*     BX-SLIDER     */
  211.         /****************/
  212.        /* section.client {
  213.             padding:4em 0em;
  214.         }*/
  215.         section.client .section-title {
  216.             margin-bottom: 6em;
  217.         }
  218.         .bx-controls {
  219.             position: relative;
  220.         }
  221.         .bx-wrapper{
  222.             margin: auto;
  223.             margin-top: 70px;
  224.         }
  225.         .bx-wrapper .bx-pager {
  226.             text-align: center;
  227.             padding-top: 30px;
  228.             display: none;
  229.         }
  230.         .bx-wrapper .bx-pager .bx-pager-item, .bx-wrapper .bx-controls-auto .bx-controls-auto-item {
  231.             display: inline-block;
  232.             *zoom: 1;
  233.             *display: inline;
  234.         }
  235.         .bx-wrapper .bx-pager.bx-default-pager a {
  236.             background: #666;
  237.             text-indent: -9999px;
  238.             display: block;
  239.             width: 10px;
  240.             height: 10px;
  241.             margin: 0 5px;
  242.             outline: 0;
  243.             -moz-border-radius: 5px;
  244.             -webkit-border-radius: 5px;
  245.             border-radius: 5px;
  246.         }
  247.         
  248.         /**/
  249.         
  250.                /* Default styles */
  251.         .filter {
  252.             background: #f3f6f9;
  253.             margin-top: -24px;
  254.         }
  255.         .container {
  256.             padding: 0 15px;
  257.             margin: 0 auto;
  258.         }
  259.         .card {
  260.             border: none;
  261.             background: transparent;
  262.             width: 100%;
  263.            /* max-width: 1070px;*/
  264.             margin: 0 auto;
  265.         }
  266.         .card-body {
  267.             margin-top: 25px;
  268.         }
  269.         .input-group {
  270.             width: calc(25% - 20px);
  271.             max-width: 200px;
  272.             margin-bottom: 10px;
  273.         }
  274.         .label {
  275.             color: black;
  276.             font-weight: 500;
  277.             display: block;
  278.         }
  279.         .btn-submit {
  280.             font-size: 16px;
  281.             font-weight: 500;
  282.             border: 1px solid black;
  283.             background: #FFFFFF;
  284.             color: black;
  285.             margin-bottom: 10px;
  286.             max-width:335px;
  287.         }
  288.         /* Media Queries */
  289.         @media screen and (max-width: 768px) {
  290.             .input-group {
  291.                 width: 100%;
  292.                 max-width: none;
  293.             }
  294.                 .home_slider_container{
  295.                 display:none;
  296.             }
  297.             .cta{
  298.             display:none;
  299.             }
  300.             .filter{margin-top:-140px;}
  301.             .offers{padding-top:55px;}
  302.             .intro{padding-top:55px;}
  303.             .section_title{font-size:20px !important;}
  304.             .offers_items {
  305.                 margin-top: 30px;
  306.             }
  307.             .intro_col
  308.             {
  309.                 min-width: 395px;
  310.                 margin-left: -45px;
  311.             }
  312.             .banniere
  313.             {
  314.                 width:100%;
  315.                 height:50%!important;
  316.             }
  317.         }
  318.         .home_slider_container {
  319.     position: absolute;
  320.     top: 0;
  321.     left: 0;
  322.     width: 100%;
  323.     height: 100%;
  324.     z-index: 10;
  325.     background: #ffffff;
  326. }
  327. .home_slider_background{
  328.     opacity: unset
  329. }
  330.     </style>
  331. {% endblock %}
  332. {% block body %}
  333.     <div class="home" style="height: 100px;">
  334.     </div>
  335.     <!-- Blog -->
  336.     <div class="cta">
  337.         <div class="home_slider_container" style="height: 132%">
  338.             {# <div class="owl-carousel owl-theme home_slider">
  339.                 {% for b in banniere%}
  340.                 <div class="owl-item home_slider_item">
  341.                     <div class="home_slider_background">
  342.                         {% for img in b.imagesbannieres %}
  343.                                 <img class="banniere" src="{{ asset('./rusticav/public/uploads/bannieres/'~img.name) }}" alt="" width="100%" height="74%" />
  344.                         {% endfor %}
  345.                     </div>
  346.                 </div>
  347.                 {% endfor %}
  348.             </div> #}
  349.             <div class="owl-carousel owl-theme home_slider">
  350.             {% for b in banniere%}
  351.             <div class="owl-carousel owl-theme home_slider">
  352.                 <div class="home_slider_background">
  353.                     {% for img in b.imagesbannieres %}
  354.                     <img class="banniere" src="{{ asset('./rusticav/public/uploads/bannieres/'~img.name) }}" alt="" width="100%" height="74%" />
  355.                     {% endfor %}
  356.                 </div>
  357.             </div>
  358.             {% endfor %}
  359.         </div>
  360.             <!-- Home Slider Nav - Prev -->
  361.             <div class="home_slider_nav home_slider_prev">
  362.                 <svg version="1.1" id="Layer_2" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
  363.                      width="28px" height="33px" viewBox="0 0 28 33" enable-background="new 0 0 28 33" xml:space="preserve">
  364.                     <defs>
  365.                         <linearGradient id='home_grad_prev'>
  366.                             <stop offset='0%' stop-color='#fa9e1b'/>
  367.                             <stop offset='100%' stop-color='#8d4fff'/>
  368.                         </linearGradient>
  369.                     </defs>
  370.                     <path class="nav_path" fill="#F3F6F9" d="M19,0H9C4.029,0,0,4.029,0,9v15c0,4.971,4.029,9,9,9h10c4.97,0,9-4.029,9-9V9C28,4.029,23.97,0,19,0z
  371.                     M26,23.091C26,27.459,22.545,31,18.285,31H9.714C5.454,31,2,27.459,2,23.091V9.909C2,5.541,5.454,2,9.714,2h8.571
  372.                     C22.545,2,26,5.541,26,9.909V23.091z"/>
  373.                     <polygon class="nav_arrow" fill="#F3F6F9" points="15.044,22.222 16.377,20.888 12.374,16.885 16.377,12.882 15.044,11.55 9.708,16.885 11.04,18.219
  374.                     11.042,18.219 "/>
  375.                 </svg>
  376.             </div>
  377.             <!-- Home Slider Nav - Next -->
  378.             <div class="home_slider_nav home_slider_next">
  379.                 <svg version="1.1" id="Layer_3" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
  380.                      width="28px" height="33px" viewBox="0 0 28 33" enable-background="new 0 0 28 33" xml:space="preserve">
  381.                     <defs>
  382.                         <linearGradient id='home_grad_next'>
  383.                             <stop offset='0%' stop-color='#fa9e1b'/>
  384.                             <stop offset='100%' stop-color='#8d4fff'/>
  385.                         </linearGradient>
  386.                     </defs>
  387.                     <path class="nav_path" fill="#F3F6F9" d="M19,0H9C4.029,0,0,4.029,0,9v15c0,4.971,4.029,9,9,9h10c4.97,0,9-4.029,9-9V9C28,4.029,23.97,0,19,0z
  388.                 M26,23.091C26,27.459,22.545,31,18.285,31H9.714C5.454,31,2,27.459,2,23.091V9.909C2,5.541,5.454,2,9.714,2h8.571
  389.                 C22.545,2,26,5.541,26,9.909V23.091z"/>
  390.                     <polygon class="nav_arrow" fill="#F3F6F9" points="13.044,11.551 11.71,12.885 15.714,16.888 11.71,20.891 13.044,22.224 18.379,16.888 17.048,15.554
  391.                 17.046,15.554 "/>
  392.                 </svg>
  393.             </div>
  394.             <!-- Home Slider Dots -->
  395.             <div class="home_slider_dots">
  396.                 <ul id="home_slider_custom_dots" class="home_slider_custom_dots">
  397.                     <li class="home_slider_custom_dot active"><div></div>01.</li>
  398.                     <li class="home_slider_custom_dot"><div></div>02.</li>
  399.                     <li class="home_slider_custom_dot"><div></div>03.</li>
  400.                 </ul>
  401.             </div>
  402.         </div>
  403.     </div>
  404.     <!-- Inclure jQuery (nécessaire pour Owl Carousel) -->
  405. <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
  406. <!-- Inclure le fichier JavaScript de Owl Carousel -->
  407. <script src="https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/owl.carousel.min.js"></script>
  408. <script>
  409.     $(document).ready(function(){
  410.         // Initialisez le carrousel avec Owl Carousel
  411.         $('.home_slider').owlCarousel({
  412.             loop: true,
  413.             items: 1,
  414.             autoplay: true,
  415.             autoplayTimeout: 5000, // Durée entre chaque diapositive en millisecondes (5 secondes)
  416.             autoplayHoverPause: true, // Mettre en pause le carrousel lorsque survolé
  417.             nav: true, // Activer les flèches de navigation
  418.             dots: true // Activer les points de navigation
  419.         });
  420.         // Écoutez l'événement 'changed.owl.carousel' pour détecter le changement de diapositive
  421.         $('.home_slider').on('changed.owl.carousel', function(event) {
  422.             var currentSlide = event.item.index;
  423.             var slideCount = event.item.count;
  424.             if (currentSlide === slideCount - 1) {
  425.                 // Si c'est la dernière diapositive, retournez à la première diapositive
  426.                 $('.home_slider').trigger('to.owl.carousel', [0, 500]);
  427.             }
  428.         });
  429.     });
  430. </script>
  431. </div>
  432.     <br><br><br><br><br><br>
  433.         <div class="filter">
  434.         <div class="container">
  435.             <div class="card card-7">
  436.                 <div class="card-body">
  437.                     {{ form_start(form,{'attr':{'class':'search_panel_content d-flex flex-wrap align-items-center justify-content-between'}}) }}
  438.                     <div class="input-group">
  439.                         <label class="label">Destination</label>
  440.                         {{ form_widget(form.ville,{'attr':{'class':'input--style-1','style':'font-size:15px;width:100%;border:none'}}) }}
  441.                     </div>
  442.                     <div class="input-group">
  443.                         <label class="label">Départ</label>
  444.                         {{ form_widget(form.dateDepart,{'attr':{'class':'input--style-1'}}) }}
  445.                     </div>
  446.                     <div class="input-group">
  447.                         <label class="label">Arrivé</label>
  448.                         {{ form_widget(form.dateArrive,{'attr':{'class':'input--style-1'}}) }}
  449.                     </div>
  450.                     <div class="input-group">
  451.                         <label class="label">Nuitée</label>
  452.                         {{ form_widget(form.nombreNuits,{'attr':{'class':'input--style-1'}}) }}
  453.                     </div>
  454.                     <button type="button" class="btn-submit" data-toggle="modal" data-target="#roomModal">
  455.                         Ajouter une chambre
  456.                     </button>
  457.                     <!-- Modal -->
  458.                                 <div class="modal fade" id="roomModal" tabindex="-1" role="dialog" aria-labelledby="roomModalLabel" aria-hidden="true">
  459.                                     <span class="modal-dialog modal-dialog-centered" role="document">
  460.                                         <span class="modal-content rounded-0">
  461.                                             <span class="modal-content" style="width: 85%;margin-top: 131px;margin-left:30px;">
  462.                                                 <span class="modal-body bg-3">
  463.                                                     <div class="modal-header" style="border-bottom: none">
  464.                                                         <h5 class="modal-title" id="roomModalLabel" style="color: #0093a9;font-size: 22px;margin-left: -30px;font-weight: 700">Chambre et Occupation</h5>
  465.                                                         <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  466.                                                             <span aria-hidden="true">&times;</span>
  467.                                                         </button>
  468.                                                     </div>
  469.                                                     <ul class="rooms" data-prototype="{{ form_widget(form.rooms.vars.prototype, {'attr': {'style': 'display:contents;color:black;font-size:18px'}})|e }}">
  470.                                                         <div style="display: contents">
  471.                                                             {% for roomForm in form.rooms %}
  472.                                                                 <li class="row room-item">
  473.                                                                     <span>
  474.                                                                         <label class="input--style-1" style="color: black">Adultes</label>
  475.                                                                         {{ form_widget(roomForm.nbadultes, {'attr': {'class': 'input--style-1', 'style': 'border:1px solid black'}}) }}
  476.                                                                     </span>
  477.                                                                     <span style="margin-right: 10px;"></span>
  478.                                                                     <span>
  479.                                                                         <label class="input--style-1" style="color: black">Enfants</label>
  480.                                                                         {{ form_widget(roomForm.nbfnfants, {'attr': {'class': 'input--style-1', 'style': 'border:1px solid black'}}) }}
  481.                                                                     </span>
  482.                                                                 </li>
  483.                                                             {% endfor %}
  484.                                                         </div>
  485.                                                     </ul>
  486.                                                     <div class="modal-footer">
  487.                                                         <button type="button" class="btn btn-primary" id="saveButtonModal" style="color: #FFFFFF;background:#ff9100 ">Valider</button>
  488.                                                     </div>
  489.                                                 </span>
  490.                                             </span>
  491.                                         </span>
  492.                                     </span>
  493.                                 </div>
  494.                     <button class="btn-submit" type="submit">Voir disponibilité</button>
  495.                     {{ form_end(form) }}
  496.                 </div>
  497.             </div>
  498.         </div>
  499.     </div>
  500.     <!-- Offers -->
  501.     <div class="offers">
  502.         <div class="container">
  503.             <div class="row">
  504.                 <div class="col text-center">
  505.                     <h2 class="section_title">Nos Meilleurs Hôtels en Tunisie</h2>
  506.                 </div>
  507.             </div>
  508.             <div class="row offers_items">
  509.                 {% for h in hotel |slice(0, 4) %}
  510.                     <!-- Offers Item -->
  511.                     <div class="col-lg-6 offers_col">
  512.                         <div class="offers_item">
  513.                             <div class="row">
  514.                                 <div class="col-lg-6">
  515.                                     <div class="offers_image_container">
  516.                                         <div class="offers_image_background" >
  517.                                             {% for img in h.imageshotels %}
  518.                                                 {% if loop.first %}
  519.                                                     <img src="{{ asset('./rusticav/public/uploads/hotels/'~img.name) }}" alt="" width="100%" height="100%" />
  520.                                                 {% endif %}
  521.                                             {% endfor %}
  522.                                         </div>
  523.                                         <div class="offer_name">{{ h.name }}
  524.                                         </div>
  525.                                     </div>
  526.                                 </div>
  527.                                 <div class="col-lg-6">
  528.                                     <div class="offers_content">
  529.                                         <div class="offers_price">
  530.                                             {% set totalprix = 0 %}
  531.                                             {% if h.hotelrooms is defined and h.hotelrooms|length > 0 %}
  532.                                                 {% set firstHotelRoom = h.hotelrooms[0] %}
  533.                                                 {% if firstHotelRoom.pricerooms is defined and firstHotelRoom.pricerooms|length > 0 %}
  534.                                                     {% set firstPriceRoom = firstHotelRoom.pricerooms[0] %}
  535.                                                     {% if firstPriceRoom.price is defined %}
  536.                                                         {% set totalprix = totalprix + firstPriceRoom.price %}
  537.                                                     {% endif %}
  538.                                                 {% endif %}
  539.                                             {% endif %}
  540.                                             {% if h.hotelarrangements is defined and h.hotelarrangements|length > 0 %}
  541.                                                 {% set firstHotelArrangements = h.hotelarrangements[0] %}
  542.                                                 {% if firstHotelArrangements.pricearrangements is defined and firstHotelArrangements.pricearrangements|length > 0 %}
  543.                                                     {% set firstPriceArrangements = firstHotelArrangements.pricearrangements[0] %}
  544.                                                     {% if firstPriceArrangements.price is defined %}
  545.                                                         {% set totalprix = totalprix + firstPriceArrangements.price %}
  546.                                                     {% endif %}
  547.                                                 {% endif %}
  548.                                             {% endif %}
  549.                                             <span style="margin-left: 0px">A partir de:</span> {{ totalprix }} TND
  550.                                         </div>
  551.                                         <div class="rating_r rating_r_4 offers_rating" style="color:#b29b63">
  552.                                             {% for i in 1..h.star %}
  553.                                                 <img src="{{asset('front/images/etoil.png')}}" class="" alt="...">
  554.                                             {% endfor %}
  555.                                         </div>
  556.                                         <style>
  557.                                             .full-paragraph {
  558.                                                 display: none;
  559.                                             }
  560.                                             .short-paragraph {
  561.                                                 display: block;
  562.                                             }
  563.                                         </style>
  564.                                         <div class="offer">
  565.                                             <p class="short-paragraph"style="color: black">{{ h.shortdesc|striptags|slice(0, 100) }}{% if h.shortdesc|length > 100 %}...{% endif %}</p>
  566.                                             <p class="full-paragraph" style="display: none;color: black">{{ h.shortdesc|raw }}</p>
  567.                                             <a href="#" class="read-more-link" onclick="toggleParagraph(this); return false;">Suite</a>
  568.                                         </div>
  569.                                         <script>
  570.                                             function toggleParagraph(link) {
  571.                                                 var offer = link.closest('.offer');
  572.                                                 var shortParagraph = offer.querySelector('.short-paragraph');
  573.                                                 var fullParagraph = offer.querySelector('.full-paragraph');
  574.                                                 if (shortParagraph.style.display === 'none') {
  575.                                                     shortParagraph.style.display = 'block';
  576.                                                     fullParagraph.style.display = 'none';
  577.                                                     link.innerText = 'Suite';
  578.                                                 } else {
  579.                                                     shortParagraph.style.display = 'none';
  580.                                                     fullParagraph.style.display = 'block';
  581.                                                     link.innerText = 'Moins';
  582.                                                 }
  583.                                             }
  584.                                         </script>
  585.                                         <div class="offers_icons">
  586.                                             <ul class="offers_icons_list">
  587.                                                 <li class="offers_icons_item"><img src="{{ asset('front/images/post.png') }}" alt=""></li>
  588.                                                 <li class="offers_icons_item"><img src="{{ asset('front/images/compass.png') }}" alt=""></li>
  589.                                                 <li class="offers_icons_item"><img src="{{ asset('front/images/bicycle.png') }}" alt=""></li>
  590.                                                 <li class="offers_icons_item"><img src="{{ asset('front/images/sailboat.png') }}" alt=""></li>
  591.                                             </ul>
  592.                                         </div>
  593.                                         <div class="offers_link"><a href="{{ path('detailhotel',{'id':h.id}) }}" class="btn btn-primary" style="color: #FFFFFF;background: #ff9100;border: none">Voir Détails</a></div>
  594.                                     </div>
  595.                                 </div>
  596.                             </div>
  597.                         </div>
  598.                     </div>
  599.                 {% endfor %}
  600.             </div>
  601.         </div>
  602.     </div>
  603.     <div class="cta">
  604.         <!-- Image by https://unsplash.com/@thanni -->
  605.         <div class="cta_background" style="background-image:url(./front/images/Slider_3.png);opacity: unset ; background-size: cover;background-position: center;width: 100%;"></div>
  606.         <div class="container">
  607.             <div class="row">
  608.                 <div class="col">
  609.                 </div>
  610.             </div>
  611.         </div>
  612.     </div>
  613.     <!-- Intro -->
  614.     
  615.     <div class="intro">
  616.         <div class="container">
  617.             <div class="row">
  618.                 <div class="col text-center">
  619.                     <h2 class="section_title" style="font-size: 33px;color: #0093a9">Croisière</h2>
  620.                 </div>
  621.             </div>
  622.             <div class="intro">
  623.                 <div class="container mt-4">
  624.                     <div class="row intro_items" style="margin-top: -100px; margin-left:20px;">
  625.                         {% for c in croisiere|slice(0, 3) %}
  626.                             <div class="col-lg-4 intro_col">
  627.                                 <div class="intro_item" style="width: 90%;height: 400px;box-shadow: 0 16px 38px -12px rgba(0, 0, 0, 0.56), 0 4px 25px 0px rgba(0, 0, 0, 0.12), 0 8px 10px -5px rgba(0, 0, 0, 0.2);">
  628.                                     <div class="intro_item_overlay" style="background: #301c405c"></div>
  629.                                     <div class="intro_item_background">
  630.                                         {% for img in c.imagescroisieres %}
  631.                                             {% if loop.first %}
  632.                                                 <img src="{{ asset('./rusticav/public/uploads/croisieres/'~img.name) }}" alt="" width="100%" height="100%" />
  633.                                             {% endif %}
  634.                                         {% endfor %}
  635.                                     </div>
  636.                                     <div class="intro_item_content d-flex flex-column align-items-center justify-content-center" style="margin-top: 60px;">
  637.                                         <div class="button intro_button" style="margin-bottom: -5px;">
  638.                                             <div class="button_bcg" style="background: #0093a9;"></div>
  639.                                             <a href="{{ path('details', {'croisiereId': c.id}) }}" style="font-size: 14px">
  640.                                                 Voir plus<span></span><span></span><span></span>
  641.                                             </a>
  642.                                         </div>
  643.                                         <div class="intro_center text-center">
  644.                                             <a href="{{ path('details', {'croisiereId': c.id}) }}" style="color:#000;font-size: 23px"><h1 style="font-size: 34px;text-transform: uppercase">{{c.name}}</h1></a>
  645.                                         </div>
  646.                                     </div>
  647.                                 </div>
  648.                             </div>
  649.                         {% endfor %}
  650.                     </div>
  651.                 </div>
  652.                 <div class="text-right mt-4" style="margin-right: 79px;">
  653.                     <a href="{{path('app_croisiere')}}" style="color: #0093a9">
  654.                         Découvrir Nos Croisières <i class="fa fa-angle-double-right"></i>
  655.                     </a>
  656.                 </div>
  657.             </div>
  658.         </div>
  659.         <!-- CTA -->
  660.         <div class="cta">
  661.             <!-- Image by https://unsplash.com/@thanni -->
  662.             <div class="cta_background" style="background-image:url(./front/images/Slider_1.png);opacity: unset; background-size: cover;background-position: center;width: 100%;"></div>
  663.             <div class="container">
  664.                 <div class="row">
  665.                     <div class="col">
  666.                     </div>
  667.                 </div>
  668.             </div>
  669.         </div>
  670.         <!-- Intro -->
  671.         <div class="intro">
  672.             <div class="container">
  673.                 <div class="row">
  674.                     <div class="col text-center">
  675.                         <h2 class="section_title" style="font-size: 33px;color: #0093a9">Voyages Organisés</h2>
  676.                     </div>
  677.                 </div>
  678.                 <div class="intro">
  679.                     <div class="container mt-4">
  680.                         <div class="row intro_items" style="margin-top: -62px; margin-left:20px;">
  681.                             {% for s in sejour|slice(0, 3) %}
  682.                                 <div class="col-lg-4 intro_col">
  683.                                     <div class="intro_item" style="width: 90%;height: 400px;box-shadow: 0 16px 38px -12px rgba(0, 0, 0, 0.56), 0 4px 25px 0px rgba(0, 0, 0, 0.12), 0 8px 10px -5px rgba(0, 0, 0, 0.2);">
  684.                                         <div class="intro_item_overlay" style="background: #301c405c"></div>
  685.                                         <div class="intro_item_background">
  686.                                             {% for img in s.imageSejours %}
  687.                                                 {% if loop.first %}
  688.                                                     <img src="{{ asset('./rusticav/public/uploads/sejours/'~img.name) }}" alt="" width="100%" height="100%" />
  689.                                                 {% endif %}
  690.                                             {% endfor %}
  691.                                         </div>
  692.                                         <div class="intro_item_content d-flex flex-column align-items-center justify-content-center" style="margin-top: 60px;">
  693.                                             <div class="intro_date" style="background-color:#ff9100; top: 74px;font-size: 12px;font-weight: 700"> {{s.dated|date("d-m-Y")}} Au {{s.datef|date("d-m-Y")}}</div>
  694.                                             <div class="button intro_button" style="margin-bottom: -5px;">
  695.                                                 <div class="button_bcg" style="background: #0093a9;"></div>
  696.                                                 <a href="{{ path('detailsejour', {'id': s.id}) }}" style="font-size: 14px">
  697.                                                     Voir plus<span></span><span></span><span></span>
  698.                                                 </a>
  699.                                             </div>
  700.                                             <div class="intro_center text-center">
  701.                                                 <a href="{{ path('detailsejour', {'id': s.id}) }}" style="color:#000;font-size: 23px"><h1 style="font-size: 34px;text-transform: uppercase">{{s.titre}}</h1></a>
  702.                                                 <div class="intro_price" style="font-weight: 600;font-size: 20px">À partir de <strong>{{s.prix + s.marge}} TND</strong> </div>
  703.                                             </div>
  704.                                         </div>
  705.                                     </div>
  706.                                 </div>
  707.                             {% endfor %}
  708.                         </div>
  709.                     </div>
  710.                     <div class="text-right mt-4" style="margin-right: 79px;">
  711.                         <a href="{{path('app_sejour')}}" style="color: #0093a9">
  712.                             Découvrir Nos Voyages Organisés <i class="fa fa-angle-double-right"></i>
  713.                         </a>
  714.                     </div>
  715.                 </div>
  716.             </div>
  717.             <!-- CTA -->
  718.             {# <div class="cta">
  719.                 <!-- Image by https://unsplash.com/@thanni -->
  720.                 <div class="cta_background" style="background-image:url(./front/images/Slider_2.png);opacity: unset; background-size: cover;background-position: center;width: 100%;height: 128%;margin-top: 0px;"></div>
  721.                 <div class="container">
  722.                     <div class="row">
  723.                         <div class="col">
  724.                         </div>
  725.                     </div>
  726.                 </div>
  727.             </div>
  728.             <div class="intro">
  729.                 <div class="container">
  730.                     <div class="row" style="margin-top:50px;">
  731.                         <div class="col text-center">
  732.                             <h2 class="section_title" style="font-size: 33px;color: #0093a9">Circuits & Excursions en Tunisie</h2>
  733.                         </div>
  734.                     </div>
  735.                     <div class="intro">
  736.                         <div class="container mt-4">
  737.                             <div class="row intro_items" style="margin-top: -62px; margin-left:20px;">
  738.                                 {% for c in circuit|slice(0, 3) %}
  739.                                     <div class="col-lg-4 intro_col">
  740.                                         <div class="intro_item" style="width: 90%;height: 400px;box-shadow: 0 16px 38px -12px rgba(0, 0, 0, 0.56), 0 4px 25px 0px rgba(0, 0, 0, 0.12), 0 8px 10px -5px rgba(0, 0, 0, 0.2);">
  741.                                             <div class="intro_item_overlay" style="background: #301c405c"></div>
  742.                                             <div class="intro_item_background">
  743.                                                 {% for img in c.imagescircuits %}
  744.                                                     {% if loop.first %}
  745.                                                         <img src="{{ asset('./rusticav/public/uploads/circuits/'~img.name) }}" alt="" width="100%" height="100%" />
  746.                                                     {% endif %}
  747.                                                 {% endfor %}
  748.                                             </div>
  749.                                             <div class="intro_item_content d-flex flex-column align-items-center justify-content-center" style="margin-top: 60px;">
  750.                                                 <div class="intro_date" style="background-color:#ff9100; top: 74px;font-size: 12px;font-weight: 700"> {{c.dated|date("d-m-Y")}} Au {{c.datef|date("d-m-Y")}}</div>
  751.                                                 <div class="button intro_button" style="margin-bottom: -5px;">
  752.                                                     <div class="button_bcg" style="background: #0093a9;"></div>
  753.                                                     <a href="{{ path('detailcircuit', {'id': c.id}) }}" style="font-size: 14px">
  754.                                                         Voir plus<span></span><span></span><span></span>
  755.                                                     </a>
  756.                                                 </div>
  757.                                                 <div class="intro_center text-center">
  758.                                                     <a href="{{ path('detailcircuit', {'id': c.id}) }}" style="color:#000;font-size: 23px"><h1 style="font-size: 34px;text-transform: uppercase">{{c.libelle}}</h1></a>
  759.                                                     <div class="intro_price" style="font-weight: 600;font-size: 20px">À partir de <strong>{{c.prix + c.marge}} TND</strong> </div>
  760.                                                 </div>
  761.                                             </div>
  762.                                         </div>
  763.                                     </div>
  764.                                 {% endfor %}
  765.                             </div>
  766.                         </div>
  767.                         <div class="text-right mt-4" style="margin-right: 79px;">
  768.                             <a href="{{path('app_circuit')}}" style="color: #0093a9">
  769.                                 Découvrir Nos Circuits <i class="fa fa-angle-double-right"></i>
  770.                             </a>
  771.                         </div>
  772.                     </div>
  773.                 </div>
  774.             </div> #}
  775.                 <section class="client">
  776.                     <div class="container">
  777.                         <div class="row">
  778.                             <div class="col text-center">
  779.                                 <h2 class="section_title" style="font-size: 33px;color: #0093a9">Nos Partenaires</h2>
  780.                             </div>
  781.                         </div>
  782.                         <div class="row">
  783.                             <div class="col text-center">
  784.                             <div class="carousel-client">
  785.                                 <div class="slide">
  786.                                     <img src="{{ asset('front/images/logo_starcroisieres.svg') }}" style="margin-top: 15px">
  787.                                 </div>
  788.                                 <div class="slide">
  789.                                     <img src="{{ asset('front/images/msc.webp') }}">
  790.                                 </div>
  791.                                 <div class="slide">
  792.                                     <img src="{{ asset('front/images/costa.webp') }}">
  793.                                 </div>
  794.                                 <div class="slide">
  795.                                     <img src="{{ asset('front/images/rccl.webp') }}">
  796.                                 </div>
  797.                                 <div class="slide">
  798.                                     <img src="{{ asset('front/images/ponant.webp') }}">
  799.                                 </div>
  800.                                 <div class="slide">
  801.                                     <img src="{{ asset('front/images/celestyal.webp') }}">
  802.                                 </div>
  803.                             </div>
  804.                             </div>
  805.                         </div>
  806.                     </div>
  807.                 </section>
  808.             {% block javascripts %}
  809.                 {{ parent() }}
  810.                 <script src="https://code.jquery.com/jquery-3.6.4.min.js"></script>
  811.                 <script>
  812.                     $(document).ready(function() {
  813.                         // Mettre à jour le champ "nombre de nuit" lorsqu'une date d'arrivée est saisie
  814.                         $('#{{ form.dateArrive.vars.id }}').change(function() {
  815.                             var datef = new Date($(this).val());
  816.                             var dated = new Date($('#{{ form.dateDepart.vars.id }}').val());
  817.                             if (!isNaN(datef.getTime()) && !isNaN(dated.getTime())) {
  818.                                 var diff = Math.ceil((datef - dated) / (1000 * 60 * 60 * 24));
  819.                                 $('#{{ form.nombreNuits.vars.id }}').val(diff);
  820.                             }
  821.                         });
  822.                     });
  823.                 </script>
  824.             {% endblock %}
  825.     <script>
  826.         $(document).ready(function () {
  827.             var $collectionHolder = $('ul.rooms');
  828.             $collectionHolder.data('index', $collectionHolder.find(':input').length);
  829.             $collectionHolder.find('li').each(function () {
  830.                 addRemoveButton($(this));
  831.             });
  832.             var $addRoomButton = $('<button type="button" class="add-room" style="color: #0093a9;margin-top: 19px;border: none">Ajouter une chambre</button>');
  833.             var $newLinkLi = $('<li class="row room-item"></li>').append($addRoomButton);
  834.             $collectionHolder.append($newLinkLi);
  835.             $addRoomButton.on('click', function (e) {
  836.                 addRoomForm($collectionHolder, $newLinkLi);
  837.             });
  838.             function addRoomForm($collectionHolder, $newLinkLi) {
  839.                 var prototype = $collectionHolder.data('prototype');
  840.                 var index = $collectionHolder.data('index');
  841.                 var newForm = prototype;
  842.                 newForm = newForm.replace(/__name__/g, index);
  843.                 $collectionHolder.data('index', index + 1);
  844.                 var $newFormLi = $('<li class="row room-item"></li>').append(newForm);
  845.                 $newFormLi.find('input').each(function () {
  846.                     var $input = $(this);
  847.                     var name = $input.attr('name');
  848.                     var $select = createDropdown(name);
  849.                     $input.replaceWith($select);
  850.                 });
  851.                 $newLinkLi.before($newFormLi);
  852.                 addRemoveButton($newFormLi);
  853.                 // Ajouter un gestionnaire d'événements pour les nouveaux éléments ajoutés
  854.                 $newFormLi.find('.remove-room').on('click', function () {
  855.                     $newFormLi.remove();
  856.                 });
  857.             }
  858.             function createDropdown(name) {
  859.                 var $select = $('<select class="input--style-1" style="border: 1px solid black" name="' + name + '"></select>');
  860.                 for (var i = 0; i <= 5; i++) {
  861.                     $select.append('<option value="' + i + '">' + i + '</option>');
  862.                 }
  863.                 return $select;
  864.             }
  865.             function addRemoveButton($formLi) {
  866.                 var $removeRoomButton = $('<button type="button" class="remove-room" style="margin-left: 20px"><i class="fa fa-trash"></i></button>');
  867.                 $formLi.append($removeRoomButton);
  868.                 $removeRoomButton.on('click', function (e) {
  869.                     $formLi.remove();
  870.                 });
  871.             }
  872.             function displayChoices() {
  873.                 var roomValues = [];
  874.                 // Récupérer les valeurs de chaque chambre
  875.                 $('ul.rooms li.row.room-item').each(function () {
  876.                     var nbadultes = $(this).find('select[name*="[nbadultes]"]').val() || 0;
  877.                     var nbfnfants = $(this).find('select[name*="[nbfnfants]"]').val() || 0;
  878.                     roomValues.push({
  879.                         'nbadultes': nbadultes,
  880.                         'nbfnfants': nbfnfants
  881.                     });
  882.                     // Ajouter d'autres lignes pour d'autres champs de la chambre si nécessaire
  883.                 });
  884.                 // Mettre à jour le contenu de l'élément avec les résultats
  885.                 var resultsContainer = $('#results-container');
  886.                 resultsContainer.empty();
  887.                 if (roomValues.length >=1 ) {
  888.                     // Construire le HTML pour afficher les résultats
  889.                     for (var i = 1; i < roomValues.length; i++) {
  890.                         resultsContainer.append('<p>Room ' + (i) + ': Adults - ' + roomValues[i].nbadultes + ', Children - ' + roomValues[i].nbfnfants + '</p>');
  891.                         // Ajouter d'autres lignes pour d'autres champs de la chambre si nécessaire
  892.                     }
  893.                 } else {
  894.                     // Afficher un message si aucun résultat n'est trouvé
  895.                     resultsContainer.html('<p>Aucun résultat trouvé.</p>');
  896.                 }
  897.                 //      Masquer la fenêtre modale après avoir affiché les résultats
  898.                 $('#roomModal').modal('hide');
  899.             }
  900.             // Associer la fonction displayChoices au clic sur le bouton "Enregistrer"
  901.             $('#roomModal').on('click', '.btn-primary', function () {
  902.                 displayChoices();
  903.             });
  904.         });
  905.     </script>
  906.     <script src="https://code.jquery.com/jquery-2.2.4.min.js"></script>
  907.     <script src="https://cdnjs.cloudflare.com/ajax/libs/bxslider/4.2.5/jquery.bxslider.js"></script>
  908.     <script>
  909.         $('.carousel-client').bxSlider({
  910.             auto: true,
  911.             slideWidth: 234,
  912.             minSlides: 1,
  913.             maxSlides: 6,
  914.             controls: false
  915.         });
  916.     </script>
  917.     <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
  918.         <script src="https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/owl.carousel.min.js"></script>
  919.     </div>
  920.     </div>
  921. {% endblock %}