<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\CoreExtension;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;
use Twig\TemplateWrapper;
/* analytic/index.html.twig */
class __TwigTemplate_c2f3956b6528201f8313e970207fc607 extends Template
{
private Source $source;
/**
* @var array<string, Template>
*/
private array $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'title' => [$this, 'block_title'],
'content' => [$this, 'block_content'],
];
}
protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
{
// line 1
return "Layouts/layout.html.twig";
}
protected function doDisplay(array $context, array $blocks = []): iterable
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "analytic/index.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "analytic/index.html.twig"));
$this->parent = $this->loadTemplate("Layouts/layout.html.twig", "analytic/index.html.twig", 1);
yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 3
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_title(array $context, array $blocks = []): iterable
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "title"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "title"));
yield " Retabit Platform ";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
// line 5
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_content(array $context, array $blocks = []): iterable
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
// line 6
yield "<div class=\"container\">
<div class=\"row align-items-center justify-content-center\">
<div class=\"col-12 px-5 pe-0\">
<div class=\"row align-items-center justify-content-start\">
<div class=\"col-12 col-sm-6\">
<h1 class=\"mb-3\">";
// line 13
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Analiza el estado actual de los edificios residenciales de un municipio", [], "messages");
yield "</h1>
<select id=\"municipio\" class=\"form-select-perso\" autocomplete=\"off\" placeholder=\"Selecciona municipio\">
";
// line 15
$context['_parent'] = $context;
$context['_seq'] = CoreExtension::ensureTraversable((isset($context["municipios"]) || array_key_exists("municipios", $context) ? $context["municipios"] : (function () { throw new RuntimeError('Variable "municipios" does not exist.', 15, $this->source); })()));
$context['loop'] = [
'parent' => $context['_parent'],
'index0' => 0,
'index' => 1,
'first' => true,
];
if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
$length = count($context['_seq']);
$context['loop']['revindex0'] = $length - 1;
$context['loop']['revindex'] = $length;
$context['loop']['length'] = $length;
$context['loop']['last'] = 1 === $length;
}
foreach ($context['_seq'] as $context["_key"] => $context["muni"]) {
// line 16
yield " <option value=\"";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["muni"], "adminunit", [], "any", false, false, false, 16), "html", null, true);
yield "\"
";
// line 17
if (CoreExtension::getAttribute($this->env, $this->source, $context["loop"], "first", [], "any", false, false, false, 17)) {
// line 18
yield " selected
";
}
// line 20
yield " >";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["muni"], "adminunitname", [], "any", false, false, false, 20), "html", null, true);
yield "</option>
";
++$context['loop']['index0'];
++$context['loop']['index'];
$context['loop']['first'] = false;
if (isset($context['loop']['revindex0'], $context['loop']['revindex'])) {
--$context['loop']['revindex0'];
--$context['loop']['revindex'];
$context['loop']['last'] = 0 === $context['loop']['revindex0'];
}
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_key'], $context['muni'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 22
yield " </select>
<div class=\"mt-3\">
<button class=\"btn btn-primary\" onclick=\"go()\">";
// line 24
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Comienza", [], "messages");
yield "</button>
</div>
</div>
<div class=\"col-12 col-sm-6\" style=\"contain: content;\">
<img src=\"";
// line 29
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("img/bk_descubre.jpg"), "html", null, true);
yield "\" alt=\"Retabit descubre\" class=\"float-end\">
</div>
</div>
</div>
</div>
</div>
<div class=\"container-fluid bk_blue\">
<div class=\"container\">
<div class=\"row align-items-center justify-content-center\">
<div class=\"col-12 text-center p-5\">
<h3 class=\"text-white mb-0\">";
// line 42
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("RETABIT integra datos de diversas fuentes para analizar el parque residencial, considerando factores ambientales, socioeconómicos y urbanos que influyen en la rehabilitación sostenible de los edificios", [], "messages");
yield "</h3>
</div>
</div>
</div>
</div>
<div class=\"container\">
<div class=\"row align-items-center justify-content-center\">
<div class=\"col-12 pe-5 p-5\">
<div class=\"row align-items-center justify-content-start\">
<div class=\"col-12 mb-3\">
<h3>";
// line 55
yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Análisis disponibles", [], "messages");
yield "</h3>
<div class=\"row align-items-top justify-content-start\">
";
// line 57
$context['_parent'] = $context;
$context['_seq'] = CoreExtension::ensureTraversable((isset($context["analytic_filters"]) || array_key_exists("analytic_filters", $context) ? $context["analytic_filters"] : (function () { throw new RuntimeError('Variable "analytic_filters" does not exist.', 57, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
// line 58
yield " <div class=\"col-4 mb-1 p-2 d-flex\">
<div class=\"p-4 w-100 bk_box\">
<h5 class=\"fw-bold\">
";
// line 61
if ((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 61, $this->source); })()), "request", [], "any", false, false, false, 61), "locale", [], "any", false, false, false, 61) == "ca")) {
// line 62
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "name_ca", [], "any", false, false, false, 62), "html", null, true);
yield "
";
} elseif ((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, // line 63
(isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 63, $this->source); })()), "request", [], "any", false, false, false, 63), "locale", [], "any", false, false, false, 63) == "en")) {
// line 64
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "name_en", [], "any", false, false, false, 64), "html", null, true);
yield "
";
} else {
// line 66
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "name", [], "any", false, false, false, 66), "html", null, true);
yield "
";
}
// line 67
yield "
</h5>
<p> ";
// line 69
if ((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 69, $this->source); })()), "request", [], "any", false, false, false, 69), "locale", [], "any", false, false, false, 69) == "ca")) {
// line 70
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "descripcion_ca", [], "any", false, false, false, 70), "html", null, true);
yield "
";
} elseif ((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, // line 71
(isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 71, $this->source); })()), "request", [], "any", false, false, false, 71), "locale", [], "any", false, false, false, 71) == "en")) {
// line 72
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "descripcion_en", [], "any", false, false, false, 72), "html", null, true);
yield "
";
} else {
// line 74
yield " ";
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, $context["item"], "descripcion", [], "any", false, false, false, 74), "html", null, true);
yield "
";
}
// line 76
yield " </p>
</div>
</div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_key'], $context['item'], $context['_parent']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 80
yield " ";
// line 88
yield " </div>
</div>
</div>
</div>
</div>
</div>
<style>
.ts-control::after{
content: '';
width: 30px;
height: 30px;
top: 10px;
right: 0px;
position: absolute;
display: inline-block;
background-image: url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e\");
background-size: 60%;
background-repeat: no-repeat;
}
.ts-dropdown-content{
max-height: 300px !important;
}
</style>
<script src=\"";
// line 117
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("bundles/fosjsrouting/js/router.min.js"), "html", null, true);
yield "\"></script>
<script src=\"";
// line 118
yield $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("fos_js_routing_js", ["callback" => "fos.Router.setData"]);
yield "\"></script>
<script type=\"text/javascript\">
let base_url = '";
// line 121
yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["base_url"]) || array_key_exists("base_url", $context) ? $context["base_url"] : (function () { throw new RuntimeError('Variable "base_url" does not exist.', 121, $this->source); })()), "html", null, true);
yield "';
";
// line 123
yield "
new TomSelect('#municipio',{
plugins: ['dropdown_input'],
});
";
// line 131
yield "
function go(){
let dato = document.getElementById(\"municipio\").value;
let dir = window.location.href;
let url = base_url + '/explora/' + dato;
window.location.href = url;
}
</script>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
yield from [];
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName(): string
{
return "analytic/index.html.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable(): bool
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo(): array
{
return array ( 326 => 131, 319 => 123, 315 => 121, 309 => 118, 305 => 117, 274 => 88, 272 => 80, 263 => 76, 257 => 74, 251 => 72, 249 => 71, 244 => 70, 242 => 69, 238 => 67, 232 => 66, 226 => 64, 224 => 63, 219 => 62, 217 => 61, 212 => 58, 208 => 57, 203 => 55, 187 => 42, 171 => 29, 163 => 24, 159 => 22, 142 => 20, 138 => 18, 136 => 17, 131 => 16, 114 => 15, 109 => 13, 100 => 6, 87 => 5, 64 => 3, 41 => 1,);
}
public function getSourceContext(): Source
{
return new Source("{% extends 'Layouts/layout.html.twig' %}
{% block title %} Retabit Platform {% endblock %}
{% block content %}
<div class=\"container\">
<div class=\"row align-items-center justify-content-center\">
<div class=\"col-12 px-5 pe-0\">
<div class=\"row align-items-center justify-content-start\">
<div class=\"col-12 col-sm-6\">
<h1 class=\"mb-3\">{% trans %}Analiza el estado actual de los edificios residenciales de un municipio{% endtrans %}</h1>
<select id=\"municipio\" class=\"form-select-perso\" autocomplete=\"off\" placeholder=\"Selecciona municipio\">
{% for muni in municipios %}
<option value=\"{{ muni.adminunit }}\"
{% if loop.first %}
selected
{% endif %}
>{{ muni.adminunitname }}</option>
{% endfor %}
</select>
<div class=\"mt-3\">
<button class=\"btn btn-primary\" onclick=\"go()\">{% trans %}Comienza{% endtrans %}</button>
</div>
</div>
<div class=\"col-12 col-sm-6\" style=\"contain: content;\">
<img src=\"{{ asset('img/bk_descubre.jpg') }}\" alt=\"Retabit descubre\" class=\"float-end\">
</div>
</div>
</div>
</div>
</div>
<div class=\"container-fluid bk_blue\">
<div class=\"container\">
<div class=\"row align-items-center justify-content-center\">
<div class=\"col-12 text-center p-5\">
<h3 class=\"text-white mb-0\">{% trans %}RETABIT integra datos de diversas fuentes para analizar el parque residencial, considerando factores ambientales, socioeconómicos y urbanos que influyen en la rehabilitación sostenible de los edificios{% endtrans %}</h3>
</div>
</div>
</div>
</div>
<div class=\"container\">
<div class=\"row align-items-center justify-content-center\">
<div class=\"col-12 pe-5 p-5\">
<div class=\"row align-items-center justify-content-start\">
<div class=\"col-12 mb-3\">
<h3>{% trans %}Análisis disponibles{% endtrans %}</h3>
<div class=\"row align-items-top justify-content-start\">
{% for item in analytic_filters %}
<div class=\"col-4 mb-1 p-2 d-flex\">
<div class=\"p-4 w-100 bk_box\">
<h5 class=\"fw-bold\">
{% if app.request.locale == \"ca\" %}
{{ item.name_ca }}
{% elseif app.request.locale == \"en\" %}
{{ item.name_en }}
{% else %}
{{ item.name }}
{% endif %}
</h5>
<p> {% if app.request.locale == \"ca\" %}
{{ item.descripcion_ca }}
{% elseif app.request.locale == \"en\" %}
{{ item.descripcion_en }}
{% else %}
{{ item.descripcion }}
{% endif %}
</p>
</div>
</div>
{% endfor %}
{# {% for item in kpismulti %}
<div class=\"col-4 mb-1 p-1 d-flex \" >
<div class=\"box one p-2 w-100\">
<h4>{{item.name|capitalize}}</h4>
<p>{{item.info}}</p>
</div>
</div>
{% endfor %} #}
</div>
</div>
</div>
</div>
</div>
</div>
<style>
.ts-control::after{
content: '';
width: 30px;
height: 30px;
top: 10px;
right: 0px;
position: absolute;
display: inline-block;
background-image: url(\"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e\");
background-size: 60%;
background-repeat: no-repeat;
}
.ts-dropdown-content{
max-height: 300px !important;
}
</style>
<script src=\"{{ asset('bundles/fosjsrouting/js/router.min.js') }}\"></script>
<script src=\"{{ path('fos_js_routing_js', { callback: 'fos.Router.setData' }) }}\"></script>
<script type=\"text/javascript\">
let base_url = '{{base_url}}';
{# console.log(base_url); #}
new TomSelect('#municipio',{
plugins: ['dropdown_input'],
});
{# new TomSelect('#municipio_project',{
plugins: ['dropdown_input'],
}); #}
function go(){
let dato = document.getElementById(\"municipio\").value;
let dir = window.location.href;
let url = base_url + '/explora/' + dato;
window.location.href = url;
}
</script>
{% endblock %}
", "analytic/index.html.twig", "/mnt/www/retabit_platform/templates/analytic/index.html.twig");
}
}