112 lines
5.5 KiB
Twig
112 lines
5.5 KiB
Twig
{% extends 'layout.twig' %}
|
|
|
|
{% block title "Ğ1-Marché - Tableau de bord" %}
|
|
|
|
{% block body %}
|
|
<div class="container" style="color:floralwhite;background-color: #333333;padding: 1rem;">
|
|
<div class="container tab-de-bord">
|
|
<h3 style="display:inline-block;">Tableau de bord - </h3>
|
|
<h4 style="display:inline-block;">
|
|
{% if (sess.role == 0) %} Super Admin{% endif %}
|
|
{% if (sess.role == 1) %} Admin général{% endif %}
|
|
{% if (sess.role == 2) %} Admin Antenne{% endif %}
|
|
</h4>
|
|
</h3>
|
|
</div>
|
|
<p></p>
|
|
{% if (sess.role == 0) %}
|
|
<h4>Liste des admins généraux</h4>
|
|
<ul class="list-group list-group-flush">
|
|
{% for admin_gen in liste_adminGeneral %}
|
|
<a style="color:black;" href="" title="{{ admin_gen.username }}">
|
|
<li class="liste_antennes list-group-item" style="padding: .2rem 1.25rem;">
|
|
{{ admin_gen.username }}
|
|
</li>
|
|
</a>
|
|
{% endfor %}
|
|
</ul>
|
|
{% endif %}
|
|
<p></p>
|
|
{% if (sess.role==0 or sess.role==1) %}
|
|
<h4>Liste des admins Antenne</h4>
|
|
<ul class="list-group list-group-flush">
|
|
{% for admin_ant in liste_adminAntenne %}
|
|
<a style="color:black;" href="" title="{{ admin_ant.username }}">
|
|
<li class="liste_antennes list-group-item" style="padding: .2rem 1.25rem;">
|
|
{{ admin_ant.username }}
|
|
</li>
|
|
</a>
|
|
{% endfor %}
|
|
</ul>
|
|
{% endif %}
|
|
<p></p>
|
|
{% if (sess.role==0 or sess.role==1 or sess.role==2) %}
|
|
<h4>Gérer les antennes</h4>
|
|
<button class="btn btn-primary" style="max-width: 6rem;margin-top:0rem;margin-bottom:0.7rem;height:2rem;">
|
|
<a class="nav-link" href="{{ path('antenne.edit') }}" style="padding-left:0.2rem;margin-top:-0.4rem;color:white;font-size:14px;">MODIFIER</a>
|
|
</button>
|
|
{% if (sess.role==0 or sess.role==1) %}
|
|
<button class="btn btn-primary" style="margin-top:0rem;margin-bottom:0.7rem;height:2rem;padding-left:-1rem;">
|
|
<a class="nav-link" href="{{ path('antenne.create') }}" style="margin-top:-0.4rem;color:white;font-size:14px;">CREER</a>
|
|
</button>
|
|
<button class="btn btn-primary" style="max-width:6.4rem;margin-top:0rem;margin-bottom:0.7rem;height:2rem;">
|
|
<a class="nav-link" href="{{ path('antenne.edit') }}" style="padding-left:0rem;margin-top:-0.4rem;color:white;font-size:14px;">SUPPRIMER</a>
|
|
</button>
|
|
{% endif %}
|
|
<h4>Liste des régions/antennes</h4>
|
|
|
|
<ul class="list-group list-group-flush">
|
|
{% set region = '' %}
|
|
{% for item in listeAntennes %}
|
|
{% if (item.regionName != region) %}
|
|
<li class="liste_antennes list-group-item" style="color:black;
|
|
background-color:lightgoldenrodyellow;padding: .2rem 1.25rem;">
|
|
{{ item.regionName }}
|
|
</li>
|
|
<a style="color:black;" href="" title="{{ item.regionName }}">
|
|
<li class="liste_antennes list-group-item" style="background-color:#8fbc8f;padding: .2rem 1.25rem;">
|
|
► {{ item.antenneName }}
|
|
</li>
|
|
</a>
|
|
{% else %}
|
|
<a style="color:black;" href="" title="{{ item.regionName }}">
|
|
<li class="liste_antennes list-group-item" style="background-color:#8fbc8f;padding: .2rem 1.25rem;">
|
|
► {{ item.antenneName }}
|
|
</li>
|
|
</a>
|
|
{% endif %}
|
|
{% set region = item.regionName %}
|
|
{% endfor %}
|
|
</ul>
|
|
{% endif %}
|
|
<p></p>
|
|
{% if (sess.role==0 or sess.role==1 or sess.role==2) %}
|
|
<h4>Liste des utilisateurs</h4>
|
|
|
|
<ul class="list-group list-group-flush">
|
|
{% for item2 in liste_users_suivi %}
|
|
<a style="color:black;" href="{{ path('dashboard.user',{user:item2.username}) }}" title="{{ item2.username }}">
|
|
<li class="liste_antennes list-group-item" style="padding: .2rem 1.25rem;">
|
|
{{ item2.username }}
|
|
{% set antenne_suivie = item2.suiviantenne|split('|') %}
|
|
{% for antenn in antenne_suivie %}
|
|
{% for item in listeAntennes %}
|
|
{% if (item.id == antenn) %}
|
|
- {{ item.antenneName }}
|
|
{% endif %}
|
|
{% endfor %}
|
|
{% endfor %}
|
|
{% if not (item2.actif) %}
|
|
<button class="btn btn-primary">DESACTIVE</button>
|
|
{% endif %}
|
|
</li>
|
|
</a>
|
|
{% endfor %}
|
|
</ul>
|
|
{% endif %}
|
|
<p></p>
|
|
<div class="row">
|
|
{{ widgets | raw }}
|
|
</div>
|
|
</div>
|
|
{% endblock %} |