<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
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;
/* includes/product-categories.html.twig */
class __TwigTemplate_334f910d48f3e1d70e619d29fbe03a19 extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->parent = false;
$this->blocks = [
];
$this->sandbox = $this->env->getExtension('\Twig\Extension\SandboxExtension');
$this->checkSecurity();
}
protected function doDisplay(array $context, array $blocks = [])
{
$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", "includes/product-categories.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "includes/product-categories.html.twig"));
// line 1
echo "<aside class=\"sidebar\">
<form id=\"js_filterfield\">
";
// line 3
if ((twig_length_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["filterDefinition"]) || array_key_exists("filterDefinition", $context) ? $context["filterDefinition"] : (function () { throw new RuntimeError('Variable "filterDefinition" does not exist.', 3, $this->source); })()), "filters", [], "any", false, false, true, 3)) > 0)) {
// line 4
echo " ";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, (isset($context["filterDefinition"]) || array_key_exists("filterDefinition", $context) ? $context["filterDefinition"] : (function () { throw new RuntimeError('Variable "filterDefinition" does not exist.', 4, $this->source); })()), "filters", [], "any", false, false, true, 4));
foreach ($context['_seq'] as $context["_key"] => $context["filter"]) {
// line 5
echo "
";
// line 6
$context["filterMarkup"] = twig_get_attribute($this->env, $this->source, (isset($context["filterService"]) || array_key_exists("filterService", $context) ? $context["filterService"] : (function () { throw new RuntimeError('Variable "filterService" does not exist.', 6, $this->source); })()), "filterFrontend", [$context["filter"], (isset($context["productListing"]) || array_key_exists("productListing", $context) ? $context["productListing"] : (function () { throw new RuntimeError('Variable "productListing" does not exist.', 6, $this->source); })()), (isset($context["currentFilter"]) || array_key_exists("currentFilter", $context) ? $context["currentFilter"] : (function () { throw new RuntimeError('Variable "currentFilter" does not exist.', 6, $this->source); })())], "method", false, false, true, 6);
// line 7
echo "
";
// line 8
echo $this->sandbox->ensureToStringAllowed((isset($context["filterMarkup"]) || array_key_exists("filterMarkup", $context) ? $context["filterMarkup"] : (function () { throw new RuntimeError('Variable "filterMarkup" does not exist.', 8, $this->source); })()), 8, $this->source);
echo "
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['filter'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 11
echo " ";
}
// line 12
echo "
";
// line 14
echo " ";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, twig_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.', 14, $this->source); })()), "request", [], "any", false, false, true, 14), "query", [], "any", false, false, true, 14));
foreach ($context['_seq'] as $context["key"] => $context["value"]) {
// line 15
echo " ";
if (((($context["key"] != "parentCategoryIds") && ($context["key"] != "page")) && ($context["key"] != "categoryTypes"))) {
// line 16
echo " ";
if (twig_test_iterable($context["value"])) {
// line 17
echo " ";
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable($context["value"]);
foreach ($context['_seq'] as $context["subkey"] => $context["subvalue"]) {
// line 18
echo " <input type=\"hidden\" name=\"";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed($context["key"], 18, $this->source), "html", null, true);
echo "[]\" value=\"";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed($context["subvalue"], 18, $this->source), "html", null, true);
echo "\">
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['subkey'], $context['subvalue'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 20
echo " ";
} else {
// line 21
echo " <input type=\"hidden\" name=\"";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed($context["key"], 21, $this->source), "html", null, true);
echo "\" value=\"";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed($context["value"], 21, $this->source), "html", null, true);
echo "\">
";
}
// line 23
echo " ";
}
// line 24
echo " ";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['key'], $context['value'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 25
echo " </form>
</aside>";
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
public function getTemplateName()
{
return "includes/product-categories.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 126 => 25, 120 => 24, 117 => 23, 109 => 21, 106 => 20, 95 => 18, 90 => 17, 87 => 16, 84 => 15, 79 => 14, 76 => 12, 73 => 11, 64 => 8, 61 => 7, 59 => 6, 56 => 5, 51 => 4, 49 => 3, 45 => 1,);
}
public function getSourceContext()
{
return new Source("<aside class=\"sidebar\">
<form id=\"js_filterfield\">
{% if(filterDefinition.filters|length > 0) %}
{% for filter in filterDefinition.filters %}
{% set filterMarkup = filterService.filterFrontend(filter, productListing, currentFilter) %}
{{ filterMarkup | raw }}
{% endfor %}
{% endif %}
{# Remember other query params #}
{% for key,value in app.request.query %}
{% if key != 'parentCategoryIds' and key != 'page' and key != 'categoryTypes' %}
{% if value is iterable %}
{% for subkey,subvalue in value %}
<input type=\"hidden\" name=\"{{ key }}[]\" value=\"{{ subvalue }}\">
{% endfor %}
{% else %}
<input type=\"hidden\" name=\"{{ key }}\" value=\"{{ value }}\">
{% endif %}
{% endif %}
{% endfor %}
</form>
</aside>", "includes/product-categories.html.twig", "/data/sites/web/devliegerfilipbe/subsites/dev.devliegerfilip.dspdev.be/templates/includes/product-categories.html.twig");
}
public function checkSecurity()
{
static $tags = array("if" => 3, "for" => 4, "set" => 6);
static $filters = array("length" => 3, "raw" => 8, "escape" => 18);
static $functions = array();
try {
$this->sandbox->checkSecurity(
['if', 'for', 'set'],
['length', 'raw', 'escape'],
[]
);
} catch (SecurityError $e) {
$e->setSourceContext($this->source);
if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
$e->setTemplateLine($tags[$e->getTagName()]);
} elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
$e->setTemplateLine($filters[$e->getFilterName()]);
} elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
$e->setTemplateLine($functions[$e->getFunctionName()]);
}
throw $e;
}
}
}