templates/entreprise/home.html.twig line 41

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% block stylesheets %}
  3.     {{ parent() }}
  4.     <style>
  5.         .slick-prev:before,
  6.         .slick-next:before {
  7.             color: black;
  8.             font-size: 35px;
  9.         }
  10.         .slide-container{
  11.             height: 350px;
  12.         }
  13.     
  14.         .home-collection-slide-container{
  15.             width: 97%;
  16.         }
  17.     </style>
  18. {% endblock stylesheets %}
  19. {% block body %}
  20.      <!-- Slider-->
  21.         <div class="container" >
  22.             <div class="row">
  23.                 <div class="col-md-2">
  24.                     <div>
  25.                     {% for leftBoxe in leftBoxes %}
  26.                         <div>
  27.                              <div class="card">
  28.                                 <div class="card-body text-center">
  29.                                 {{ leftBoxe.contenu | raw }}
  30.                                 </div>
  31.                               </div>
  32.                         </div>
  33.                         <br/>
  34.                     {% endfor %}
  35.                     </div>
  36.                 </div>
  37.                 <div class="col-md-7">
  38.                     <div id="slide-container">
  39.                     {{ render(controller('App\\Controller\\EntrepriseController::homeSlidesAction')) }}
  40.                     </div>
  41.                 </div>
  42.                 <div class="col-md-3">
  43.                     <div>
  44.                     {% for rightBoxe in rightBoxes %}
  45.                         <div>
  46.                              <div class="card">
  47.                                 <div class="card-body text-center">
  48.                                 {{ rightBoxe.contenu | raw }}
  49.                                 </div>
  50.                               </div>
  51.                         </div>
  52.                         <br/>
  53.                     {% endfor %}
  54.                     </div>
  55.                     
  56.                 </div>
  57.             </div>
  58.         </div>
  59.           
  60.     <section class="container pt-5">
  61.         
  62.     
  63.       <!-- Heading-->
  64.       {% for collection in collections %}
  65.       {% if collection.isPromotional %}
  66.         <div class="row">
  67.             {% set photos = collection.photos %}
  68.             {% for p in photos %}
  69.                 <div class="col">
  70.                     <img src="{{ p.url }}" />
  71.                 </div>
  72.             {% endfor %}
  73.         </div>
  74.       {% else %}
  75.         <div class="assie-card">
  76.             <div class="assie-card-body">
  77.               <div class="d-flex flex-wrap justify-content-between align-items-center pt-1 border-bottom pb-4 mb-4">
  78.                 <h2 class="h3 mb-0 pt-3 mr-2">{{ collection.nom }}</h2>
  79.                 <div class="pt-3"><a class="btn btn-outline-accent btn-sm" href="{{ path('product_by_collection', {'slug': collection.slug}) }}">Plus de produits<i class="czi-arrow-right ml-1 mr-n1"></i></a></div>
  80.               </div>
  81.               <!-- Grid-->
  82.                 <div class="home-collection-slide-container">
  83.                   <div class="row pt-2 mx-n2 home-collection-slide">
  84.                     <!-- Product-->
  85.                     {% set products = collection.products %}
  86.                     {{ include ('entreprise/product_raw_list_1.html.twig') }}
  87.                     <!-- Product-->
  88.                   </div>
  89.               </div>
  90.             </div>
  91.         </div>
  92.       {% endif %}
  93.       {% endfor %}
  94.       
  95.     </section>
  96.     <br/>
  97.     <br/>
  98.     <br/>
  99.   {# End main #}
  100. {% endblock body %}
  101. {% block javascripts %}
  102.     {{ parent() }}
  103.     <script type="text/javascript">
  104.     $(function(){
  105.         $('.autoplay-slide').slick({
  106.               slidesToShow: 1,
  107.               slidesToScroll: 1,
  108.               autoplay: true,
  109.               autoplaySpeed: 3000,
  110.               arrows: true,
  111.               responsive: [
  112.                     {
  113.                       breakpoint: 1024,
  114.                       settings: {
  115.                         slidesToShow: 1,
  116.                         slidesToScroll: 1,
  117.                         infinite: true,
  118.                         autoplay: true,
  119.                       }
  120.                     }
  121.                 ]
  122.             });
  123.             
  124.         
  125.     });
  126. </script>
  127. {% endblock javascripts %}