templates/Layouts/layout.html.twig line 91

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% block stylesheets %}
  3.     {# jquery #}
  4.     <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.7.0/jquery.min.js" integrity="sha512-3gJwYpMe3QewGELv8k/BX9vcqhryRdzRMxVfq6ngyWXwo03GFEzjsUm8Q7RZcHPHksttq7/GFoxjCVUjkjvPdw==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
  5.     
  6.     {# OLMap #}
  7.     <!--<link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/openlayers/openlayers.github.io@master/en/v6.14.1/css/ol.css" type="text/css">-->
  8.     <script src="https://cdn.jsdelivr.net/npm/ol@7.4.0/dist/ol.js"></script>
  9.     <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/ol@v7.1.0/ol.css" type="text/css">
  10.     {# jquery UI #}
  11.     <link rel="stylesheet" href="//code.jquery.com/ui/1.13.2/themes/base/jquery-ui.css">
  12.     <script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.13.3/jquery-ui.min.js"></script>
  13.     
  14.     {# D3 #}
  15.     <script src="https://cdn.jsdelivr.net/npm/d3@7"></script>
  16.     {# TomSelect #}
  17.     <link href="https://cdn.jsdelivr.net/npm/tom-select@2.2.2/dist/css/tom-select.css" rel="stylesheet">
  18.     <script src="https://cdn.jsdelivr.net/npm/tom-select@2.2.2/dist/js/tom-select.complete.min.js"></script>
  19.     {# DataTables #}
  20.     <link href="https://cdn.datatables.net/v/dt/dt-1.13.5/datatables.min.css" rel="stylesheet">
  21.     <script src="https://cdn.datatables.net/v/dt/dt-1.13.5/datatables.min.js"></script>
  22.     {# Maps #}
  23.     <script src="{{ asset('build/js/olmap.js') }}"></script>
  24.     {% if app.request.attributes.get('_route') == 'explore_analytic' %}
  25.         <script src="{{ asset('build/js/map_explore.js') }}"></script>    
  26.     {% else %}
  27.         <script src="{{ asset('build/js/map.js') }}"></script>
  28.     {% endif %}
  29.     {# TURF JS #}
  30.     {% if app.request.attributes.get('_route') != 'explore_analytic' %}        
  31.         <script src="https://cdn.jsdelivr.net/npm/@turf/turf@7/turf.min.js"></script>
  32.     {% endif %}
  33.     
  34.     {# <script src="{{ asset('build/js/map_img.js') }}"></script> #}
  35.     {# <script src="{{ asset('build/js/map_tile.js') }}"></script> #}
  36.     {# Stats #}
  37.     <script src="{{ asset('build/js/stats.js') }}"></script>
  38.     {# Fontawesome #}
  39.     {# <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.2/css/all.min.css" integrity="sha512-z3gLpd7yknf1YoNbCzqRKc4qyor8gaKU1qmn+CShxbuBusANI9QpRohGBreCFkKxLhei6S9CQXFEbbKuqLg0DA==" crossorigin="anonymous" referrerpolicy="no-referrer" /> #}
  40.     {# Google Fonts Type #}
  41.     <link rel="preconnect" href="https://fonts.googleapis.com">
  42.     <link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
  43.     <link href="https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300..800;1,300..800&display=swap" rel="stylesheet">
  44.     {# Google Fonts Iconography #}
  45.     <link href="https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined" rel="stylesheet" />
  46.     <link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Material+Symbols+Sharp:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200" />
  47. {% endblock %}
  48. {% block body %}
  49.     {% if app.request.attributes.get('_route') != 'home' and app.request.attributes.get('_route') != 'technology' and app.request.attributes.get('_route') != 'interfaces' and app.request.attributes.get('_route') != 'team' and app.request.attributes.get('_route') != 'about' and app.request.attributes.get('_route') != 'applications' and app.request.attributes.get('_route') != 'view-application' %}
  50.         <div id="new_header">
  51.             {% if app.request.attributes.get('_route') == 'app_project_index' or app.request.attributes.get('_route') == 'app_project_detail' or app.request.attributes.get('_route') == 'app_project_home'%}
  52.                 <a href="{{ path('home') }}" class="m-3 ms-0 hover"><img src="{{ asset('img/icon_planifica.png') }}" height="24px" alt="logo Retabit"/></a>
  53.                 
  54.             {% elseif app.request.attributes.get('_route') == 'app_analytic' or app.request.attributes.get('_route') == 'explore_analytic' or app.request.attributes.get('_route') == 'app_analytic_home' %}
  55.                 
  56.                 <a href="{{ path('home') }}" class="m-3 ms-0 hover"><img src="{{ asset('img/icon_explora.png') }}" height="24px" alt="logo Retabit"/></a>
  57.             
  58.             {% else %}
  59.             
  60.                 <a href="{{ path('home') }}" class="m-3 ms-0 hover"><img src="{{ asset('img/icon_explora.png') }}" height="24px" alt="logo Retabit"/></a>
  61.             
  62.             {% endif %}
  63.             
  64.             <ul id="left_bar_list">
  65.             <li id="new_header_map" class="mb-2"></li>
  66.             <li id="new_header_table" class="mb-2"></li>
  67.             <li id="new_header_card" class="mb-2"></li>
  68.             <li id="new_header_graf" class="mb-2"></li>
  69.             </ul>
  70.             
  71.             <div id="log_div" class="dropup">
  72.             
  73.                 {% if is_granted ('IS_AUTHENTICATED_FULLY') %}
  74.                     {% if is_granted ('ROLE_SUPER_ADMIN') %}
  75.                         
  76.                             <a class="btn btn-primary btn-round"  role="button" href="{{ path('dashboard') }}">
  77.                                 <span style=" ">D</span>
  78.                             </a>
  79.                         
  80.                     {% endif %}
  81.                     <button type="button" class="btn btn-primary btn-round dropdown-toggle btn-dashboard" data-bs-toggle="dropdown" aria-expanded="false" style="">                        
  82.                         <span class="material-symbols-outlined" style="font-size: inherit;" aria-hidden="true">person</span>
  83.                     </button>
  84.                     <ul class="dropdown-menu" style="z-index: 100; padding: 24px 24px;">
  85.                         <!-- Dropdown menu links -->
  86.                         <div class="mb-3">
  87.                             <p>{{ app.user.name}}</p>
  88.                             <small>{{ app.user.email}}</small>
  89.                         </div>
  90.                         <div class="d-flex justify-content-between">
  91.                             
  92.                             <a href="{{ path('profile') }}"><span class="material-symbols-outlined" aria-hidden="true">app_registration</span> </a>
  93.                             <a href="{{ path('app_logout') }}"><span class="material-symbols-outlined" aria-hidden="true">logout</span></a>
  94.                         </div>
  95.                         
  96.                     </ul>
  97.                     
  98.                     
  99.                 {% elseif app.request.attributes.get('_route') == 'app_project_index' or app.request.attributes.get('_route') == 'app_project_detail' or app.request.attributes.get('_route') == 'app_project_home' %}
  100.                     <a href="{{ path('app_login') }}" class="hover">Login</a>    
  101.                 {% endif %} 
  102.             </div>
  103.         </div>
  104.     {% endif %}
  105.     
  106.     {# <div class="container-fluid" id="header">
  107.         <div class="d-flex align-items-center justify-content-between">
  108.             <a href="{{ path('home') }}" class="m-3 ms-0 hover"><img src="{{ asset('img/retabit_logo.svg') }}" height="24px" alt="logo Retabit"/></a>
  109.             <div class="d-inline-block">
  110.                 <a href="{{ path('home') }}" class="hover">Inicio</a>
  111.                 {% if is_granted('IS_AUTHENTICATED_FULLY') %}
  112.                     <a href="{{ path('app_logout') }}">Logout</a>
  113.                 {% endif %}
  114.             </div>
  115.         </div>
  116.     </div> #}
  117.     {% if app.request.attributes.get('_route') == 'app_project_detail' or app.request.attributes.get('_route') == 'explore_analytic' %}
  118.         {% set container_type = 'container-fluid' %}
  119.     {% else %}
  120.         {% set container_type = 'container' %}
  121.     {% endif %}
  122.     {% if app.request.attributes.get('_route') == 'app_project' or app.request.attributes.get('_route') == 'app_project_detail' %}
  123.         {% set project = project[0] %}
  124.     {% endif %}
  125.     
  126.     <div id="big_container" style="{% if app.request.attributes.get('_route') == 'home' or app.request.attributes.get('_route') == 'technology' or app.request.attributes.get('_route') == 'interfaces' or app.request.attributes.get('_route') == 'applications'  or app.request.attributes.get('_route') == 'team' or app.request.attributes.get('_route') == 'about' or app.request.attributes.get('_route') == 'view-application' %}padding-left: 0;{% endif %}">
  127.         <div class="d-flex align-items-center justify-content-between border_bottom" id="header_in_top" style="height: 80px; {% if app.request.attributes.get('_route') == 'home' or app.request.attributes.get('_route') == 'technology' or app.request.attributes.get('_route') == 'interfaces' or app.request.attributes.get('_route') == 'applications' or app.request.attributes.get('_route') == 'team' or app.request.attributes.get('_route') == 'about' or app.request.attributes.get('_route') == 'view-application'%}background: #171C33;{% endif %}">
  128.             {% if app.request.attributes.get('_route') == 'app_project_index' or app.request.attributes.get('_route') == 'app_project_detail' or app.request.attributes.get('_route') == 'app_project_home'%}
  129.                 <div style="display:flex; align-items:center;">
  130.                     <a href="{{ path('app_project_index') }}" class="m-0 hover d-inline-block float-start" style="font-weight:100; color: #212529; letter-spacing: 1px; font-size: 30px; text-decoration:none;"><img src="{{ asset('img/retabit_explora 1.png') }}" class="ms-3" height="29px" alt="logo Retabit" style="display: inline;"/>{% trans %}Planifica{% endtrans %}</a>
  131.                     
  132.                     {% if app.request.attributes.get('_route') == 'app_project_detail' or app.request.attributes.get('_route') == 'app_project_home' %}
  133.                         <h2 class="float-start me-3 mb-0"><span class="ms-3 me-3">|</span><a href="{{ path('app_project_home',{'mun': mun}) }}" class="hover text-decoration-none hover_link">{{ municipioname.adminunitname|capitalize }}</a></h2>
  134.                     {% endif %}
  135.                 </div>
  136.                 
  137.                 {% if app.request.attributes.get('_route') == 'app_project_detail' %}
  138.                     {{include ('components/statsbar_project.html.twig')}}
  139.                 {% endif %}
  140.                 
  141.             
  142.             {% elseif app.request.attributes.get('_route') == 'app_analytic' or app.request.attributes.get('_route') == 'explore_analytic' or app.request.attributes.get('_route') == 'app_analytic_home' %}
  143.             
  144.                 <div style="display:flex; align-items:center;">
  145.                     <a href="{{ path('app_analytic_home') }}" class="m-0 hover d-inline-block float-start" style="font-weight:100; color: #212529; letter-spacing: 1px; font-size: 30px; text-decoration:none;"><img src="{{ asset('img/retabit_explora 1.png') }}" class="ms-3" height="29px" alt="logo Retabit" style="display: inline;"/>{% trans %}Analiza{% endtrans %}</a>
  146.                     {% if app.request.attributes.get('_route') == 'app_analytic' or app.request.attributes.get('_route') == 'explore_analytic' %}
  147.                         <h2 class="float-start mb-0"><span class="ms-3 me-3">|</span><a href="{{ path('app_analytic',{'mun': mun}) }}" class="hover text-decoration-none hover_link">{{ municipioname.adminunitname|capitalize }}</a></h2>
  148.                     {% endif %}
  149.                 </div>
  150.                 {% if app.request.attributes.get('_route') == 'explore_analytic' %}
  151.                     {{include ('components/statsbar_analytic.html.twig')}}
  152.                 {% endif %}
  153.             {% elseif app.request.attributes.get('_route') == 'dashboard' or app.request.attributes.get('_route') == 'users' or app.request.attributes.get('_route') == 'detail-user' or app.request.attributes.get('_route') == 'profile'%} 
  154.                 <div style="display:flex; align-items:center;">
  155.                     <a href="{{ path('dashboard') }}" class="m-0 hover d-inline-block float-start" style="font-weight:100; color: #212529; letter-spacing: 1px; font-size: 30px; text-decoration:none;"><img src="{{ asset('img/retabit_explora 1.png') }}" class="ms-3" height="29px" alt="logo Retabit" style="display: inline;"/>{% trans %}Dashboard{% endtrans %}</a>
  156.                 </div>
  157.             {% elseif app.request.attributes.get('_route') == 'app_login' or app.request.attributes.get('_route') == 'register' or  app.request.attributes.get('_route') == 'app_forgot_password_request' or  app.request.attributes.get('_route') == 'app_reset_password' or  app.request.attributes.get('_route') == 'app_check_email' %} 
  158.                 <div style="display:flex; align-items:center;">
  159.                     <a href="{{ path('home') }}" class="m-0 hover d-inline-block float-start" style="font-weight:100; color: #212529; letter-spacing: 1px; font-size: 30px; text-decoration:none;"><img src="{{ asset('img/retabit_explora 1.png') }}" class="ms-3" height="29px" alt="logo Retabit" style="display: inline;"/>
  160.                         {% if app.request.attributes.get('_route') == 'app_login' %}
  161.                             {% trans %}Login{% endtrans %}
  162.                         {% elseif app.request.attributes.get('_route') == 'register' %}
  163.                             {% trans %}Register{% endtrans %}
  164.                         {% elseif app.request.attributes.get('_route') == 'app_forgot_password_request' %}
  165.                             {% trans %}Reset Password{% endtrans %}
  166.                         {% elseif app.request.attributes.get('_route') == 'app_forgot_password_request' %}
  167.                             {% trans %}Reset your password{% endtrans %}
  168.                         {% elseif app.request.attributes.get('_route') == 'app_check_email' %}
  169.                             {% trans %}Reset your password{% endtrans %}
  170.                         {% endif %}
  171.                     </a>
  172.                 </div>
  173.             {% else %}
  174.                 <div class="container w-100 h-100 overflow-hidden">
  175.                     <div class="d-flex w-100 h-100 align-items-center justify-content-between">
  176.                         <div class="d-flex align-items-center">
  177.                            <!-- <a href="{{ path('home') }}" class="m-3 hover"><img src="{{ asset('img/icon_explora.png') }}" height="24px" alt="logo Retabit"/></a>-->
  178.                             <a href="{{ path('home') }}" class="mt-1 hover d-inline-block"><img src="{{ asset('img/logo-menu-white.png') }}" class="" height="29px" alt="logo Retabit"/></a>
  179.                         </div>
  180.                         <div class="d-flex justify-content-between align-items-center ">
  181.                             <div class="me-5">
  182.                                 <a class="mx-3 item-navHeader {% if app.request.attributes.get('_route') == 'technology' %}active{% endif %}" href="{{ path('technology') }}">{% trans %}TECHNOLOGY{% endtrans %}</a>
  183.                                 <a class="mx-3 item-navHeader {% if app.request.attributes.get('_route') == 'interfaces' %}active{% endif %}" href="{{ path('interfaces') }}">{% trans %}INTERFACES{% endtrans %}</a>
  184.                                 <a class="mx-3 item-navHeader {% if app.request.attributes.get('_route') == 'applications' or app.request.attributes.get('_route') == 'view-application'%}active{% endif %}" href="{{ path('applications') }}">{% trans %}APPLICATIONS{% endtrans %}</a>
  185.                                 <a class="mx-3 item-navHeader {% if app.request.attributes.get('_route') == 'team' %}active{% endif %}" href="{{ path('team') }}">{% trans %}TEAM{% endtrans %}</a>
  186.                                 <a class="mx-3 item-navHeader {% if app.request.attributes.get('_route') == 'about' %}active{% endif %}" href="{{ path('about') }}">{% trans %}ABOUT{% endtrans %}</a>
  187.                             </div>
  188.                             <div class="me-3">
  189.                                 <button class="btn btn-secondary dropdown-toggle" type="button" data-bs-toggle="dropdown" aria-expanded="false">
  190.                                     {{ app.request.get('_locale')|upper }}
  191.                                 </button>
  192.                                 <ul class="dropdown-menu">
  193.                                     <li><a class="dropdown-item" href="{{ path(app.request.get('_route'), app.request.get('_route_params')|merge({'_locale': 'en'})) }}">EN</a></li>
  194.                                     <li><a class="dropdown-item" href="{{ path(app.request.get('_route'), app.request.get('_route_params')|merge({'_locale': 'es'})) }}">ES</a></li>
  195.                                     <li><a class="dropdown-item" href="{{ path(app.request.get('_route'), app.request.get('_route_params')|merge({'_locale': 'ca'})) }}">CA</a></li>
  196.                                 </ul>
  197.                             </div>
  198.                         </div>
  199.                     </div>
  200.                     
  201.                 </div>
  202.             
  203.             {% endif %}
  204.                 
  205.         </div>
  206.         <div id="header_bar" class="col-12 d-none">
  207.             <div class="container-fluid">
  208.                 <div class="row align-items-center justify-content-center">
  209.                     <div class="col-12">
  210.                         <p class="mt-1 mb-1">
  211.                         {% if app.request.attributes.get('_route') == 'home' %}
  212.                             <a href="{{ path('home') }}" class="hover" > Inicio</a>
  213.                         {% elseif app.request.attributes.get('_route') == 'app_analytic_home' %}
  214.                             <a href="{{ path('home') }}" class="hover" > Inicio</a>
  215.                             <span class="material-symbols-outlined">chevron_right</span>
  216.                             <a href="{{ path('app_analytic_home') }}" class="hover" > Analiza </a>
  217.                         {% elseif app.request.attributes.get('_route') == 'app_analytic' %}
  218.                             <a href="{{ path('home') }}" class="hover" > Inicio</a>
  219.                             <span class="material-symbols-outlined">chevron_right</span>
  220.                             <a href="{{ path('app_analytic_home') }}" class="hover" > Analiza </a>
  221.                             <span class="material-symbols-outlined">chevron_right</span>
  222.                             <a href="{{ path('app_analytic', {'mun': mun }) }}" class="hover" > {{ municipioname.adminunitname|capitalize }}</a>
  223.                         {% elseif app.request.attributes.get('_route') == 'explore_analytic' %}
  224.                             <a href="{{ path('home') }}" class="hover" > Inicio</a>
  225.                             <span class="material-symbols-outlined">chevron_right</span>
  226.                             <a href="{{ path('app_analytic_home') }}" class="hover" > Analiza </a>
  227.                             <span class="material-symbols-outlined">chevron_right</span>
  228.                             <a href="{{ path('app_analytic', {'mun': mun }) }}" class="hover" > {{ municipioname.adminunitname|capitalize }}</a>
  229.                             <span class="material-symbols-outlined">chevron_right</span>
  230.                             {% for item in analytic_data %}
  231.                                 {% if item.slug == slug %}
  232.                                     {% set name_analytic = item.name %}
  233.                                     <a href="{{ path('app_analytic', {'mun': mun, 'slug': slug }) }}" class="hover" > {{ name_analytic|capitalize }}</a>
  234.                                 {% endif %}
  235.                             {% endfor %}
  236.                         {% elseif app.request.attributes.get('_route') == 'app_project_index' %}
  237.                             <a href="{{ path('home') }}" class="hover" > Inicio</a>
  238.                             <span class="material-symbols-outlined">chevron_right</span>
  239.                             <a href="{{ path('app_project_index') }}" class="hover" > Planifica </a>
  240.                         {% elseif app.request.attributes.get('_route') == 'app_project_home' %}
  241.                             <a href="{{ path('home') }}" class="hover" > Inicio</a>
  242.                             <span class="material-symbols-outlined">chevron_right</span>
  243.                             <a href="{{ path('app_project_index') }}" class="hover" > Planifica </a>
  244.                             <span class="material-symbols-outlined">chevron_right</span>
  245.                             <a href="{{ path('app_project_home', {'mun': mun }) }}" class="hover" > {{ municipioname.adminunitname|capitalize }}</a>
  246.                             {# {{dump(project)}} #}
  247.                         {% elseif app.request.attributes.get('_route') == 'app_project_detail' %}
  248.                             <a href="{{ path('home') }}" class="hover" > Inicio</a>
  249.                             <span class="material-symbols-outlined">chevron_right</span>
  250.                             <a href="{{ path('app_project_index') }}" class="hover" > Planifica </a>
  251.                             <span class="material-symbols-outlined">chevron_right</span>
  252.                             <a href="{{ path('app_project_home', {'mun': mun }) }}" class="hover" > {{ municipioname.adminunitname|capitalize }}</a>
  253.                             <span class="material-symbols-outlined">chevron_right</span>
  254.                             <a href="{{ path('app_project_detail', {'mun': mun, 'id_project': project.id }) }}" class="hover" > {{ project.name }}</a>
  255.                         {% endif %}
  256.                         </p>
  257.                             
  258.                         
  259.                         
  260.                     </div>
  261.                 </div>
  262.             </div>
  263.         </div>
  264.         
  265.         {% block content %}{% endblock %}
  266.         
  267.     </div>
  268.     <footer>
  269.         <div class="container">
  270.             <div class="row py-5">
  271.                 <div class="col">
  272.                     <div>
  273.                         <img src="{{ asset('custom/logo_retabit.png') }}" alt="logo"/>
  274.                         <h4 class="pt-4 pb-4">Multi-dimensional data driven services to foster residential building retrofitting programmes in the implementation of SECAPs</h4>
  275.                     </div>
  276.                     <div class="ministerio">
  277.                         <img src="https://retabit.es/wp-content/uploads/2022/03/logo-ministerio.png" alt="logo ministerio">
  278.                         <p>
  279.                             Proyecto PID2020-115936RB-C21 <br>
  280.                             Financiado por el Ministerio de Ciencia e Innovación
  281.                         </p>
  282.                     </div>
  283.                 </div>
  284.                 <div class="col offset-md-2">
  285.                     <div class="row">
  286.                         <div class="col">
  287.                             <p>Legal information</p>
  288.                             <ul>
  289.                                 <li><a href="https://retabit.es/privacy-policy">Privacy policy</a></li>
  290.                                 <li><a href="https://retabit.es/terms-and-conditions">Terms &amp; conditions</a></li>
  291.                                 <li><a href="https://retabit.es/cookie-policy">Cookies policy</a></li>
  292.                             </ul>
  293.                         </div>
  294.                         <div class="col">
  295.                             <p>Follow us</p>
  296.                             <ul>
  297.                                 <li><a href="https://twitter.com/retabit_es">Twitter</a></li>
  298.                                 <li><a href="https://www.linkedin.com/company/re-dwell">LinkedIn</a></li>
  299.                             </ul>
  300.                         </div>
  301.                     </div>
  302.                     <div class="row pt-5 align-items-center">
  303.                         <a class="d-inline w-auto" href="https://www.salleurl.edu"><img class="col-6 me-3" style="width: auto;" src="{{ asset('img/footer_salle.png') }}"/></a>
  304.                         <a class="d-inline w-auto" href="https://www.irec.cat/"><img class="col-6" style="width: auto;" src="{{ asset('img/footer_irec.png') }}"/></a>
  305.                         <p class="mt-5">© Design and programming by <a href="https://www.salleurl.edu/en/research/groups-and-institutes/human-environment-research-group/architecture-representation-comp">ARC Engineering and Architecture La Salle</a></p>
  306.                     </div>
  307.                 </div>
  308.             </div>
  309.         
  310.         </div>
  311.     </footer>
  312. {% endblock %}