<?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;
/* @BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig */
class __TwigTemplate_bbfc55d6946aa784642933365971e666 extends \Twig\Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'content' => [$this, 'block_content'],
];
}
protected function doGetParent(array $context)
{
// line 1
return "@SyliusShop/layout.html.twig";
}
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", "@BitBagSyliusElasticsearchPlugin/Shop/Product/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", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig"));
// line 3
$this->env->getRuntime("Symfony\\Component\\Form\\FormRenderer")->setTheme((isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 3, $this->source); })()), [0 => "@SyliusUi/Form/theme.html.twig", 1 => "Context/Shop/ProductCategory/formTheme.html.twig"], true);
// line 5
$macros["messages"] = $this->macros["messages"] = $this->loadTemplate("@SyliusUi/Macro/messages.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 5)->unwrap();
// line 6
$macros["pagination"] = $this->macros["pagination"] = $this->loadTemplate("@SyliusUi/Macro/pagination.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 6)->unwrap();
// line 1
$this->parent = $this->loadTemplate("@SyliusShop/layout.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 1);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 8
public function block_content($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(), "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 9
echo " ";
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->renderBlock((isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 9, $this->source); })()), 'form_start', ["method" => "GET", "attr" => ["class" => "ui loadable form", "id" => "category-filters-form"]]);
echo "
";
// line 12
echo " ";
$this->loadTemplate("bundles/BitBagSyliusElasticsearchPlugin/Shop/Filters/mobileFilters.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 12)->display(twig_array_merge($context, ["filterForm" => (isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 12, $this->source); })())]));
// line 13
echo "
<div class=\"ui stackable grid\">
<div class=\"four wide column\">
";
// line 16
$this->loadTemplate("@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 16, "1283377628")->display(twig_array_merge($context, ["filterForm" => // line 17
(isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 17, $this->source); })()), "resetUrl" => $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("bitbag_sylius_elasticsearch_plugin_shop_list_products", ["slug" => twig_get_attribute($this->env, $this->source, // line 18
(isset($context["taxon"]) || array_key_exists("taxon", $context) ? $context["taxon"] : (function () { throw new RuntimeError('Variable "taxon" does not exist.', 18, $this->source); })()), "slug", [], "any", false, false, false, 18), "products" => $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("products"), "product_category" => $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("product_category"), "_locale" => 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.', 18, $this->source); })()), "request", [], "any", false, false, false, 18), "locale", [], "any", false, false, false, 18)])]));
// line 37
echo " </div>
<div class=\"twelve wide column\">
<h1 class=\"ui header category-page-header\">
";
// line 40
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["taxon"]) || array_key_exists("taxon", $context) ? $context["taxon"] : (function () { throw new RuntimeError('Variable "taxon" does not exist.', 40, $this->source); })()), "name", [], "any", false, false, false, 40), "html", null, true);
echo "
</h1>
";
// line 42
echo $this->extensions['BitBag\OpenMarketplace\Component\Core\Common\Twig\RenderBannerExtension']->renderBanner("Context/Shop/Blog/banner.html.twig");
echo "
";
// line 43
$this->loadTemplate("Context/Common/Banner/_categoryBanner.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 43)->display($context);
// line 44
echo " <div class=\"sub header expandable-content-container\">
<span class=\"expandable-content text-sm\">";
// line 45
echo twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["taxon"]) || array_key_exists("taxon", $context) ? $context["taxon"] : (function () { throw new RuntimeError('Variable "taxon" does not exist.', 45, $this->source); })()), "description", [], "any", false, false, false, 45), "html", null, true);
echo "</span>
</div>
<div class=\"ui divider\"></div>
<div class=\"ui segment product-listing-sorting-bar no-border no-background no-shadow\">
<div class=\"ui stackable grid\">
<div class=\"eleven wide column no-padding no-border\">
";
// line 59
echo " </div>
<div class=\"five wide column no-padding no-border sorting-buttons\">
";
// line 61
$this->loadTemplate("@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_sorting.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 61)->display($context);
// line 62
echo " ";
$this->loadTemplate("@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_pagination.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 62)->display($context);
// line 63
echo " </div>
</div>
</div>
";
// line 67
if ((twig_length_filter($this->env, (isset($context["products"]) || array_key_exists("products", $context) ? $context["products"] : (function () { throw new RuntimeError('Variable "products" does not exist.', 67, $this->source); })())) > 0)) {
// line 68
echo " <div class=\"category-products-grid\" id=\"products\">
";
// line 69
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["products"]) || array_key_exists("products", $context) ? $context["products"] : (function () { throw new RuntimeError('Variable "products" does not exist.', 69, $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["product"]) {
// line 70
echo " ";
$this->loadTemplate("@SyliusShop/Product/_box.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 70)->display($context);
// line 71
echo " ";
++$context['loop']['index0'];
++$context['loop']['index'];
$context['loop']['first'] = false;
if (isset($context['loop']['length'])) {
--$context['loop']['revindex0'];
--$context['loop']['revindex'];
$context['loop']['last'] = 0 === $context['loop']['revindex0'];
}
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['product'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 72
echo " </div>
<div class=\"ui hidden divider\"></div>
";
// line 75
echo twig_call_macro($macros["pagination"], "macro_simple", [(isset($context["products"]) || array_key_exists("products", $context) ? $context["products"] : (function () { throw new RuntimeError('Variable "products" does not exist.', 75, $this->source); })())], 75, $context, $this->getSourceContext());
echo "
";
} else {
// line 77
echo " ";
echo twig_call_macro($macros["messages"], "macro_info", ["sylius.ui.no_results_to_display"], 77, $context, $this->getSourceContext());
echo "
";
}
// line 79
echo " </div>
</div>
<button type=\"submit\" style=\"display: none\">
<i class=\"search icon\"></i>
";
// line 83
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("bitbag_sylius_elasticsearch_plugin.ui.filter"), "html", null, true);
echo "
</button>
";
// line 85
echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->renderBlock((isset($context["form"]) || array_key_exists("form", $context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.', 85, $this->source); })()), 'form_end', ["render_rest" => false]);
echo "
<script>
window.translations = {
readMore: \"";
// line 89
echo twig_escape_filter($this->env, twig_lower_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("app.ui.read_more")), "html", null, true);
echo "\",
readLess: \"";
// line 90
echo twig_escape_filter($this->env, twig_lower_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("app.ui.read_less")), "html", null, true);
echo "\"
};
document.addEventListener('DOMContentLoaded', () => {
const form = document.getElementById('category-filters-form');
if (!form) {
return;
}
const shouldDisable = (el) => {
if (el.disabled) {
return false;
}
if (el.type === 'checkbox' || el.type === 'radio') {
return !el.checked;
}
if (el.tagName === 'SELECT' && el.multiple) {
return el.selectedOptions.length === 0;
}
return el.value === '' || el.value === null;
};
form.addEventListener('submit', () => {
form.querySelectorAll('input, select, textarea').forEach((el) => {
if (shouldDisable(el)) {
el.disabled = true;
}
});
});
});
</script>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
public function getTemplateName()
{
return "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 214 => 90, 210 => 89, 203 => 85, 198 => 83, 192 => 79, 186 => 77, 181 => 75, 176 => 72, 162 => 71, 159 => 70, 142 => 69, 139 => 68, 137 => 67, 131 => 63, 128 => 62, 126 => 61, 122 => 59, 112 => 45, 109 => 44, 107 => 43, 103 => 42, 98 => 40, 93 => 37, 91 => 18, 90 => 17, 89 => 16, 84 => 13, 81 => 12, 75 => 9, 65 => 8, 54 => 1, 52 => 6, 50 => 5, 48 => 3, 35 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends '@SyliusShop/layout.html.twig' %}
{% form_theme form with ['@SyliusUi/Form/theme.html.twig', 'Context/Shop/ProductCategory/formTheme.html.twig'] %}
{% import '@SyliusUi/Macro/messages.html.twig' as messages %}
{% import '@SyliusUi/Macro/pagination.html.twig' as pagination %}
{% block content %}
{{ form_start(form, {'method': 'GET', 'attr': {'class': 'ui loadable form', 'id': 'category-filters-form'}}) }}
{# Mobile Filter Toggle Button #}
{% include 'bundles/BitBagSyliusElasticsearchPlugin/Shop/Filters/mobileFilters.twig' with {'filterForm': form} %}
<div class=\"ui stackable grid\">
<div class=\"four wide column\">
{% embed 'bundles/BitBagSyliusElasticsearchPlugin/Shop/Filters/filters.twig' with {
'filterForm': form,
'resetUrl': path('bitbag_sylius_elasticsearch_plugin_shop_list_products', {'slug': taxon.slug, 'products': 'products'|trans, 'product_category': 'product_category'|trans, '_locale': app.request.locale})
} %}
{% block formContent %}
{% include '@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_filterForm.html.twig' %}
{% endblock %}
{% block extraFilters %}
<div class=\"ui accordion filters-accordion\">
<div class=\"title no-padding\">
<div class=\"header item\">
{{ 'app.ui.price_range'|trans }}
<i class=\"dropdown icon\" style=\"margin-inline-start: auto;\"></i>
</div>
</div>
<div class=\"content no-padding\">
{% include '@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_filterPrice.html.twig' %}
</div>
</div>
{% endblock %}
{% endembed %}
</div>
<div class=\"twelve wide column\">
<h1 class=\"ui header category-page-header\">
{{ taxon.name }}
</h1>
{{ bitbag_cms_render_banner('Context/Shop/Blog/banner.html.twig') }}
{% include 'Context/Common/Banner/_categoryBanner.html.twig' %}
<div class=\"sub header expandable-content-container\">
<span class=\"expandable-content text-sm\">{{ taxon.description }}</span>
</div>
<div class=\"ui divider\"></div>
<div class=\"ui segment product-listing-sorting-bar no-border no-background no-shadow\">
<div class=\"ui stackable grid\">
<div class=\"eleven wide column no-padding no-border\">
{# Product search disabled due to performance issues - needs optimization before re-enabling
{# <div class=\"ui search max-width-350\" id=\"products-search\">
<div class=\"ui fluid left icon input input-bg\">
{{ form_widget(form.name, {'attr': {'placeholder': 'sylius.ui.search', 'class': 'prompt'}}) }}
<i class=\"search icon\"></i>
</div>
</div> #}
</div>
<div class=\"five wide column no-padding no-border sorting-buttons\">
{% include '@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_sorting.html.twig' %}
{% include '@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_pagination.html.twig' %}
</div>
</div>
</div>
{% if products|length > 0 %}
<div class=\"category-products-grid\" id=\"products\">
{% for product in products %}
{% include '@SyliusShop/Product/_box.html.twig' %}
{% endfor %}
</div>
<div class=\"ui hidden divider\"></div>
{{ pagination.simple(products) }}
{% else %}
{{ messages.info('sylius.ui.no_results_to_display') }}
{% endif %}
</div>
</div>
<button type=\"submit\" style=\"display: none\">
<i class=\"search icon\"></i>
{{ 'bitbag_sylius_elasticsearch_plugin.ui.filter'|trans }}
</button>
{{ form_end(form, {'render_rest': false}) }}
<script>
window.translations = {
readMore: \"{{ 'app.ui.read_more'|trans|lower }}\",
readLess: \"{{ 'app.ui.read_less'|trans|lower }}\"
};
document.addEventListener('DOMContentLoaded', () => {
const form = document.getElementById('category-filters-form');
if (!form) {
return;
}
const shouldDisable = (el) => {
if (el.disabled) {
return false;
}
if (el.type === 'checkbox' || el.type === 'radio') {
return !el.checked;
}
if (el.tagName === 'SELECT' && el.multiple) {
return el.selectedOptions.length === 0;
}
return el.value === '' || el.value === null;
};
form.addEventListener('submit', () => {
form.querySelectorAll('input, select, textarea').forEach((el) => {
if (shouldDisable(el)) {
el.disabled = true;
}
});
});
});
</script>
{% endblock %}
", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", "/srv/open_marketplace/templates/bundles/BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig");
}
}
/* @BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig */
class __TwigTemplate_bbfc55d6946aa784642933365971e666___1283377628 extends \Twig\Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'formContent' => [$this, 'block_formContent'],
'extraFilters' => [$this, 'block_extraFilters'],
];
}
protected function doGetParent(array $context)
{
// line 16
return "bundles/BitBagSyliusElasticsearchPlugin/Shop/Filters/filters.twig";
}
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", "@BitBagSyliusElasticsearchPlugin/Shop/Product/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", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig"));
$this->parent = $this->loadTemplate("bundles/BitBagSyliusElasticsearchPlugin/Shop/Filters/filters.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 16);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 20
public function block_formContent($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(), "block", "formContent"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "formContent"));
// line 21
echo " ";
$this->loadTemplate("@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_filterForm.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 21)->display($context);
// line 22
echo " ";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
// line 23
public function block_extraFilters($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(), "block", "extraFilters"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "extraFilters"));
// line 24
echo " <div class=\"ui accordion filters-accordion\">
<div class=\"title no-padding\">
<div class=\"header item\">
";
// line 27
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("app.ui.price_range"), "html", null, true);
echo "
<i class=\"dropdown icon\" style=\"margin-inline-start: auto;\"></i>
</div>
</div>
<div class=\"content no-padding\">
";
// line 32
$this->loadTemplate("@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_filterPrice.html.twig", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", 32)->display($context);
// line 33
echo " </div>
</div>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
public function getTemplateName()
{
return "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 496 => 33, 494 => 32, 486 => 27, 481 => 24, 471 => 23, 461 => 22, 458 => 21, 448 => 20, 425 => 16, 214 => 90, 210 => 89, 203 => 85, 198 => 83, 192 => 79, 186 => 77, 181 => 75, 176 => 72, 162 => 71, 159 => 70, 142 => 69, 139 => 68, 137 => 67, 131 => 63, 128 => 62, 126 => 61, 122 => 59, 112 => 45, 109 => 44, 107 => 43, 103 => 42, 98 => 40, 93 => 37, 91 => 18, 90 => 17, 89 => 16, 84 => 13, 81 => 12, 75 => 9, 65 => 8, 54 => 1, 52 => 6, 50 => 5, 48 => 3, 35 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends '@SyliusShop/layout.html.twig' %}
{% form_theme form with ['@SyliusUi/Form/theme.html.twig', 'Context/Shop/ProductCategory/formTheme.html.twig'] %}
{% import '@SyliusUi/Macro/messages.html.twig' as messages %}
{% import '@SyliusUi/Macro/pagination.html.twig' as pagination %}
{% block content %}
{{ form_start(form, {'method': 'GET', 'attr': {'class': 'ui loadable form', 'id': 'category-filters-form'}}) }}
{# Mobile Filter Toggle Button #}
{% include 'bundles/BitBagSyliusElasticsearchPlugin/Shop/Filters/mobileFilters.twig' with {'filterForm': form} %}
<div class=\"ui stackable grid\">
<div class=\"four wide column\">
{% embed 'bundles/BitBagSyliusElasticsearchPlugin/Shop/Filters/filters.twig' with {
'filterForm': form,
'resetUrl': path('bitbag_sylius_elasticsearch_plugin_shop_list_products', {'slug': taxon.slug, 'products': 'products'|trans, 'product_category': 'product_category'|trans, '_locale': app.request.locale})
} %}
{% block formContent %}
{% include '@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_filterForm.html.twig' %}
{% endblock %}
{% block extraFilters %}
<div class=\"ui accordion filters-accordion\">
<div class=\"title no-padding\">
<div class=\"header item\">
{{ 'app.ui.price_range'|trans }}
<i class=\"dropdown icon\" style=\"margin-inline-start: auto;\"></i>
</div>
</div>
<div class=\"content no-padding\">
{% include '@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_filterPrice.html.twig' %}
</div>
</div>
{% endblock %}
{% endembed %}
</div>
<div class=\"twelve wide column\">
<h1 class=\"ui header category-page-header\">
{{ taxon.name }}
</h1>
{{ bitbag_cms_render_banner('Context/Shop/Blog/banner.html.twig') }}
{% include 'Context/Common/Banner/_categoryBanner.html.twig' %}
<div class=\"sub header expandable-content-container\">
<span class=\"expandable-content text-sm\">{{ taxon.description }}</span>
</div>
<div class=\"ui divider\"></div>
<div class=\"ui segment product-listing-sorting-bar no-border no-background no-shadow\">
<div class=\"ui stackable grid\">
<div class=\"eleven wide column no-padding no-border\">
{# Product search disabled due to performance issues - needs optimization before re-enabling
{# <div class=\"ui search max-width-350\" id=\"products-search\">
<div class=\"ui fluid left icon input input-bg\">
{{ form_widget(form.name, {'attr': {'placeholder': 'sylius.ui.search', 'class': 'prompt'}}) }}
<i class=\"search icon\"></i>
</div>
</div> #}
</div>
<div class=\"five wide column no-padding no-border sorting-buttons\">
{% include '@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_sorting.html.twig' %}
{% include '@BitBagSyliusElasticsearchPlugin/Shop/Product/Index/_pagination.html.twig' %}
</div>
</div>
</div>
{% if products|length > 0 %}
<div class=\"category-products-grid\" id=\"products\">
{% for product in products %}
{% include '@SyliusShop/Product/_box.html.twig' %}
{% endfor %}
</div>
<div class=\"ui hidden divider\"></div>
{{ pagination.simple(products) }}
{% else %}
{{ messages.info('sylius.ui.no_results_to_display') }}
{% endif %}
</div>
</div>
<button type=\"submit\" style=\"display: none\">
<i class=\"search icon\"></i>
{{ 'bitbag_sylius_elasticsearch_plugin.ui.filter'|trans }}
</button>
{{ form_end(form, {'render_rest': false}) }}
<script>
window.translations = {
readMore: \"{{ 'app.ui.read_more'|trans|lower }}\",
readLess: \"{{ 'app.ui.read_less'|trans|lower }}\"
};
document.addEventListener('DOMContentLoaded', () => {
const form = document.getElementById('category-filters-form');
if (!form) {
return;
}
const shouldDisable = (el) => {
if (el.disabled) {
return false;
}
if (el.type === 'checkbox' || el.type === 'radio') {
return !el.checked;
}
if (el.tagName === 'SELECT' && el.multiple) {
return el.selectedOptions.length === 0;
}
return el.value === '' || el.value === null;
};
form.addEventListener('submit', () => {
form.querySelectorAll('input, select, textarea').forEach((el) => {
if (shouldDisable(el)) {
el.disabled = true;
}
});
});
});
</script>
{% endblock %}
", "@BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig", "/srv/open_marketplace/templates/bundles/BitBagSyliusElasticsearchPlugin/Shop/Product/index.html.twig");
}
}