templates/structure/searchResult.html.twig line 1

Open in your IDE?
  1. <section id="sectionStructure" class="structure col resultats resultats-recherche">
  2.     <h2>Des lieux, associations, institutions ou entreprises</h2>
  3.     
  4.     {# {{ dump(structures) }} #}
  5.     {% if listWithThumbnails %}
  6.         {% import "common/listWithImages.html.twig" as listWithImages %}
  7.         <div class="row structures-list with-images">
  8.             {% for structure in structures %}
  9.                 <div class="col-sm-6 col-md-4 col-lg-3 article with-image 
  10.                     {% if type is defined %}{{ type }}{% endif %}
  11.                 ">
  12.                     <a style="display:block" href="{{ path('showStructureBySlug', {slug:structure.slug}) }}">
  13.                         <div class="post-medias">
  14.                             {{ listWithImages.showOneImage(structure) }}
  15.                         </div>
  16.                         <p>
  17.                             {# <span class="date">{{ structure.createdAt|date("d/m/Y") }}</span>
  18.                             <span class="tags">{{ structure.tags|join(', ') }}</span>
  19.                             <br/> #}
  20.                             <span class="title">
  21.                                 {{ structure.title }}
  22.                                 {# {{ structure.title|raw|striptags|slice(0,30) }}
  23.                                 {% if structure.title|raw|striptags|length > 30 %}...{% endif %} #}
  24.                             </span>
  25.                         </p>
  26.                     </a>
  27.                 </div>
  28.             {% endfor %}
  29.         </div>            
  30.     {% else %}
  31.         <ul class="structuresList">
  32.             {% for key, structure in structures %}
  33.                 <li>
  34.                     <a href="{{ path('showStructureBySlug', { 'slug':structure.slug }) }}">
  35.                         {{ structure.title}} {% if is_granted('ROLE_EDITOR') %}(priorité : {{ structure.priority }}){% endif %} 
  36.                     </a>
  37.                 </li>
  38.             {% endfor %}
  39.         </ul>
  40.     {% endif %}
  41. </section>