Commit 16b70e7f authored by ornanovitch's avatar ornanovitch 🐃

simplification liste théâtres (accordion incompatible avec algo twig)

parent de23c025
This diff is collapsed.
......@@ -3,39 +3,28 @@
{% block body %}
<h1 class="w-100 font-weight-bold mb-3">LES THÉÂTRES BALISES</h1>
<div id="accordionTheatersBalises">
{% set city = "" %}
{% for theater in theaters|sort((a, b) => a.city <=> b.city) %}
{% if city != theater.city %}
<div class="card bg-dark">
<a class="h4 card-header bg-dark collapsed text-light"
type="button"
data-toggle="collapse"
data-target="#{{ theater.city | replace({' ': '_', '\'': '-'}) }}"
aria-expanded="true" aria-controls="{{ theater.city | replace({' ': '_', '\'': '-'}) }}">
<div id="card-{{ theater.city | replace({' ': '_', '\'': '-'}) }}">
<i class="fas fa-chevron-down"></i>
{{ theater.city | upper }}
</div>
</a>
{% endif %}
<div id="{{ theater.city | replace({' ': '_', '\'': '-'}) }}"
class="collapse"
aria-labelledby="{{ theater.city | replace({' ': '_', '\'': '-'}) }}"
data-parent="#accordionTheatersBalises">
<div class="card-body bg-light">
<div class="d-flex align-items-center">
<a class="h5 p-2 text-dark flex-grow-1 font-weight-bold" href="{{ path('theater_show_visitors' ,{'id': theater.id}) }}"> {{ theater.nameAlt }}</a>
<!-- futur lien vers la carte -->
{# <a class="p-2 text-dark" href="{{ path('theater_show_visitors' ,{'id': theater.id}) }} "><i class="fas fa-map-marked-alt fa-2x"></i></a> #}
<a class="p-2 text-dark" href="{{ theater.website }}"><i class="fas fa-external-link-alt fa-2x"></i></a>
<div class="card bg-dark">
<div class="card-header">
<h1 class="text-uppercase font-weight-bold m-0">les Théâtres Balises</h1>
</div>
<div class="card-body">
<ul class="list-group">
{% set city = "" %}
{% for theater in theaters|sort((a, b) => a.city <=> b.city) %}
{% if city != theater.city %}
<div class="h5 pl-0 m-0 list-group-item disabled bg-dark text-light font-weight-bold">
{{ theater.city|upper }}
</div>
</div>
</div>
{% endif %}
<a class="h4 m-0 list-group-item bg-light text-dark" href="{{ path('theater_show_visitors' ,{'id': theater.id}) }}">
{{ theater.nameAlt }}
</a>
{% set city = theater.city %}
{% endfor %}
</ul>
</div>
{% set city = theater.city %}
{% endfor %}
</div>
{% endblock %}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment