241 lines
12 KiB
Twig
Executable File
241 lines
12 KiB
Twig
Executable File
<!DOCTYPE html>
|
|
<html>
|
|
<head>
|
|
<title>{% block title %}{{app.session.get("appname")}}{% endblock %}</title>
|
|
|
|
<meta http-equiv="Content-Type" content="text/html"; charset="utf-8" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0" />
|
|
<meta name="robots" content="all">
|
|
<meta name="description" content="{{ app.session.get("appmeta")|replace({'"':"'", "\n":' ', "\r":' '}) }} {% block moremeta %}{% endblock %}">
|
|
|
|
<link rel="shortcut icon" href="{{ path('app_minio_image',{file:"logo/"~app.session.get("logodark")}) }}" />
|
|
|
|
|
|
{{ encore_entry_link_tags('app') }}
|
|
{{ encore_entry_script_tags('app') }}
|
|
{% block encoretags %}{% endblock encoretags %}
|
|
<script src="{{ asset('bundles/tetranzselect2entity/js/select2entity.js') }}"></script>
|
|
|
|
{{ include('Include/style.css.twig') }}
|
|
{% if not app.session.get("apptheme") is empty %}
|
|
<link href="{{ appAlias }}themes/{{ app.session.get("apptheme") }}/style.css" rel="stylesheet" media="screen" />
|
|
{% endif %}
|
|
|
|
{% block localstyle %}{% endblock %}
|
|
</head>
|
|
|
|
<body>
|
|
{% if (useheader is defined and useheader) or (usemenu is defined and usemenu) %}
|
|
<div class="header sticky-top">
|
|
{% if useheader is defined and useheader and app.session.get("haveheader") and (app.session.get("fgheader") or not app.user) %}
|
|
<div id="header" class="d-flex align-items-center" style="height:{{app.session.get("headerheight")}}px; background-image: linear-gradient(90deg,rgba(var(--colorbgbodydark-rgb),1),rgba(var(--colorbgbodydark-rgb),0.1)),url({{ path('app_minio_image',{file:app.session.get("headerimage")}) }});background-size:cover">
|
|
<a href="{{ path('app_home')}}">
|
|
<img src="{{ path('app_minio_image',{file:"logo/"~app.session.get("logodark")}) }}" style="height:{{app.session.get("headerheight")-20}}px;margin-left:10px; max-height:120px;">
|
|
</a>
|
|
|
|
<h1 class="flex-grow-1">
|
|
<a href="{{ path('app_home')}}">
|
|
{{app.session.get("appname")}}
|
|
</a>
|
|
<br>
|
|
<small><a href="{{ path('app_home')}}">{{app.session.get("appsubname")}}</a></small>
|
|
</h1>
|
|
|
|
<div class="pe-3">
|
|
<nav class="nav">
|
|
{% if app.user %}
|
|
<a class="nav-link" href="{{path("app_all_user")}}" title="Mon Profil">
|
|
<img src="{{ path('app_minio_image',{file:"avatar/"~app.user.avatar}) }}" class="avatar" style="width:35px;height:35px;">
|
|
</a>
|
|
|
|
{% if is_granted('ROLE_ADMIN') %}
|
|
<a class="nav-link" href="{{path("app_admin_home")}}" title="Console d'Administration"><i class="fa fa-cog fa-2x"></i></a>
|
|
{% elseif is_granted('ROLE_MODO') %}
|
|
<a class="nav-link" href="{{path("app_modo_home")}}" title="Console d'Administration"><i class="fa fa-cog fa-2x"></i></a>
|
|
{% endif %}
|
|
|
|
{% if app.session.get("showannuaire") %}
|
|
{% if is_granted('ROLE_MANAGER') %}
|
|
<a class="nav-link" href="{{path("app_manager_users")}}" title="Annuaire des Utilisateurs"><i class="fas fa-address-book fa-2x"></i></a>
|
|
{% else %}
|
|
<a class="nav-link" href="{{path("app_all_users")}}" title="Annuaire des Utilisateurs"><i class="fas fa-address-book fa-2x"></i></a>
|
|
{% endif %}
|
|
{% endif %}
|
|
|
|
{% if appGroupuse %}
|
|
<a class="nav-link" href="{{path("app_all_group")}}" title="Gestion des Groupes de Travail"><i class="fas fa-users fa-2x"></i></a>
|
|
{% endif %}
|
|
|
|
{% if app.session.get("haveheader") %}
|
|
<a id="switchHeader" class="nav-link" onclick="switchHeader()" title="Cacher / Afficher Bannière"><i class="fa fa-chevron-up fa-2x"></i></a>
|
|
{% endif %}
|
|
|
|
<a class="nav-link" href="{{path("app_logout")}}" title="Déconnexion"><i class="fa fa-sign-out-alt fa-2x"></i></a>
|
|
{% else %}
|
|
{% if appModeregistration!="none" and appModeregistration!="" and appMasteridentity=="SQL"%}
|
|
<a class="nav-link" href="{{ path('app_registration') }}" title="Inscription"><i class="fa fa-user-plus fa-2x fa-fw"></i></a>
|
|
{% endif %}
|
|
<a class="nav-link" href="{{path("app_login")}}" title="Connexion"><i class="fa fa-sign-in-alt fa-2x"></i></a>
|
|
{% endif %}
|
|
</nav>
|
|
|
|
{% if app.user %}
|
|
<div id="nameuser" style="text-align:right; margin-top:5px"><a href="{{ path('app_all_user') }}" title="Mon Profil">{{ app.user.firstname }} {{ app.user.lastname }}</a></div>
|
|
{% endif %}
|
|
</div>
|
|
</div>
|
|
{% endif %}
|
|
|
|
{% if (usemenu is defined and usemenu) or not app.session.get("fgheader") or not app.session.get("haveheader") %}
|
|
{%set style="display:flex"%}
|
|
{% else %}
|
|
{%set style="display:none"%}
|
|
{% endif %}
|
|
|
|
<nav id="menu" class="navbar navbar-expand p-0" style="{{style}}">
|
|
<a class="nav-link navbar-logo" href="{{ path('app_home')}}" style="display:none">
|
|
<img src="{{ path('app_minio_image',{file:"logo/"~app.session.get("logodark")}) }}">
|
|
</a>
|
|
|
|
<a class="nav-link ps-0" href="{{ path('app_home')}}">
|
|
{% if not app.session.get("fgheader") or not app.session.get("haveheader") %}
|
|
<span style="font-family: var(--fonttitle);">{{app.session.get("appname")}}</span>
|
|
{% else %}
|
|
Accueil
|
|
{% endif %}
|
|
</a>
|
|
|
|
<div class="collapse navbar-collapse" id="navbarNav">
|
|
<ul class="navbar-nav">
|
|
</ul>
|
|
</div>
|
|
|
|
<ul id="menuuser" class="nav navbar-right pe-3">
|
|
{% block menuuser %}
|
|
{% endblock %}
|
|
</ul>
|
|
|
|
<ul id="menulink" class="nav navbar-right pe-3" style="display:none;">
|
|
{% if app.user %}
|
|
<a href="{{path("app_all_user")}}">
|
|
<img src="{{ path('app_minio_image',{file:"avatar/"~app.user.avatar}) }}" class="avatar" style="width:25px; height:25px; margin-top:-3px; margin-right:3px;">
|
|
</a>
|
|
|
|
{% if is_granted('ROLE_ADMIN') %}
|
|
<a href="{{path("app_admin_home")}}"><i class="fa fa-cog fa-fw"></i></a>
|
|
{% elseif is_granted('ROLE_MODO') %}
|
|
<a href="{{path("app_modo_home")}}"><i class="fa fa-cog"></i></a>
|
|
{% endif %}
|
|
|
|
{% if app.session.get("showannuaire") %}
|
|
{% if is_granted('ROLE_MANAGER') %}
|
|
<a href="{{path("app_manager_users")}}" title="Annuaire des Utilisateurs"><i class="fas fa-address-book"></i></a>
|
|
{% else %}
|
|
<a href="{{path("app_all_users")}}" title="Annuaire des Utilisateurs"><i class="fas fa-address-book"></i></a>
|
|
{% endif %}
|
|
{% endif %}
|
|
|
|
{% if appGroupuse %}
|
|
<a href="{{path("app_all_group")}}"><i class="fas fa-users fa-fw"></i></a>
|
|
{% endif %}
|
|
|
|
{% if app.session.get("haveheader") %}
|
|
<a id="switchHeader" class="btn-link" onclick="switchHeader()" title="Cacher / Afficher Bannière"><i class="fa fa-chevron-down fa-fw"></i></a>
|
|
{% endif %}
|
|
|
|
<a href="{{path("app_logout")}}"><i class="fa fa-sign-out-alt fa-fw"></i></a>
|
|
{% else %}
|
|
<a href="{{path("app_login")}}"><i class="fa fa-sign-in-alt fa-fw"></i></a>
|
|
{% endif %}
|
|
</li>
|
|
</ul>
|
|
</nav>
|
|
</div>
|
|
{% endif %}
|
|
|
|
<main>
|
|
{% if usesidebar is defined and usesidebar %}
|
|
{% if is_granted('ROLE_ADMIN') %}
|
|
{{ include('Include/sidebaradmin.html.twig') }}
|
|
{% elseif is_granted('ROLE_MODO') %}
|
|
{{ include('Include/sidebarmodo.html.twig') }}
|
|
{% endif %}
|
|
{% endif %}
|
|
|
|
<div id="page" class="p-4">
|
|
{%if maxsize is defined %}<div style="max-width:{{maxsize}}px;margin:0 auto;">{%endif%}
|
|
{% block body %}{% endblock %}
|
|
|
|
|
|
|
|
{%if maxsize is defined %}</div>{%endif%}
|
|
|
|
|
|
</main>
|
|
|
|
{% if app.session.get("havefooter") and ((useheader is defined and useheader) or (usemenu is defined and usemenu)) %}
|
|
<footer>
|
|
<div class="d-flex align-items-center justify-content-center">
|
|
<div class="footer-adress">
|
|
{{ app.session.get("adress")|raw}}
|
|
</div>
|
|
{{ include('Include/social.html.twig') }}
|
|
</div>
|
|
</footer>
|
|
{% endif %}
|
|
</div>
|
|
|
|
<div id="mymodal" class="modal" role="dialog">
|
|
<div class="modal-dialog modal-lg" role="document">
|
|
<div class="modal-content">
|
|
<div id="mymodalheader" class="modal-header">
|
|
<h4 class="modal-title"></h4>
|
|
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
|
<span aria-hidden="true">×</span>
|
|
</button>
|
|
</div>
|
|
|
|
<div class="modal-body">
|
|
<iframe frameborder=0 width="100%" height="600px"></iframe>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<div id="mymodallarge" class="modal" tabindex="-1">
|
|
<div class="modal-dialog modal-xl">
|
|
<div class="modal-content">
|
|
<div class="modal-header">
|
|
<h4 class="modal-title"></h4>
|
|
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
|
</div>
|
|
<div class="modal-body">
|
|
<iframe frameborder=0 width="100%" height="700px"></iframe>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
<script>
|
|
function switchHeader() {
|
|
{% if app.user %}
|
|
$.ajax({
|
|
method: "POST",
|
|
url: "{{ path('app_all_preference') }}",
|
|
data: {
|
|
id:0,
|
|
key:'fgheader',
|
|
value: !($("#header").is(":visible"))
|
|
},
|
|
success: function() {
|
|
location.reload();
|
|
}
|
|
});
|
|
{% endif %}
|
|
}
|
|
</script>
|
|
|
|
{% block localscript %}{% endblock %}
|
|
</body>
|
|
|
|
</html> |