var/cache/dev/twig/6d/6d25d4717cabc1b8eb6ff73df9ba860c.php line 41

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\CoreExtension;
  6. use Twig\Extension\SandboxExtension;
  7. use Twig\Markup;
  8. use Twig\Sandbox\SecurityError;
  9. use Twig\Sandbox\SecurityNotAllowedTagError;
  10. use Twig\Sandbox\SecurityNotAllowedFilterError;
  11. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  12. use Twig\Source;
  13. use Twig\Template;
  14. /* @FactorySupport/document/category_page/default.html.twig */
  15. class __TwigTemplate_ddc80679697f0591763950d55a354c3e extends Template
  16. {
  17.     private $source;
  18.     private $macros = [];
  19.     public function __construct(Environment $env)
  20.     {
  21.         parent::__construct($env);
  22.         $this->source $this->getSourceContext();
  23.         $this->blocks = [
  24.             'contentBlock' => [$this'block_contentBlock'],
  25.         ];
  26.         $this->sandbox $this->env->getExtension(SandboxExtension::class);
  27.         $this->checkSecurity();
  28.     }
  29.     protected function doGetParent(array $context)
  30.     {
  31.         // line 1
  32.         return "layout/default.html.twig";
  33.     }
  34.     protected function doDisplay(array $context, array $blocks = [])
  35.     {
  36.         $macros $this->macros;
  37.         $__internal_b91a4435ea3baf1e2b6bfda56133dace $this->extensions["Sentry\\SentryBundle\\Tracing\\Twig\\TwigTracingExtension"];
  38.         $__internal_b91a4435ea3baf1e2b6bfda56133dace->enter($__internal_b91a4435ea3baf1e2b6bfda56133dace_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@FactorySupport/document/category_page/default.html.twig"));
  39.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  40.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@FactorySupport/document/category_page/default.html.twig"));
  41.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  42.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""@FactorySupport/document/category_page/default.html.twig"));
  43.         $this->parent $this->loadTemplate("layout/default.html.twig""@FactorySupport/document/category_page/default.html.twig"1);
  44.         yield from $this->parent->unwrap()->yield($contextarray_merge($this->blocks$blocks));
  45.         
  46.         $__internal_b91a4435ea3baf1e2b6bfda56133dace->leave($__internal_b91a4435ea3baf1e2b6bfda56133dace_prof);
  47.         
  48.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  49.         
  50.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  51.     }
  52.     // line 3
  53.     public function block_contentBlock($context, array $blocks = [])
  54.     {
  55.         $macros $this->macros;
  56.         $__internal_b91a4435ea3baf1e2b6bfda56133dace $this->extensions["Sentry\\SentryBundle\\Tracing\\Twig\\TwigTracingExtension"];
  57.         $__internal_b91a4435ea3baf1e2b6bfda56133dace->enter($__internal_b91a4435ea3baf1e2b6bfda56133dace_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""contentBlock"));
  58.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  59.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""contentBlock"));
  60.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  61.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""contentBlock"));
  62.         // line 4
  63.         yield "<main class=\"stereotaxicCategoryPage\" style=\"background-attachment: fixed;background-image: url(";
  64.         ((CoreExtension::getAttribute($this->env$this->source, (isset($context["document"]) || array_key_exists("document"$context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.'4$this->source); })()), "getProperty", ["template_background_image"], "method"falsefalsetrue4)) ? (yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env$this->sourceCoreExtension::getAttribute($this->env$this->source, (isset($context["document"]) || array_key_exists("document"$context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.'4$this->source); })()), "getProperty", ["template_background_image"], "method"falsefalsetrue4), "getThumbnail", ["Stoelting_division_bg"], "method"falsefalsetrue4), "html"nulltrue)) : (yield ""));
  65.         yield ") ;\">
  66.         <div class=\"container mt-5 mt-lg-5 mt-md-5\">
  67.             <div class=\"row\">
  68.                 <div class=\"col-xl-10 offset-xl-1 offset-lg-0 col-lg-12 pb-3 pb-lg-3 pb-md-3\">
  69.                     <div class=\"d-flex align-items-center\">
  70.                         ";
  71.         // line 9
  72.         $context["anyMaze"] = CoreExtension::inFilter("any-maze"Twig\Extension\CoreExtension::lower($this->env->getCharset(), $this->sandbox->ensureToStringAllowed(CoreExtension::getAttribute($this->env$this->source, (isset($context["document"]) || array_key_exists("document"$context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.'9$this->source); })()), "getProperty", ["navigation_title"], "method"falsefalsetrue9), 9$this->source)));
  73.         // line 10
  74.         yield "                        <div class=\"category-breadcrumb-image mr-3 mr-lg-3 mr-md-3\">
  75.                             ";
  76.         // line 11
  77.         if ((isset($context["editmode"]) || array_key_exists("editmode"$context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.'11$this->source); })())) {
  78.             // line 12
  79.             yield "                                ";
  80.             yield $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"image""categoryBreadcrumbImage");
  81.             yield "
  82.                             ";
  83.         } else {
  84.             // line 14
  85.             yield "                                <img style=\"width:80px;\" src=\"";
  86.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->sandbox->ensureToStringAllowed(CoreExtension::getAttribute($this->env$this->source$this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"image""categoryBreadcrumbImage"), "getThumbnail", ["Stoelting_category_breadcrumb"], "method"falsefalsetrue14), 14$this->source), "html"nulltrue);
  87.             yield "\" alt=\"";
  88.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->sandbox->ensureToStringAllowed(CoreExtension::getAttribute($this->env$this->source$this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"image""categoryBreadcrumbImage"), "getAlt", [], "method"falsefalsetrue14), 14$this->source), "html"nulltrue);
  89.             yield "\">
  90.                             ";
  91.         }
  92.         // line 16
  93.         yield "                        </div>
  94.                         <h2 class=\"d-none d-md-inline font-weight-bold border-2 border-bottom border-indigo w-100 custom-bradcrumb-padding\">
  95.                             ";
  96.         // line 18
  97.         if ((isset($context["editmode"]) || array_key_exists("editmode"$context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.'18$this->source); })())) {
  98.             // line 19
  99.             yield "                                ";
  100.             yield $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""categoryBreadcrumbHeading", ["placeholder" => CoreExtension::getAttribute($this->env$this->source,             // line 20
  101. (isset($context["document"]) || array_key_exists("document"$context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.'20$this->source); })()), "getProperty", ["navigation_title"], "method"falsefalsetrue20)]);
  102.             // line 21
  103.             yield "
  104.                             ";
  105.         } elseif ( !CoreExtension::getAttribute($this->env$this->source$this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""categoryBreadcrumbHeading"), "isEmpty", [], "method"falsefalsetrue22)) {
  106.             // line 23
  107.             yield "                                ";
  108.             yield $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""categoryBreadcrumbHeading");
  109.             yield "
  110.                             ";
  111.         } else {
  112.             // line 25
  113.             yield "                                ";
  114.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->sandbox->ensureToStringAllowed(CoreExtension::getAttribute($this->env$this->source, (isset($context["document"]) || array_key_exists("document"$context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.'25$this->source); })()), "getProperty", ["navigation_title"], "method"falsefalsetrue25), 25$this->source), "html"nulltrue);
  115.             yield "
  116.                             ";
  117.         }
  118.         // line 27
  119.         yield "                        </h2>
  120.                         <!--* ON MOBILE H3-->
  121.                         <h3 class=\"d-inline d-md-none font-weight-bold border-2 border-bottom border-indigo w-100 custom-bradcrumb-padding\">
  122.                             ";
  123.         // line 30
  124.         if ((isset($context["editmode"]) || array_key_exists("editmode"$context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.'30$this->source); })())) {
  125.             // line 31
  126.             yield "                                ";
  127.             yield $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""categoryBreadcrumbHeading--mobile", ["placeholder" => CoreExtension::getAttribute($this->env$this->source,             // line 32
  128. (isset($context["document"]) || array_key_exists("document"$context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.'32$this->source); })()), "getProperty", ["navigation_title"], "method"falsefalsetrue32)]);
  129.             // line 33
  130.             yield "
  131.                             ";
  132.         } elseif ( !CoreExtension::getAttribute($this->env$this->source$this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""categoryBreadcrumbHeading--mobile"), "isEmpty", [], "method"falsefalsetrue34)) {
  133.             // line 35
  134.             yield "                                ";
  135.             yield $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""categoryBreadcrumbHeading--mobile");
  136.             yield "
  137.                             ";
  138.         } else {
  139.             // line 37
  140.             yield "                                ";
  141.             yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->sandbox->ensureToStringAllowed(CoreExtension::getAttribute($this->env$this->source, (isset($context["document"]) || array_key_exists("document"$context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.'37$this->source); })()), "getProperty", ["navigation_title"], "method"falsefalsetrue37), 37$this->source), "html"nulltrue);
  142.             yield "
  143.                             ";
  144.         }
  145.         // line 39
  146.         yield "                        </h3>
  147.                     </div>
  148.                 </div>
  149.             </div>
  150.             <div class=\"row mt-5 mt-lg-5 mt-md-5 stereotaxicCategoryPage-products\">
  151.                 <div class=\"col-xl-8 offset-xl-2\">
  152.                     <div class=\"row align-items-start\">
  153.                         ";
  154.         // line 47
  155.         $context["fallbackImage"] = $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("static/images/admin/empty_image.png");
  156.         // line 48
  157.         yield "                        ";
  158.         $context['_parent'] = $context;
  159.         $context['_seq'] = CoreExtension::ensureTraversable((isset($context["documents"]) || array_key_exists("documents"$context) ? $context["documents"] : (function () { throw new RuntimeError('Variable "documents" does not exist.'48$this->source); })()));
  160.         $context['loop'] = [
  161.           'parent' => $context['_parent'],
  162.           'index0' => 0,
  163.           'index'  => 1,
  164.           'first'  => true,
  165.         ];
  166.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  167.             $length count($context['_seq']);
  168.             $context['loop']['revindex0'] = $length 1;
  169.             $context['loop']['revindex'] = $length;
  170.             $context['loop']['length'] = $length;
  171.             $context['loop']['last'] = === $length;
  172.         }
  173.         foreach ($context['_seq'] as $context["index"] => $context["page"]) {
  174.             // line 49
  175.             yield "                            ";
  176.             $context["image"] = ((CoreExtension::getAttribute($this->env$this->source$context["page"], "image", [], "array"falsefalsetrue49)) ? (CoreExtension::getAttribute($this->env$this->sourceCoreExtension::getAttribute($this->env$this->source$context["page"], "image", [], "array"falsefalsetrue49), "getThumbnail", ["Stoelting_neuroscience_circle"], "method"falsefalsetrue49)) : ((isset($context["fallbackImage"]) || array_key_exists("fallbackImage"$context) ? $context["fallbackImage"] : (function () { throw new RuntimeError('Variable "fallbackImage" does not exist.'49$this->source); })())));
  177.             // line 50
  178.             yield "
  179.                             <!-- include subtemplate 'category-item.html.twig' -->
  180.                             ";
  181.             // line 52
  182.             yield from             $this->loadTemplate("Components/category-item.html.twig""@FactorySupport/document/category_page/default.html.twig"52)->unwrap()->yield(CoreExtension::merge($context$context["page"]));
  183.             // line 53
  184.             yield "
  185.                         ";
  186.             ++$context['loop']['index0'];
  187.             ++$context['loop']['index'];
  188.             $context['loop']['first'] = false;
  189.             if (isset($context['loop']['length'])) {
  190.                 --$context['loop']['revindex0'];
  191.                 --$context['loop']['revindex'];
  192.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  193.             }
  194.         }
  195.         $_parent $context['_parent'];
  196.         unset($context['_seq'], $context['_iterated'], $context['index'], $context['page'], $context['_parent'], $context['loop']);
  197.         $context array_intersect_key($context$_parent) + $_parent;
  198.         // line 55
  199.         yield "                    </div>
  200.                 </div>
  201.             </div>
  202.         </div>
  203.     </main>
  204. ";
  205.         
  206.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  207.         
  208.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  209.         
  210.         $__internal_b91a4435ea3baf1e2b6bfda56133dace->leave($__internal_b91a4435ea3baf1e2b6bfda56133dace_prof);
  211.         return; yield '';
  212.     }
  213.     /**
  214.      * @codeCoverageIgnore
  215.      */
  216.     public function getTemplateName()
  217.     {
  218.         return "@FactorySupport/document/category_page/default.html.twig";
  219.     }
  220.     /**
  221.      * @codeCoverageIgnore
  222.      */
  223.     public function isTraitable()
  224.     {
  225.         return false;
  226.     }
  227.     /**
  228.      * @codeCoverageIgnore
  229.      */
  230.     public function getDebugInfo()
  231.     {
  232.         return array (  217 => 55,  202 => 53,  200 => 52,  196 => 50,  193 => 49,  175 => 48,  173 => 47,  163 => 39,  157 => 37,  151 => 35,  147 => 33,  145 => 32,  143 => 31,  141 => 30,  136 => 27,  130 => 25,  124 => 23,  120 => 21,  118 => 20,  116 => 19,  114 => 18,  110 => 16,  102 => 14,  96 => 12,  94 => 11,  91 => 10,  89 => 9,  80 => 4,  67 => 3,  38 => 1,);
  233.     }
  234.     public function getSourceContext()
  235.     {
  236.         return new Source("{% extends 'layout/default.html.twig' %}
  237. {% block contentBlock %}
  238. <main class=\"stereotaxicCategoryPage\" style=\"background-attachment: fixed;background-image: url({{ document.getProperty('template_background_image') ? document.getProperty('template_background_image').getThumbnail('Stoelting_division_bg') }}) ;\">
  239.         <div class=\"container mt-5 mt-lg-5 mt-md-5\">
  240.             <div class=\"row\">
  241.                 <div class=\"col-xl-10 offset-xl-1 offset-lg-0 col-lg-12 pb-3 pb-lg-3 pb-md-3\">
  242.                     <div class=\"d-flex align-items-center\">
  243.                         {% set anyMaze = 'any-maze' in document.getProperty('navigation_title') | lower %}
  244.                         <div class=\"category-breadcrumb-image mr-3 mr-lg-3 mr-md-3\">
  245.                             {% if editmode %}
  246.                                 {{ pimcore_image('categoryBreadcrumbImage') }}
  247.                             {% else %}
  248.                                 <img style=\"width:80px;\" src=\"{{ pimcore_image('categoryBreadcrumbImage').getThumbnail('Stoelting_category_breadcrumb') }}\" alt=\"{{ pimcore_image('categoryBreadcrumbImage').getAlt() }}\">
  249.                             {% endif %}
  250.                         </div>
  251.                         <h2 class=\"d-none d-md-inline font-weight-bold border-2 border-bottom border-indigo w-100 custom-bradcrumb-padding\">
  252.                             {% if editmode %}
  253.                                 {{ pimcore_input('categoryBreadcrumbHeading', {
  254.                                     placeholder: document.getProperty('navigation_title')
  255.                                 }) }}
  256.                             {% elseif not pimcore_input('categoryBreadcrumbHeading').isEmpty() %}
  257.                                 {{ pimcore_input('categoryBreadcrumbHeading') }}
  258.                             {% else %}
  259.                                 {{ document.getProperty('navigation_title') }}
  260.                             {% endif %}
  261.                         </h2>
  262.                         <!--* ON MOBILE H3-->
  263.                         <h3 class=\"d-inline d-md-none font-weight-bold border-2 border-bottom border-indigo w-100 custom-bradcrumb-padding\">
  264.                             {% if editmode %}
  265.                                 {{ pimcore_input('categoryBreadcrumbHeading--mobile', {
  266.                                     placeholder: document.getProperty('navigation_title')
  267.                                 }) }}
  268.                             {% elseif not pimcore_input('categoryBreadcrumbHeading--mobile').isEmpty() %}
  269.                                 {{ pimcore_input('categoryBreadcrumbHeading--mobile') }}
  270.                             {% else %}
  271.                                 {{ document.getProperty('navigation_title') }}
  272.                             {% endif %}
  273.                         </h3>
  274.                     </div>
  275.                 </div>
  276.             </div>
  277.             <div class=\"row mt-5 mt-lg-5 mt-md-5 stereotaxicCategoryPage-products\">
  278.                 <div class=\"col-xl-8 offset-xl-2\">
  279.                     <div class=\"row align-items-start\">
  280.                         {% set fallbackImage = asset('static/images/admin/empty_image.png') %}
  281.                         {% for index, page in documents %}
  282.                             {% set image = page['image'] ? page['image'].getThumbnail('Stoelting_neuroscience_circle') : fallbackImage %}
  283.                             <!-- include subtemplate 'category-item.html.twig' -->
  284.                             {% include \"Components/category-item.html.twig\" with page %}
  285.                         {% endfor %}
  286.                     </div>
  287.                 </div>
  288.             </div>
  289.         </div>
  290.     </main>
  291. {% endblock %}""@FactorySupport/document/category_page/default.html.twig""/var/www/webovi/stoelting/pimcore/templates/document/category_page/default.html.twig");
  292.     }
  293.     
  294.     public function checkSecurity()
  295.     {
  296.         static $tags = array("set" => 9"if" => 11"for" => 48"include" => 52);
  297.         static $filters = array("escape" => 4"lower" => 9);
  298.         static $functions = array("pimcore_image" => 12"pimcore_input" => 19"asset" => 47);
  299.         try {
  300.             $this->sandbox->checkSecurity(
  301.                 ['set''if''for''include'],
  302.                 ['escape''lower'],
  303.                 ['pimcore_image''pimcore_input''asset'],
  304.                 $this->source
  305.             );
  306.         } catch (SecurityError $e) {
  307.             $e->setSourceContext($this->source);
  308.             if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
  309.                 $e->setTemplateLine($tags[$e->getTagName()]);
  310.             } elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
  311.                 $e->setTemplateLine($filters[$e->getFilterName()]);
  312.             } elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
  313.                 $e->setTemplateLine($functions[$e->getFunctionName()]);
  314.             }
  315.             throw $e;
  316.         }
  317.     }
  318. }