{% extends '@kohinos/common/layout.html.twig' %} {% block content %} <div class='container comptoirshow mt-2'> {% include '@kohinos/block/breadcrumb.html.twig' with {'label' : comptoir.name, 'label2': 'Liste de comptoirs', 'url2': path('comptoirs_liste') } %} <div class="bg-white rounded box-shadow"> <div class="contentcomptoir p-4 mt-2"> <div class="card mb-2"> <div class="card-header"> <h1>{{comptoir.name}}</h1> {% if comptoir.groupe != null %} <h5 class="card-subtitle">{{'Groupe local'|trans}} : <a href='{{ path('show_groupe', {'slug': comptoir.groupe.slug}) }}'>{{comptoir.groupe.__toString()}}</a></h5> {% endif %} {# @TODO : ajouter le lien d'édition uniquement quand l'utilisateur peut l'éditer (Voter?) #} {% if app.user and is_granted('ROLE_SUPER_ADMIN') %} <a class='btn btn-primary float-right' href="{{ path('comptoir_edit', {'id': comptoir.id}) }}">Edit</a> {% endif %} </div> <div class="card-body"> {% if comptoir.content != null or comptoir.media != null %} <div class="card-text mb-3 clearfix"> {% if comptoir.media != null %} <img class="w-25 float-right mr-2" src="{% path comptoir.media, 'big' %}" alt="{{comptoir.name}}"> {% endif %} {% if comptoir.content != null %} <p>{{comptoir.content|raw}}</p> {% endif %} </div> {% endif %} {% if comptoir.getFullAddresse() != null %} <h5 class="card-title">{{ 'Adresse'|trans }} :</h5> <h6 class="card-title text-muted mb-3">{{comptoir.getFullAddresse()}}</h6> {# @TODO : afficher la carte avec le POI du comptoir #} {% endif %} {% if comptoir.contacts|length > 0%} <h5 class="card-title">{{ 'Contact'|trans }}{{ (comptoir.contacts|filter(v => v.enabled)|length > 1) ? 's' : '' }} :</h5> <ul class="list-group"> {% for contact in comptoir.contacts|filter(v => v.enabled) %} <li class="list-group-item"> <b>{{contact.name}}</b><br/> {% if contact.tel != null %}{{contact.tel}}<br/>{% endif %} {% if contact.email != null %}{{contact.email}}{% endif %} </li> {% endfor %} </ul> {% endif %} </div> <div class="card-header"><h2>{{ 'Prestataires du groupe'|trans }} ({{ comptoir.groupe.prestataires|length }}) :</h2></div> <div class="row m-2"> {% for presta in comptoir.groupe.prestataires|filter(v => v.enabled and not v.mlc) %} <div class="col-6 mb-2"> {% include '@kohinos/presta/onepresta.html.twig' %} </div> {% endfor %} </ul> </div> </div> </div> </div> {% endblock %}