src/Elements/Bundle/DemiFrontendBundle/Resources/views/Includes/teaser/badges.html.twig line 1

Open in your IDE?
  1. {% set bubbles = demi_getAccoTeaserBadges(accommodation) %}
  2. {% set isBestPrice = false %}
  3. {% set minPriceProductSets = accommodationItem.getMinPriceProductSets() %}
  4. {% if minPriceProductSets is iterable %}
  5.     {% for minPriceProcuct in minPriceProductSets %}
  6.         {% set isBestPrice = minPriceProcuct.getIsBestPrice()%}
  7.     {% endfor %}
  8. {% endif %}
  9. {% if accommodation.getBestPrice() or isBestPrice or bubbles | length > 0 %}
  10.     <ul class="list-inline list-inline--gutter-3 mb-1">
  11.         {% if accommodation.getBestPrice() or isBestPrice %}
  12.             <li class="list-inline-item">
  13.                 <span class="badge badge-primary">
  14.                     <span class="demi-icon demi-icon-thumb-up"></span>
  15.                     {{ "demi.list.bestprice" | trans}}
  16.                 </span>
  17.             </li>
  18.         {% endif %}
  19.         {% if bubbles | length > 0 %}
  20.             {% for bubble in bubbles %}
  21.                 <li class="list-inline-item">
  22.                     <span class="badge badge-primary">{{ bubble }}</span>
  23.                 </li>
  24.             {% endfor %}
  25.         {% endif %}
  26.     </ul>
  27. {% endif %}