src/Elements/Bundle/DemiFrontendBundle/Resources/views/Accommodation/includes/acco-packages.mobile.html.twig line 1

Open in your IDE?
  1. {% if packages is not defined %}{% set packages = null %}{% endif %}
  2. {% if destinationPackages is not defined %}{% set destinationPackages = null %}{% endif %}
  3. <section class="container" data-track-content data-content-name="accommodation-packages">
  4.     <h2 class="h3 mb-2">{{ "demi.detail.package-offers"|trans }}</h2>
  5.     <div class="js-search-data__show-if-submitted mb-3" {{ availabilityIsChecked ? '' : 'hidden' }}>
  6.         {{ include('@ElementsDemiFrontend/Accommodation/includes/acco-detail-searchInfo.html.twig') }}
  7.         {{ include('@ElementsDemiFrontend/Accommodation/includes/corridor-matrix.html.twig', {
  8.             'styleModifier': 'pt-3',
  9.             'type': 'packages'
  10.         }) }}
  11.     </div>
  12.     <div class="js-room-list" aria-live="polite">
  13.         <div class="card box-shadow js-room-list__loading" hidden>
  14.             <div class="card-body text-center py-5">
  15.                 {{ include('@ElementsDemiFrontend/Includes/elements/spinner/loading-spinner.html.twig') }}
  16.             </div>
  17.         </div>
  18.         <div class="card box-shadow js-room-list__content" data-list="packages">
  19.             {% if packages is not empty or (destinationPackages is not empty and demi_core_configuration('getShowDestinationPackagesOnAccoDetail',[])) %}
  20.                 <ul class="list-unstyled">
  21.                     {% set position = 1 %}
  22.                     {% if packages is not empty %}
  23.                         {% for package in packages %}
  24.                                 <li>
  25.                                     {% set productKey = demi_getCheapestProducts(package.getProducts()) %}
  26.                                     {% set productKeys = package.getProducts()|keys  %}
  27.                                     {% set firstProductId = productKeys[productKey] %}
  28.                                     {{ include('@ElementsDemiFrontend/Includes/teaser/package-teaser.html.twig', {
  29.                                         'housePackageMaster': pimcore_object(package.getHousePackageMasterId()),
  30.                                         'cheapestProducts': [package.getProduct(firstProductId)],
  31.                                         'accommodation': accommodation,
  32.                                         'position': position}) }}
  33.                                     <hr class="m-0 hr--light hr--bold">
  34.                                 </li>
  35.                             {% set position = position + 1 %}
  36.                         {% endfor %}
  37.                     {% endif %}
  38.                     {% if destinationPackages is not empty and demi_core_configuration("getShowDestinationPackagesOnAccoDetail",[]) and not isAffiliate %}
  39.                         {% for package in destinationPackages %}
  40.                                 <li>
  41.                                     {{ include('@ElementsDemiFrontend/Includes/teaser/destinationPackage-teaser.html.twig', {
  42.                                         'destinationPackage': package,
  43.                                         'accommodation': accommodation,
  44.                                         'position': position})
  45.                                     }}
  46.                                     <hr class="m-0 hr--light hr--bold">
  47.                                 </li>
  48.                             {% set position = position + 1 %}
  49.                         {% endfor %}
  50.                     {% endif %}
  51.                 </ul>
  52.             {% endif %}
  53.         </div>
  54.     </div>
  55.     <div class="js-corridor__room-packages"></div>
  56. </section>