var/cache/dev/twig/a6/a6ab1d30df01a10e76efb218c5a3785c.php line 55

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\SandboxExtension;
  6. use Twig\Markup;
  7. use Twig\Sandbox\SecurityError;
  8. use Twig\Sandbox\SecurityNotAllowedTagError;
  9. use Twig\Sandbox\SecurityNotAllowedFilterError;
  10. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  11. use Twig\Source;
  12. use Twig\Template;
  13. /* layout/includes/header.html.twig */
  14. class __TwigTemplate_eb21a720496fb01cf81c3510a10dbe5e extends Template
  15. {
  16.     private $source;
  17.     private $macros = [];
  18.     public function __construct(Environment $env)
  19.     {
  20.         parent::__construct($env);
  21.         $this->source $this->getSourceContext();
  22.         $this->parent false;
  23.         $this->blocks = [
  24.         ];
  25.         $this->sandbox $this->env->getExtension('\Twig\Extension\SandboxExtension');
  26.         $this->checkSecurity();
  27.     }
  28.     protected function doDisplay(array $context, array $blocks = [])
  29.     {
  30.         $macros $this->macros;
  31.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  32.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""layout/includes/header.html.twig"));
  33.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  34.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""layout/includes/header.html.twig"));
  35.         // line 2
  36.         $context["currentLocale"] = twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'2$this->source); })()), "request", [], "any"falsefalsetrue2), "locale", [], "any"falsefalsetrue2);
  37.         // line 3
  38.         $context["loginRoute"] = ((((isset($context["currentLocale"]) || array_key_exists("currentLocale"$context) ? $context["currentLocale"] : (function () { throw new RuntimeError('Variable "currentLocale" does not exist.'3$this->source); })()) == "en")) ? ("login_en") : ("login_es"));
  39.         // line 4
  40.         echo "
  41. <div id=\"sticky-header\"></div>
  42. <div class=\"header-main header-18\">
  43.     ";
  44.         // line 8
  45.         echo "    ";
  46.         echo twig_include($this->env$context"layout/includes/navegation/desktop.html.twig");
  47.         echo "
  48.     ";
  49.         // line 10
  50.         echo "    <header id=\"header\" class=\"header header-space-mobile d-flex align-items-center ";
  51.         if ((isset($context["is_authenticated"]) || array_key_exists("is_authenticated"$context) ? $context["is_authenticated"] : (function () { throw new RuntimeError('Variable "is_authenticated" does not exist.'10$this->source); })())) {
  52.             echo "header-authenticated";
  53.         } else {
  54.             echo "header-unauthenticated";
  55.         }
  56.         echo "\">
  57.     <div class=\"container-fluid\">
  58.             <div
  59.                 class=\"row justify-content-center\">
  60.                 ";
  61.         // line 15
  62.         echo "                <div
  63.                     class=\"col-6 col-sm-6 col-md-6 col-lg-2 align-self-center justify-content-center d-flex d-lg-none\">
  64.                     ";
  65.         // line 18
  66.         echo "                    <button type=\"button\" class=\"btn--link site-header__menu js-mobile-nav-toggle mobile-nav--open me-3 d-lg-none\">
  67.                         <i class=\"icon an an-times-l\"></i>
  68.                         <i class=\"icon an an-bars-l\"></i>
  69.                     </button>
  70.                     ";
  71.         // line 23
  72.         echo "                </div>
  73.                 ";
  74.         // line 25
  75.         echo "                ";
  76.         if ((isset($context["is_authenticated"]) || array_key_exists("is_authenticated"$context) ? $context["is_authenticated"] : (function () { throw new RuntimeError('Variable "is_authenticated" does not exist.'25$this->source); })())) {
  77.             // line 26
  78.             echo "                    <div class=\"col-6 col-sm-6 col-md-6 col-lg-2 align-items-end d-none d-lg-flex justify-content-end\">
  79.                         ";
  80.             // line 28
  81.             echo "                        <div class=\"dropdown\">
  82.                             <div class=\"user-manual-link iconset\" data-bs-toggle=\"dropdown\" aria-expanded=\"false\" style=\"cursor: pointer;\">
  83.                                 <span>";
  84.             // line 30
  85.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("User Guide"), "html"nulltrue);
  86.             echo "</span>
  87.                             </div>
  88.                             <div class=\"dropdown-menu-end\">
  89.                                 ";
  90.             // line 33
  91.             echo $this->env->getFunction('pimcore_inc')->getCallable()((("/" $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'33$this->source); })()), "request", [], "any"falsefalsetrue33), "locale", [], "any"falsefalsetrue33), 33$this->source)) . "/includes/user-manual"), [], false);
  92.             echo "
  93.                             </div>
  94.                         </div>
  95.                     </div>
  96.                 ";
  97.         }
  98.         // line 38
  99.         echo "                ";
  100.         // line 39
  101.         echo "                ";
  102.         echo twig_include($this->env$context"layout/includes/search-inline.html.twig");
  103.         echo "
  104.                 ";
  105.         // line 41
  106.         echo "                ";
  107.         if ((isset($context["is_authenticated"]) || array_key_exists("is_authenticated"$context) ? $context["is_authenticated"] : (function () { throw new RuntimeError('Variable "is_authenticated" does not exist.'41$this->source); })())) {
  108.             echo 
  109.                 <div class=\"col-6 col-sm-6 col-md-6 col-lg-2 d-none d-lg-block\">
  110.                 
  111.                 </div>
  112.                 ";
  113.         }
  114.         // line 46
  115.         echo "                <div class=\"col-6 col-sm-6 col-md-6 col-lg-2 align-items-center d-flex d-lg-none\"> 
  116.                     <div class=\"site-search iconset\">
  117.                         <i class=\"icon an an-search-l\"></i>
  118.                         <span class=\"tooltip-label\">Search</span>
  119.                     </div>
  120.                     ";
  121.         // line 52
  122.         echo "
  123.                     ";
  124.         // line 54
  125.         echo "                    ";
  126.         if ((isset($context["is_authenticated"]) || array_key_exists("is_authenticated"$context) ? $context["is_authenticated"] : (function () { throw new RuntimeError('Variable "is_authenticated" does not exist.'54$this->source); })())) {
  127.             // line 55
  128.             echo "                        <div class=\"user-link iconset dropdown\">
  129.                             <button class=\"btn btn-link dropdown-toggle\" type=\"button\" id=\"userDropdown\" data-bs-toggle=\"dropdown\" aria-expanded=\"false\">
  130.                                 <i class=\"icon an an-user d-block\"></i>
  131.                                 <span class=\"text d-none\"></span>
  132.                             </button>
  133.                             <ul class=\"dropdown-menu dropdown-menu-end\" aria-labelledby=\"userDropdown\">
  134.                                 ";
  135.             // line 61
  136.             $context["currentLocale"] = twig_get_attribute($this->env$this->sourcetwig_get_attribute($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"falsefalsetrue61), "locale", [], "any"falsefalsetrue61);
  137.             // line 62
  138.             echo "                                ";
  139.             if (((isset($context["currentLocale"]) || array_key_exists("currentLocale"$context) ? $context["currentLocale"] : (function () { throw new RuntimeError('Variable "currentLocale" does not exist.'62$this->source); })()) == "en")) {
  140.                 // line 63
  141.                 echo "                                    <li><a class=\"dropdown-item\" href=\"";
  142.                 echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("myAccount");
  143.                 echo "\">";
  144.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("My account"), "html"nulltrue);
  145.                 echo "</a></li>
  146.                                     <li><a class=\"dropdown-item\" href=\"";
  147.                 // line 64
  148.                 echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("account_logout");
  149.                 echo "\">";
  150.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Logout"), "html"nulltrue);
  151.                 echo "</a></li>
  152.                                 ";
  153.             } else {
  154.                 // line 66
  155.                 echo "                                    <li><a class=\"dropdown-item\" href=\"";
  156.                 echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("myAccount");
  157.                 echo "\">";
  158.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Mi cuenta"), "html"nulltrue);
  159.                 echo "</a></li>
  160.                                     <li><a class=\"dropdown-item\" href=\"";
  161.                 // line 67
  162.                 echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("account_logout");
  163.                 echo "\">";
  164.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Salir"), "html"nulltrue);
  165.                 echo "</a></li>
  166.                                 ";
  167.             }
  168.             // line 69
  169.             echo "                            </ul>
  170.                         </div>
  171.                         ";
  172.             // line 72
  173.             echo "                        ";
  174.             echo $this->env->getFunction('pimcore_inc')->getCallable()((("/" $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source, (isset($context["app"]) || array_key_exists("app"$context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.'72$this->source); })()), "request", [], "any"falsefalsetrue72), "locale", [], "any"falsefalsetrue72), 72$this->source)) . "/includes/navbar-top"), [], false);
  175.             echo "
  176.                         ";
  177.             // line 74
  178.             echo "                        ";
  179.             // line 75
  180.             echo "                    ";
  181.         } else {
  182.             // line 76
  183.             echo "                        <div class=\"user-link iconset\">
  184.                             <a href=\"";
  185.             // line 77
  186.             echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath($this->sandbox->ensureToStringAllowed((isset($context["loginRoute"]) || array_key_exists("loginRoute"$context) ? $context["loginRoute"] : (function () { throw new RuntimeError('Variable "loginRoute" does not exist.'77$this->source); })()), 77$this->source));
  187.             echo "\">
  188.                                 <i class=\"icon an an-sign-in-al d-block\"></i>
  189.                                 <span class=\"text d-none\">";
  190.             // line 79
  191.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("layout.navbar-desktop.professional-area_translations"), "html"nulltrue);
  192.             echo "</span>
  193.                             </a>
  194.                         </div>
  195.                     ";
  196.         }
  197.         // line 83
  198.         echo "                    ";
  199.         // line 84
  200.         echo "                    
  201.                     ";
  202.         // line 86
  203.         echo "                    ";
  204.         echo twig_include($this->env$context"layout/includes/settings.html.twig");
  205.         echo "
  206.                     ";
  207.         // line 88
  208.         echo "                </div>
  209.                 ";
  210.         // line 90
  211.         echo "            </div>
  212.         </div>
  213.         ";
  214.         // line 93
  215.         echo "        ";
  216.         echo twig_include($this->env$context"layout/includes/search-popup.html.twig");
  217.         echo "
  218.         ";
  219.         // line 95
  220.         echo "    </header>
  221.     ";
  222.         // line 97
  223.         echo "    ";
  224.         if (((isset($context["is_authenticated"]) || array_key_exists("is_authenticated"$context) ? $context["is_authenticated"] : (function () { throw new RuntimeError('Variable "is_authenticated" does not exist.'97$this->source); })()) && (twig_get_attribute($this->env$this->source, (isset($context["api_sage"]) || array_key_exists("api_sage"$context) ? $context["api_sage"] : (function () { throw new RuntimeError('Variable "api_sage" does not exist.'97$this->source); })()), "access_token", [], "any"falsefalsetrue97) == ""))) {
  225.             // line 98
  226.             echo "        ";
  227.             echo twig_include($this->env$context"layout/includes/error-with-sage-api.html.twig");
  228.             echo "
  229.     ";
  230.         }
  231.         // line 100
  232.         echo "</div>";
  233.         
  234.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  235.         
  236.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  237.     }
  238.     /**
  239.      * @codeCoverageIgnore
  240.      */
  241.     public function getTemplateName()
  242.     {
  243.         return "layout/includes/header.html.twig";
  244.     }
  245.     /**
  246.      * @codeCoverageIgnore
  247.      */
  248.     public function isTraitable()
  249.     {
  250.         return false;
  251.     }
  252.     /**
  253.      * @codeCoverageIgnore
  254.      */
  255.     public function getDebugInfo()
  256.     {
  257.         return array (  241 => 100,  235 => 98,  232 => 97,  229 => 95,  224 => 93,  220 => 90,  217 => 88,  212 => 86,  209 => 84,  207 => 83,  200 => 79,  195 => 77,  192 => 76,  189 => 75,  187 => 74,  182 => 72,  178 => 69,  171 => 67,  164 => 66,  157 => 64,  150 => 63,  147 => 62,  145 => 61,  137 => 55,  134 => 54,  131 => 52,  124 => 46,  115 => 41,  110 => 39,  108 => 38,  100 => 33,  94 => 30,  90 => 28,  87 => 26,  84 => 25,  81 => 23,  75 => 18,  71 => 15,  59 => 10,  54 => 8,  49 => 4,  47 => 3,  45 => 2,);
  258.     }
  259.     public function getSourceContext()
  260.     {
  261.         return new Source("{# Get the current language from the Request #}
  262. {% set currentLocale = app.request.locale %}
  263. {% set loginRoute = (currentLocale == 'en') ? 'login_en' : 'login_es' %}
  264. <div id=\"sticky-header\"></div>
  265. <div class=\"header-main header-18\">
  266.     {# Main Navigation Desktop #}
  267.     {{ include(\"layout/includes/navegation/desktop.html.twig\") }}
  268.     {# End Main Navigation Desktop #}
  269.     <header id=\"header\" class=\"header header-space-mobile d-flex align-items-center {% if is_authenticated %}header-authenticated{% else %}header-unauthenticated{% endif %}\">
  270.     <div class=\"container-fluid\">
  271.             <div
  272.                 class=\"row justify-content-center\">
  273.                 {# Logo / Menu Toggle #}
  274.                 <div
  275.                     class=\"col-6 col-sm-6 col-md-6 col-lg-2 align-self-center justify-content-center d-flex d-lg-none\">
  276.                     {# Mobile Toggle #}
  277.                     <button type=\"button\" class=\"btn--link site-header__menu js-mobile-nav-toggle mobile-nav--open me-3 d-lg-none\">
  278.                         <i class=\"icon an an-times-l\"></i>
  279.                         <i class=\"icon an an-bars-l\"></i>
  280.                     </button>
  281.                     {# End Mobile Toggle #}
  282.                 </div>
  283.                 {# End Logo / Menu Toggle #}
  284.                 {% if is_authenticated %}
  285.                     <div class=\"col-6 col-sm-6 col-md-6 col-lg-2 align-items-end d-none d-lg-flex justify-content-end\">
  286.                         {# User Manual Dropdown #}
  287.                         <div class=\"dropdown\">
  288.                             <div class=\"user-manual-link iconset\" data-bs-toggle=\"dropdown\" aria-expanded=\"false\" style=\"cursor: pointer;\">
  289.                                 <span>{{ 'User Guide' | trans }}</span>
  290.                             </div>
  291.                             <div class=\"dropdown-menu-end\">
  292.                                 {{ pimcore_inc('/' ~ app.request.locale ~ '/includes/user-manual',{},false) }}
  293.                             </div>
  294.                         </div>
  295.                     </div>
  296.                 {% endif %}
  297.                 {# Search Inline #}
  298.                 {{ include(\"layout/includes/search-inline.html.twig\") }}
  299.                 {# End Search Inline #}
  300.                 {% if is_authenticated %} 
  301.                 <div class=\"col-6 col-sm-6 col-md-6 col-lg-2 d-none d-lg-block\">
  302.                 
  303.                 </div>
  304.                 {% endif %}
  305.                 <div class=\"col-6 col-sm-6 col-md-6 col-lg-2 align-items-center d-flex d-lg-none\"> 
  306.                     <div class=\"site-search iconset\">
  307.                         <i class=\"icon an an-search-l\"></i>
  308.                         <span class=\"tooltip-label\">Search</span>
  309.                     </div>
  310.                     {# End Search #}
  311.                     {# User Account/Professional Area #}
  312.                     {% if is_authenticated %}
  313.                         <div class=\"user-link iconset dropdown\">
  314.                             <button class=\"btn btn-link dropdown-toggle\" type=\"button\" id=\"userDropdown\" data-bs-toggle=\"dropdown\" aria-expanded=\"false\">
  315.                                 <i class=\"icon an an-user d-block\"></i>
  316.                                 <span class=\"text d-none\"></span>
  317.                             </button>
  318.                             <ul class=\"dropdown-menu dropdown-menu-end\" aria-labelledby=\"userDropdown\">
  319.                                 {% set currentLocale = app.request.locale %}
  320.                                 {% if currentLocale == 'en' %}
  321.                                     <li><a class=\"dropdown-item\" href=\"{{ path('myAccount')}}\">{{ \"My account\" | trans }}</a></li>
  322.                                     <li><a class=\"dropdown-item\" href=\"{{ path('account_logout')}}\">{{ \"Logout\" | trans }}</a></li>
  323.                                 {% else %}
  324.                                     <li><a class=\"dropdown-item\" href=\"{{ path('myAccount')}}\">{{ \"Mi cuenta\" | trans }}</a></li>
  325.                                     <li><a class=\"dropdown-item\" href=\"{{ path('account_logout')}}\">{{ \"Salir\" | trans }}</a></li>
  326.                                 {% endif %}
  327.                             </ul>
  328.                         </div>
  329.                         {# Minicart Drawer #}
  330.                         {{ pimcore_inc('/' ~ app.request.locale ~ '/includes/navbar-top',{},false) }}
  331.                         {#\t\t\t\t\t\t{{ include(\"layout/includes/minicart/minicart-drawer-btn.html.twig\") }}#}
  332.                         {# End Minicart Drawer #}
  333.                     {% else %}
  334.                         <div class=\"user-link iconset\">
  335.                             <a href=\"{{ path(loginRoute) }}\">
  336.                                 <i class=\"icon an an-sign-in-al d-block\"></i>
  337.                                 <span class=\"text d-none\">{{ 'layout.navbar-desktop.professional-area_translations' | trans }}</span>
  338.                             </a>
  339.                         </div>
  340.                     {% endif %}
  341.                     {# End User Account/Professional Area #}
  342.                     
  343.                     {# Language Selector #}
  344.                     {{ include(\"layout/includes/settings.html.twig\") }}
  345.                     {# End Language Selector #}
  346.                 </div>
  347.                 {# End Right Action #}
  348.             </div>
  349.         </div>
  350.         {# Search Popup #}
  351.         {{ include(\"layout/includes/search-popup.html.twig\") }}
  352.         {# End Search Popup #}
  353.     </header>
  354.     {# End Header #}
  355.     {% if is_authenticated and api_sage.access_token == '' %}
  356.         {{ include(\"layout/includes/error-with-sage-api.html.twig\") }}
  357.     {% endif %}
  358. </div>""layout/includes/header.html.twig""/var/www/html/templates/layout/includes/header.html.twig");
  359.     }
  360.     
  361.     public function checkSecurity()
  362.     {
  363.         static $tags = array("set" => 2"if" => 10);
  364.         static $filters = array("escape" => 30"trans" => 30);
  365.         static $functions = array("include" => 8"pimcore_inc" => 33"path" => 63);
  366.         try {
  367.             $this->sandbox->checkSecurity(
  368.                 ['set''if'],
  369.                 ['escape''trans'],
  370.                 ['include''pimcore_inc''path']
  371.             );
  372.         } catch (SecurityError $e) {
  373.             $e->setSourceContext($this->source);
  374.             if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
  375.                 $e->setTemplateLine($tags[$e->getTagName()]);
  376.             } elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
  377.                 $e->setTemplateLine($filters[$e->getFilterName()]);
  378.             } elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
  379.                 $e->setTemplateLine($functions[$e->getFunctionName()]);
  380.             }
  381.             throw $e;
  382.         }
  383.     }
  384. }