<?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;
/* products-detail.html.twig */
class __TwigTemplate_08643f3329158c8cc9487716086f58ff extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'content' => [$this, 'block_content'],
];
$this->sandbox = $this->env->getExtension('\Twig\Extension\SandboxExtension');
$this->checkSecurity();
}
protected function doGetParent(array $context)
{
// line 1
return "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", "products-detail.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "products-detail.html.twig"));
$this->parent = $this->loadTemplate("layout.html.twig", "products-detail.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 3
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 4
echo "
";
// line 5
$this->loadTemplate("includes/breadcrumb.html.twig", "products-detail.html.twig", 5)->display($context);
// line 6
echo "
";
// line 7
$context["category"] = ((twig_test_iterable(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 7, $this->source); })()), "categories", [], "any", false, false, true, 7))) ? (twig_first($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 7, $this->source); })()), "categories", [], "any", false, false, true, 7), 7, $this->source))) : (false));
// line 8
echo "
<section class=\"section-filter\">
<div class=\"container-fluid\">
<div class=\"row align-items-center\">
<div class=\"col-auto\">
";
// line 13
if ((isset($context["category"]) || array_key_exists("category", $context) ? $context["category"] : (function () { throw new RuntimeError('Variable "category" does not exist.', 13, $this->source); })())) {
// line 14
echo " <p class=\"h1\">";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["category"]) || array_key_exists("category", $context) ? $context["category"] : (function () { throw new RuntimeError('Variable "category" does not exist.', 14, $this->source); })()), "name", [], "any", false, false, true, 14), 14, $this->source), "html", null, true);
echo "</p>
";
}
// line 16
echo " </div>
";
// line 37
echo " </div><!--/ .row -->
</div><!--/ .container -->
</section>
<section class=\"section-products\">
<div class=\"container-fluid\">
<div class=\"container-inner\">
<div class=\"row\">
<div class=\"col-auto\">
<h1 class=\"h2 mb-1\">";
// line 46
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 46, $this->source); })()), "name", [], "any", false, false, true, 46), 46, $this->source), "html", null, true);
echo "</h1>
";
// line 48
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 48, $this->source); })()), "onOrder", [], "any", false, false, true, 48)) {
// line 49
echo " <span class=\"badge bg-danger\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Op bestelling!"), "html", null, true);
echo "</span>
";
}
// line 51
echo "
<p class=\"text-primary mb-5\">";
// line 52
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Code"), "html", null, true);
echo ": ";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 52, $this->source); })()), "code", [], "any", false, false, true, 52), 52, $this->source), "html", null, true);
echo " — ";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Merk"), "html", null, true);
echo ": ";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 52, $this->source); })()), "brand", [], "any", false, false, true, 52), 52, $this->source), "html", null, true);
echo " ";
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 52, $this->source); })()), "categoryTypes", [], "any", false, false, true, 52)) {
echo " — ";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Categorietype"), "html", null, true);
echo ": ";
echo twig_escape_filter($this->env, twig_join_filter(twig_array_map($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 52, $this->source); })()), "categoryTypes", [], "any", false, false, true, 52), 52, $this->source), function ($__t__) use ($context, $macros) { $context["t"] = $__t__; return twig_get_attribute($this->env, $this->source, (isset($context["t"]) || array_key_exists("t", $context) ? $context["t"] : (function () { throw new RuntimeError('Variable "t" does not exist.', 52, $this->source); })()), "name", [], "any", false, false, true, 52); }), ", "), "html", null, true);
}
echo "</p>
</div>
<div class=\"col-auto ms-auto\">
<favorite-button
product-id=\"";
// line 57
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 57, $this->source); })()), "id", [], "any", false, false, true, 57), 57, $this->source), "html", null, true);
echo "\"
:is-current-favorite=\"";
// line 58
echo ((twig_in_filter(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 58, $this->source); })()), "id", [], "any", false, false, true, 58), (isset($context["favoriteIds"]) || array_key_exists("favoriteIds", $context) ? $context["favoriteIds"] : (function () { throw new RuntimeError('Variable "favoriteIds" does not exist.', 58, $this->source); })()))) ? ("true") : ("false"));
echo "\"
></favorite-button>
</div>
<favorite-modal></favorite-modal>
</div>
<div class=\"row\">
<div class=\"col-lg-3\">
";
// line 68
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 68, $this->source); })()), "images", [], "any", false, false, true, 68)) {
// line 69
echo " ";
$context["imageList"] = $this->extensions['App\Twig\Extension\GeneralExtension']->jsonDecode($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 69, $this->source); })()), "images", [], "any", false, false, true, 69), 69, $this->source));
// line 70
echo "
<div class=\"product-detail-images\">
<!-- swiper -->
<div id=\"detail-slider\" class=\"swiper swiper--detail\">
<div class=\"swiper-wrapper\">
";
// line 75
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["imageList"]) || array_key_exists("imageList", $context) ? $context["imageList"] : (function () { throw new RuntimeError('Variable "imageList" does not exist.', 75, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["photo"]) {
// line 76
echo " <div class=\"swiper-slide\">
<a href=\"";
// line 77
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["photo"], "lightboxImage", [], "any", false, false, true, 77), 77, $this->source), "html", null, true);
echo "\" class=\"product-lightbox\"
data-glightbox=\"type: image\">
<img class=\"img-fluid\" src=\"";
// line 79
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["photo"], "thumbnailImage", [], "any", false, false, true, 79), 79, $this->source), "html", null, true);
echo "\" alt=\"\">
</a>
</div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['photo'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 83
echo " </div>
<div class=\"swiper-button-prev\"></div>
<div class=\"swiper-button-next\"></div>
</div><!--/ .swiper -->
<!-- swiper -->
<div class=\"swiper swiper--detail-thumbs\" id=\"detail-thumbs-slider\">
<div class=\"swiper-wrapper\">
";
// line 92
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["imageList"]) || array_key_exists("imageList", $context) ? $context["imageList"] : (function () { throw new RuntimeError('Variable "imageList" does not exist.', 92, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["photo"]) {
// line 93
echo "
<div class=\"swiper-slide\">
<img class=\"img-fluid\" src=\"";
// line 95
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["photo"], "thumbnailImage", [], "any", false, false, true, 95), 95, $this->source), "html", null, true);
echo "\" alt=\"\">
</div>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['photo'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 98
echo " </div>
</div><!--/ .swiper -->
</div>
";
} else {
// line 102
echo "
<div class=\"img-wrapper placeholder-img\">
<img src=\"";
// line 104
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl("/img/placeholder.png"), "html", null, true);
echo "\" alt=\"\" class=\"img-fluid w-100\">
</div>
";
}
// line 107
echo "
";
// line 108
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 108, $this->source); })()), "productsheet", [], "any", false, false, true, 108)) {
// line 109
echo " <div class=\"row\">
<div class=\"productsheet\">
<a class=\"btn btn-hyperlink icon-link\" href=\"";
// line 111
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 111, $this->source); })()), "productsheet", [], "any", false, false, true, 111), 111, $this->source), "html", null, true);
echo "\" target=\"_blank\">
";
// line 112
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Bekijk productfiche"), "html", null, true);
echo "
<i class=\"icon-link-ext\"></i>
</a>
</div>
</div><!--/ .row -->
";
}
// line 118
echo " </div>
<div class=\"col-lg-8 offset-lg-1\">
<div class=\"row\">
<div class=\"col-auto\">
<div class=\"product-detail-price\">
";
// line 124
if ( !twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 124, $this->source); })()), "OSPrice", [], "any", false, false, true, 124), "getAmount", [], "any", false, false, true, 124), "isZero", [], "any", false, false, true, 124)) {
// line 125
echo " <div class=\"price ";
if ((((twig_get_attribute($this->env, $this->source, // line 126
(isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 126, $this->source); })()), "promoDate1", [], "any", false, false, true, 126) && twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 126, $this->source); })()), "promoDate2", [], "any", false, false, true, 126)) && (twig_date_converter($this->env, twig_get_attribute($this->env, $this->source, // line 127
(isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 127, $this->source); })()), "promoDate1", [], "any", false, false, true, 127)) < twig_date_converter($this->env))) && (twig_date_converter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 127, $this->source); })()), "promoDate2", [], "any", false, false, true, 127)) > twig_date_converter($this->env)))) {
// line 128
echo " price--promo
";
}
// line 129
echo "\">";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 129, $this->source); })()), "OSPrice", [], "any", false, false, true, 129), 129, $this->source), "html", null, true);
echo "<small class=\"price-unit\">/";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 129, $this->source); })()), "unit", [], "any", false, false, true, 129), 129, $this->source), "html", null, true);
echo "</small>
</div>
";
// line 131
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 131, $this->source); })()), "discount", [], "any", false, false, true, 131)) {
// line 132
echo " ";
if ((twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 132, $this->source); })()), "OSPrice", [], "any", false, false, true, 132) != twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 132, $this->source); })()), "OSDefaultPrice", [], "any", false, false, true, 132))) {
// line 133
echo " <p class=\"old-price\">";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 133, $this->source); })()), "OSDefaultPrice", [], "any", false, false, true, 133), 133, $this->source), "html", null, true);
echo "</p>
";
}
// line 135
echo " <div class=\"promo\">-";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 135, $this->source); })()), "discount", [], "any", false, false, true, 135), 135, $this->source), "html", null, true);
echo "%</div>
";
}
// line 137
echo "
";
}
// line 139
echo " ";
if ((((twig_get_attribute($this->env, $this->source, // line 140
(isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 140, $this->source); })()), "promoDate1", [], "any", false, false, true, 140) && twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 140, $this->source); })()), "promoDate2", [], "any", false, false, true, 140)) && (twig_date_converter($this->env, twig_get_attribute($this->env, $this->source, // line 141
(isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 141, $this->source); })()), "promoDate1", [], "any", false, false, true, 141)) < twig_date_converter($this->env))) && (twig_date_converter($this->env, twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 141, $this->source); })()), "promoDate2", [], "any", false, false, true, 141)) > twig_date_converter($this->env)))) {
// line 142
echo " ";
// line 143
echo " ";
if (twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 143, $this->source); })()), "OSPrice", [], "any", false, false, true, 143), "getAmount", [], "any", false, false, true, 143), "isZero", [], "any", false, false, true, 143)) {
// line 144
echo " ";
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 144, $this->source); })()), "promoPrice", [], "any", false, false, true, 144)) {
// line 145
echo " <div class=\"price price--promo\">";
echo twig_escape_filter($this->env, $this->extensions['App\Twig\Extension\CurrencyExtension']->format($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 145, $this->source); })()), "promoPrice", [], "any", false, false, true, 145), 145, $this->source)), "html", null, true);
echo "
<small class=\"price-unit\">/";
// line 146
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 146, $this->source); })()), "unit", [], "any", false, false, true, 146), 146, $this->source), "html", null, true);
echo "</small></div>
";
}
// line 148
echo " ";
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 148, $this->source); })()), "promoPercentage", [], "any", false, false, true, 148)) {
// line 149
echo " <div class=\"promo\">-";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 149, $this->source); })()), "promoPercentage", [], "any", false, false, true, 149), 149, $this->source), "html", null, true);
echo "%</div>
";
}
// line 151
echo " ";
}
// line 152
echo "
<p class=\"date\">
(";
// line 154
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Promotie vanaf"), "html", null, true);
echo " ";
echo twig_escape_filter($this->env, twig_date_format_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 154, $this->source); })()), "promoDate1", [], "any", false, false, true, 154), 154, $this->source), "d/m/Y"), "html", null, true);
echo " ";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("tot"), "html", null, true);
echo " ";
echo twig_escape_filter($this->env, twig_date_format_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 154, $this->source); })()), "promoDate2", [], "any", false, false, true, 154), 154, $this->source), "d/m/Y"), "html", null, true);
echo "
)</p>
";
}
// line 157
echo " </div>
</div>
<div class=\"col-auto ms-auto\">
<add-to-cart
product-id=\"";
// line 162
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 162, $this->source); })()), "id", [], "any", false, false, true, 162), 162, $this->source), "html", null, true);
echo "\"
unit=\"";
// line 163
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 163, $this->source); })()), "unit", [], "any", false, false, true, 163), 163, $this->source), "html", null, true);
echo "\"
minimum-unit=\"";
// line 164
echo twig_escape_filter($this->env, (0 + twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 164, $this->source); })()), "unitMinimum", [], "any", false, false, true, 164)), "html", null, true);
echo "\"
amount-in-cart=\"";
// line 165
(((twig_get_attribute($this->env, $this->source, ($context["cartItems"] ?? null), twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 165, $this->source); })()), "id", [], "any", false, false, true, 165), [], "array", true, true, true, 165) && !(null === twig_get_attribute($this->env, $this->source, ($context["cartItems"] ?? null), twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 165, $this->source); })()), "id", [], "any", false, false, true, 165), [], "array", false, false, true, 165)))) ? (print (twig_escape_filter($this->env, twig_get_attribute($this->env, $this->source, ($context["cartItems"] ?? null), twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 165, $this->source); })()), "id", [], "any", false, false, true, 165), [], "array", false, false, true, 165), "html", null, true))) : (print (0)));
echo "\"
></add-to-cart>
</div>
</div><!--/ .row -->
";
// line 170
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 170, $this->source); })()), "onOrder", [], "any", false, false, true, 170)) {
// line 171
echo " ";
$context["orderMessage"] = $this->extensions['App\Twig\Extension\ProductRankingExtension']->getProductOrderMessage($this->sandbox->ensureToStringAllowed((isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 171, $this->source); })()), 171, $this->source));
// line 172
echo " ";
if ((isset($context["orderMessage"]) || array_key_exists("orderMessage", $context) ? $context["orderMessage"] : (function () { throw new RuntimeError('Variable "orderMessage" does not exist.', 172, $this->source); })())) {
// line 173
echo " <div class=\"alert alert-warning d-flex align-items-start\" role=\"alert\">
<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"18\" height=\"18\" viewBox=\"0 0 16 16\" fill=\"currentColor\" class=\"flex-shrink-0 me-2 mt-1\" aria-hidden=\"true\">
<path d=\"M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16zm.93-9.412-1 4.705c-.07.34.029.533.304.533.194 0 .487-.07.686-.246l-.088.416c-.286.346-.92.598-1.465.598-.703 0-1.002-.422-.808-1.319l.738-3.468c.064-.293.006-.399-.287-.47l-.451-.081.082-.381 2.29-.287zM8 5.5a1 1 0 1 1 0-2 1 1 0 0 1 0 2z\"/>
</svg>
<span style=\"white-space: pre-wrap;\">";
// line 177
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed((isset($context["orderMessage"]) || array_key_exists("orderMessage", $context) ? $context["orderMessage"] : (function () { throw new RuntimeError('Variable "orderMessage" does not exist.', 177, $this->source); })()), 177, $this->source), "html", null, true);
echo "</span>
</div>
";
}
// line 180
echo " ";
}
// line 181
echo "
";
// line 182
$context["default_tab"] = null;
// line 183
echo "
<ul class=\"nav nav--tabs\" id=\"nav-tab\" role=\"tablist\">
";
// line 185
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 185, $this->source); })()), "ingredients", [], "any", false, false, true, 185)) {
// line 186
echo " ";
$context["default_tab"] = 1;
// line 187
echo " <li class=\"nav-item\">
<button class=\"nav-link ";
// line 188
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 188, $this->source); })()) == 1)) ? ("active") : (""));
echo "\" id=\"nav-tab-1\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-1\" role=\"tab\"
aria-selected=\"true\">";
// line 190
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Ingrediënten"), "html", null, true);
echo "</button>
</li>
";
}
// line 193
echo "
";
// line 194
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 194, $this->source); })()), "description", [], "any", false, false, true, 194)) {
// line 195
echo " ";
$context["default_tab"] = (((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 195, $this->source); })())) ? ((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 195, $this->source); })())) : (2));
// line 196
echo " <li class=\"nav-item\">
<button class=\"nav-link ";
// line 197
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 197, $this->source); })()) == 2)) ? ("active") : (""));
echo "\" id=\"nav-tab-2\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-2\" role=\"tab\"
aria-selected=\"true\">";
// line 199
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Omschrijving"), "html", null, true);
echo "</button>
</li>
";
}
// line 202
echo "
";
// line 203
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 203, $this->source); })()), "nutrients", [], "any", false, false, true, 203)) {
// line 204
echo " ";
$context["default_tab"] = (((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 204, $this->source); })())) ? ((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 204, $this->source); })())) : (3));
// line 205
echo " <li class=\"nav-item\">
<button class=\"nav-link ";
// line 206
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 206, $this->source); })()) == 3)) ? ("active") : (""));
echo "\" id=\"nav-tab-3\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-3\" role=\"tab\"
aria-selected=\"false\">";
// line 208
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Voedingswaarde"), "html", null, true);
echo "</button>
</li>
";
}
// line 211
echo "
";
// line 212
if (((isset($context["allergens"]) || array_key_exists("allergens", $context) ? $context["allergens"] : (function () { throw new RuntimeError('Variable "allergens" does not exist.', 212, $this->source); })()) && (twig_length_filter($this->env, (isset($context["allergens"]) || array_key_exists("allergens", $context) ? $context["allergens"] : (function () { throw new RuntimeError('Variable "allergens" does not exist.', 212, $this->source); })())) > 0))) {
// line 213
echo " ";
$context["default_tab"] = (((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 213, $this->source); })())) ? ((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 213, $this->source); })())) : (4));
// line 214
echo " <li class=\"nav-item\">
<button class=\"nav-link ";
// line 215
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 215, $this->source); })()) == 4)) ? ("active") : (""));
echo "\" id=\"nav-tab-4\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-4\" role=\"tab\"
aria-selected=\"false\">";
// line 217
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Wettelijke allergenen"), "html", null, true);
echo "</button>
</li>
";
}
// line 220
echo "
";
// line 221
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 221, $this->source); })()), "psinfoodDocuments", [], "any", false, false, true, 221)) {
// line 222
echo " ";
$context["default_tab"] = (((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 222, $this->source); })())) ? ((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 222, $this->source); })())) : (5));
// line 223
echo " <li class=\"nav-item\">
<button class=\"nav-link ";
// line 224
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 224, $this->source); })()) == 5)) ? ("active") : (""));
echo "\" id=\"nav-tab-5\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-5\" role=\"tab\"
aria-selected=\"false\">";
// line 226
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Documenten"), "html", null, true);
echo "</button>
</li>
";
}
// line 229
echo " </ul>
<div class=\"tab-content\" id=\"tab-content\">
";
// line 232
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 232, $this->source); })()), "ingredients", [], "any", false, false, true, 232)) {
// line 233
echo " <div class=\"tab-pane fade ";
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 233, $this->source); })()) == 1)) ? ("show active") : (""));
echo "\" id=\"tab-1\"
aria-labelledby=\"nav-tab-1\" role=\"tabpanel\">
";
// line 235
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 235, $this->source); })()), "ingredients", [], "any", false, false, true, 235), 235, $this->source), "html", null, true);
echo "
</div>
";
}
// line 238
echo "
";
// line 239
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 239, $this->source); })()), "description", [], "any", false, false, true, 239)) {
// line 240
echo " <div class=\"tab-pane fade ";
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 240, $this->source); })()) == 2)) ? ("show active") : (""));
echo "\" id=\"tab-2\"
aria-labelledby=\"nav-tab-2\" role=\"tabpanel\">
";
// line 242
echo twig_nl2br($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 242, $this->source); })()), "description", [], "any", false, false, true, 242), 242, $this->source));
echo "
</div>
";
}
// line 245
echo "
";
// line 246
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 246, $this->source); })()), "nutrients", [], "any", false, false, true, 246)) {
// line 247
echo " <div class=\"tab-pane fade ";
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 247, $this->source); })()) == 3)) ? ("show active") : (""));
echo "\" id=\"tab-3\"
aria-labelledby=\"nav-tab-3\" role=\"tabpanel\">
<table class=\"table\">
";
// line 250
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable($this->extensions['App\Twig\Extension\GeneralExtension']->jsonDecode(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 250, $this->source); })()), "nutrients", [], "any", false, false, true, 250)));
foreach ($context['_seq'] as $context["_key"] => $context["nutrient"]) {
// line 251
echo " <tr>
<td>";
// line 252
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["nutrient"], "name", [], "any", false, false, true, 252), 252, $this->source), "html", null, true);
echo ":</td>
<td class=\"text-end\">";
// line 253
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["nutrient"], "value", [], "any", false, false, true, 253), 253, $this->source), "html", null, true);
echo " ";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["nutrient"], "unit", [], "any", false, false, true, 253), 253, $this->source), "html", null, true);
echo "</td>
</tr>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['nutrient'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 256
echo " </table>
</div>
";
}
// line 259
echo "
";
// line 260
if ((isset($context["allergens"]) || array_key_exists("allergens", $context) ? $context["allergens"] : (function () { throw new RuntimeError('Variable "allergens" does not exist.', 260, $this->source); })())) {
// line 261
echo " <div class=\"tab-pane fade ";
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 261, $this->source); })()) == 4)) ? ("show active") : (""));
echo "\" id=\"tab-4\"
aria-labelledby=\"nav-tab-4\" role=\"tabpanel\">
";
// line 263
$context["counter"] = 0;
// line 264
echo "
";
// line 265
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable((isset($context["allergens"]) || array_key_exists("allergens", $context) ? $context["allergens"] : (function () { throw new RuntimeError('Variable "allergens" does not exist.', 265, $this->source); })()));
foreach ($context['_seq'] as $context["_key"] => $context["allergen_type"]) {
// line 266
echo " ";
if (($context["allergen_type"] && twig_length_filter($this->env, twig_get_attribute($this->env, $this->source, $context["allergen_type"], "fields", [], "any", false, false, true, 266)))) {
// line 267
echo " ";
$context["counter"] = ((isset($context["counter"]) || array_key_exists("counter", $context) ? $context["counter"] : (function () { throw new RuntimeError('Variable "counter" does not exist.', 267, $this->source); })()) + 1);
// line 268
echo " <p><strong>";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["allergen_type"], "title", [], "array", false, false, true, 268), 268, $this->source), "html", null, true);
echo ":</strong></p>
<ul class=\"ingredients\">
";
// line 271
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env, $this->source, $context["allergen_type"], "fields", [], "any", false, false, true, 271));
foreach ($context['_seq'] as $context["_key"] => $context["allergen"]) {
// line 272
echo " <li>";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed($context["allergen"], 272, $this->source), "html", null, true);
echo "</li>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['allergen'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 274
echo " </ul>
";
}
// line 276
echo " ";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['allergen_type'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 277
echo "
";
// line 278
if (((isset($context["counter"]) || array_key_exists("counter", $context) ? $context["counter"] : (function () { throw new RuntimeError('Variable "counter" does not exist.', 278, $this->source); })()) == 0)) {
// line 279
echo " <p>";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Geen allergeeninformatie beschikbaar voor dit product"), "html", null, true);
echo "</p>
";
}
// line 281
echo " </div>
";
}
// line 283
echo "
";
// line 284
if (twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 284, $this->source); })()), "psinfoodDocuments", [], "any", false, false, true, 284)) {
// line 285
echo " <div class=\"tab-pane fade ";
echo ((((isset($context["default_tab"]) || array_key_exists("default_tab", $context) ? $context["default_tab"] : (function () { throw new RuntimeError('Variable "default_tab" does not exist.', 285, $this->source); })()) == 5)) ? ("show active") : (""));
echo "\" id=\"tab-5\"
aria-labelledby=\"nav-tab-5\" role=\"tabpanel\">
<ul class=\"ingredients\">
";
// line 288
$context['_parent'] = $context;
$context['_seq'] = twig_ensure_traversable($this->extensions['App\Twig\Extension\GeneralExtension']->jsonDecode(twig_get_attribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 288, $this->source); })()), "psinfoodDocuments", [], "any", false, false, true, 288)));
foreach ($context['_seq'] as $context["_key"] => $context["document"]) {
// line 289
echo " <li>
<a href=\"";
// line 290
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, $context["document"], "downloadurl", [], "any", false, false, true, 290), 290, $this->source), "html", null, true);
echo "\">
";
// line 291
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["document"], "labelname", [], "any", false, false, true, 291), "value", [], "any", false, false, true, 291), 291, $this->source), "html", null, true);
echo "
";
// line 292
if ((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["document"], "title", [], "any", false, false, true, 292), "value", [], "any", false, false, true, 292) === "string")) {
// line 293
echo " ";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["document"], "title", [], "any", false, false, true, 293), "value", [], "any", false, false, true, 293), 293, $this->source), "html", null, true);
echo "
";
}
// line 295
echo " </a>
</li>
";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['document'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 298
echo " </ul>
</div>
";
}
// line 301
echo " </div>
</div>
</div><!--/ .row -->
</div>
</div><!--/ .container-fluid -->
</section>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
public function getTemplateName()
{
return "products-detail.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 723 => 301, 718 => 298, 710 => 295, 704 => 293, 702 => 292, 698 => 291, 694 => 290, 691 => 289, 687 => 288, 680 => 285, 678 => 284, 675 => 283, 671 => 281, 665 => 279, 663 => 278, 660 => 277, 654 => 276, 650 => 274, 641 => 272, 637 => 271, 630 => 268, 627 => 267, 624 => 266, 620 => 265, 617 => 264, 615 => 263, 609 => 261, 607 => 260, 604 => 259, 599 => 256, 588 => 253, 584 => 252, 581 => 251, 577 => 250, 570 => 247, 568 => 246, 565 => 245, 559 => 242, 553 => 240, 551 => 239, 548 => 238, 542 => 235, 536 => 233, 534 => 232, 529 => 229, 523 => 226, 518 => 224, 515 => 223, 512 => 222, 510 => 221, 507 => 220, 501 => 217, 496 => 215, 493 => 214, 490 => 213, 488 => 212, 485 => 211, 479 => 208, 474 => 206, 471 => 205, 468 => 204, 466 => 203, 463 => 202, 457 => 199, 452 => 197, 449 => 196, 446 => 195, 444 => 194, 441 => 193, 435 => 190, 430 => 188, 427 => 187, 424 => 186, 422 => 185, 418 => 183, 416 => 182, 413 => 181, 410 => 180, 404 => 177, 398 => 173, 395 => 172, 392 => 171, 390 => 170, 382 => 165, 378 => 164, 374 => 163, 370 => 162, 363 => 157, 351 => 154, 347 => 152, 344 => 151, 338 => 149, 335 => 148, 330 => 146, 325 => 145, 322 => 144, 319 => 143, 317 => 142, 315 => 141, 314 => 140, 312 => 139, 308 => 137, 302 => 135, 296 => 133, 293 => 132, 291 => 131, 283 => 129, 279 => 128, 277 => 127, 276 => 126, 274 => 125, 272 => 124, 264 => 118, 255 => 112, 251 => 111, 247 => 109, 245 => 108, 242 => 107, 236 => 104, 232 => 102, 226 => 98, 217 => 95, 213 => 93, 209 => 92, 198 => 83, 188 => 79, 183 => 77, 180 => 76, 176 => 75, 169 => 70, 166 => 69, 164 => 68, 151 => 58, 147 => 57, 126 => 52, 123 => 51, 117 => 49, 115 => 48, 110 => 46, 99 => 37, 95 => 16, 89 => 14, 87 => 13, 80 => 8, 78 => 7, 75 => 6, 73 => 5, 70 => 4, 60 => 3, 37 => 1,);
}
public function getSourceContext()
{
return new Source("{% extends 'layout.html.twig' %}
{% block content %}
{% include 'includes/breadcrumb.html.twig' %}
{% set category = product.categories is iterable ? product.categories|first : false %}
<section class=\"section-filter\">
<div class=\"container-fluid\">
<div class=\"row align-items-center\">
<div class=\"col-auto\">
{% if category %}
<p class=\"h1\">{{ category.name }}</p>
{% endif %}
</div>
{#
<div class=\"col-auto ms-auto\">
<select name=\"\" id=\"\" class=\"form-select\">
<option value=\"\">Toon als thumbnails</option>
</select>
</div>
<div class=\"col-auto\">
<select name=\"\" id=\"\" class=\"form-select\">
<option value=\"\">Sorteer op productgroep</option>
</select>
</div>
<div class=\"col-auto\">
<select name=\"\" id=\"\" class=\"form-select\">
<option value=\"\">Toon aantal (9)</option>
</select>
</div>
#}
</div><!--/ .row -->
</div><!--/ .container -->
</section>
<section class=\"section-products\">
<div class=\"container-fluid\">
<div class=\"container-inner\">
<div class=\"row\">
<div class=\"col-auto\">
<h1 class=\"h2 mb-1\">{{ product.name }}</h1>
{% if product.onOrder %}
<span class=\"badge bg-danger\">{{ 'Op bestelling!'|trans }}</span>
{% endif %}
<p class=\"text-primary mb-5\">{{ 'Code'|trans }}: {{ product.code }} — {{ 'Merk'|trans }}: {{ product.brand }} {% if product.categoryTypes %} — {{ 'Categorietype'|trans }}: {{ product.categoryTypes|map(t => t.name)|join(', ') }}{% endif %}</p>
</div>
<div class=\"col-auto ms-auto\">
<favorite-button
product-id=\"{{ product.id }}\"
:is-current-favorite=\"{{ product.id in favoriteIds ? 'true' : 'false' }}\"
></favorite-button>
</div>
<favorite-modal></favorite-modal>
</div>
<div class=\"row\">
<div class=\"col-lg-3\">
{% if product.images %}
{% set imageList = product.images|json_decode %}
<div class=\"product-detail-images\">
<!-- swiper -->
<div id=\"detail-slider\" class=\"swiper swiper--detail\">
<div class=\"swiper-wrapper\">
{% for photo in imageList %}
<div class=\"swiper-slide\">
<a href=\"{{ photo.lightboxImage }}\" class=\"product-lightbox\"
data-glightbox=\"type: image\">
<img class=\"img-fluid\" src=\"{{ photo.thumbnailImage }}\" alt=\"\">
</a>
</div>
{% endfor %}
</div>
<div class=\"swiper-button-prev\"></div>
<div class=\"swiper-button-next\"></div>
</div><!--/ .swiper -->
<!-- swiper -->
<div class=\"swiper swiper--detail-thumbs\" id=\"detail-thumbs-slider\">
<div class=\"swiper-wrapper\">
{% for photo in imageList %}
<div class=\"swiper-slide\">
<img class=\"img-fluid\" src=\"{{ photo.thumbnailImage }}\" alt=\"\">
</div>
{% endfor %}
</div>
</div><!--/ .swiper -->
</div>
{% else %}
<div class=\"img-wrapper placeholder-img\">
<img src=\"{{ asset('/img/placeholder.png') }}\" alt=\"\" class=\"img-fluid w-100\">
</div>
{% endif %}
{% if product.productsheet %}
<div class=\"row\">
<div class=\"productsheet\">
<a class=\"btn btn-hyperlink icon-link\" href=\"{{ product.productsheet }}\" target=\"_blank\">
{{ 'Bekijk productfiche'|trans }}
<i class=\"icon-link-ext\"></i>
</a>
</div>
</div><!--/ .row -->
{% endif %}
</div>
<div class=\"col-lg-8 offset-lg-1\">
<div class=\"row\">
<div class=\"col-auto\">
<div class=\"product-detail-price\">
{% if not product.OSPrice.getAmount.isZero %}
<div class=\"price {% if
product.promoDate1 and product.promoDate2 and
date(product.promoDate1) < date() and date(product.promoDate2) > date() %}
price--promo
{% endif %}\">{{ product.OSPrice }}<small class=\"price-unit\">/{{ product.unit }}</small>
</div>
{% if( product.discount ) %}
{% if( product.OSPrice != product.OSDefaultPrice ) %}
<p class=\"old-price\">{{ product.OSDefaultPrice }}</p>
{% endif %}
<div class=\"promo\">-{{ product.discount }}%</div>
{% endif %}
{% endif %}
{% if
product.promoDate1 and product.promoDate2 and
date(product.promoDate1) < date() and date(product.promoDate2) > date() %}
{# Show promo price even when prices should not show #}
{% if product.OSPrice.getAmount.isZero %}
{% if product.promoPrice %}
<div class=\"price price--promo\">{{ product.promoPrice | currency }}
<small class=\"price-unit\">/{{ product.unit }}</small></div>
{% endif %}
{% if( product.promoPercentage ) %}
<div class=\"promo\">-{{ product.promoPercentage }}%</div>
{% endif %}
{% endif %}
<p class=\"date\">
({{ 'Promotie vanaf'|trans }} {{ product.promoDate1|date('d/m/Y') }} {{ 'tot'|trans }} {{ product.promoDate2|date('d/m/Y') }}
)</p>
{% endif %}
</div>
</div>
<div class=\"col-auto ms-auto\">
<add-to-cart
product-id=\"{{ product.id }}\"
unit=\"{{ product.unit }}\"
minimum-unit=\"{{ 0 + product.unitMinimum }}\"
amount-in-cart=\"{{ cartItems[product.id] ?? 0 }}\"
></add-to-cart>
</div>
</div><!--/ .row -->
{% if product.onOrder %}
{% set orderMessage = product_order_message(product) %}
{% if orderMessage %}
<div class=\"alert alert-warning d-flex align-items-start\" role=\"alert\">
<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"18\" height=\"18\" viewBox=\"0 0 16 16\" fill=\"currentColor\" class=\"flex-shrink-0 me-2 mt-1\" aria-hidden=\"true\">
<path d=\"M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16zm.93-9.412-1 4.705c-.07.34.029.533.304.533.194 0 .487-.07.686-.246l-.088.416c-.286.346-.92.598-1.465.598-.703 0-1.002-.422-.808-1.319l.738-3.468c.064-.293.006-.399-.287-.47l-.451-.081.082-.381 2.29-.287zM8 5.5a1 1 0 1 1 0-2 1 1 0 0 1 0 2z\"/>
</svg>
<span style=\"white-space: pre-wrap;\">{{ orderMessage }}</span>
</div>
{% endif %}
{% endif %}
{% set default_tab = null %}
<ul class=\"nav nav--tabs\" id=\"nav-tab\" role=\"tablist\">
{% if product.ingredients %}
{% set default_tab = 1 %}
<li class=\"nav-item\">
<button class=\"nav-link {{ default_tab == 1 ? 'active' : '' }}\" id=\"nav-tab-1\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-1\" role=\"tab\"
aria-selected=\"true\">{{ 'Ingrediënten'|trans }}</button>
</li>
{% endif %}
{% if product.description %}
{% set default_tab = default_tab ? default_tab : 2 %}
<li class=\"nav-item\">
<button class=\"nav-link {{ default_tab == 2 ? 'active': '' }}\" id=\"nav-tab-2\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-2\" role=\"tab\"
aria-selected=\"true\">{{ 'Omschrijving'|trans }}</button>
</li>
{% endif %}
{% if product.nutrients %}
{% set default_tab = default_tab ? default_tab : 3 %}
<li class=\"nav-item\">
<button class=\"nav-link {{ default_tab == 3 ? 'active' : '' }}\" id=\"nav-tab-3\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-3\" role=\"tab\"
aria-selected=\"false\">{{ 'Voedingswaarde'|trans }}</button>
</li>
{% endif %}
{% if allergens and (allergens|length) > 0 %}
{% set default_tab = default_tab ? default_tab : 4 %}
<li class=\"nav-item\">
<button class=\"nav-link {{ default_tab == 4 ? 'active' : '' }}\" id=\"nav-tab-4\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-4\" role=\"tab\"
aria-selected=\"false\">{{ 'Wettelijke allergenen'|trans }}</button>
</li>
{% endif %}
{% if product.psinfoodDocuments %}
{% set default_tab = default_tab ? default_tab : 5 %}
<li class=\"nav-item\">
<button class=\"nav-link {{ default_tab == 5 ? 'active' : '' }}\" id=\"nav-tab-5\"
data-bs-toggle=\"tab\" data-bs-target=\"#tab-5\" role=\"tab\"
aria-selected=\"false\">{{ 'Documenten'|trans }}</button>
</li>
{% endif %}
</ul>
<div class=\"tab-content\" id=\"tab-content\">
{% if product.ingredients %}
<div class=\"tab-pane fade {{ default_tab == 1 ? 'show active' : '' }}\" id=\"tab-1\"
aria-labelledby=\"nav-tab-1\" role=\"tabpanel\">
{{ product.ingredients }}
</div>
{% endif %}
{% if product.description %}
<div class=\"tab-pane fade {{ default_tab == 2 ? 'show active' : '' }}\" id=\"tab-2\"
aria-labelledby=\"nav-tab-2\" role=\"tabpanel\">
{{ product.description|raw|nl2br }}
</div>
{% endif %}
{% if product.nutrients %}
<div class=\"tab-pane fade {{ default_tab == 3 ? 'show active' : '' }}\" id=\"tab-3\"
aria-labelledby=\"nav-tab-3\" role=\"tabpanel\">
<table class=\"table\">
{% for nutrient in product.nutrients|json_decode %}
<tr>
<td>{{ nutrient.name }}:</td>
<td class=\"text-end\">{{ nutrient.value }} {{ nutrient.unit }}</td>
</tr>
{% endfor %}
</table>
</div>
{% endif %}
{% if allergens %}
<div class=\"tab-pane fade {{ default_tab == 4 ? 'show active' : '' }}\" id=\"tab-4\"
aria-labelledby=\"nav-tab-4\" role=\"tabpanel\">
{% set counter = 0 %}
{% for allergen_type in allergens %}
{% if allergen_type and allergen_type.fields|length %}
{% set counter = counter + 1 %}
<p><strong>{{ allergen_type['title'] }}:</strong></p>
<ul class=\"ingredients\">
{% for allergen in allergen_type.fields %}
<li>{{ allergen }}</li>
{% endfor %}
</ul>
{% endif %}
{% endfor %}
{% if counter == 0 %}
<p>{{ 'Geen allergeeninformatie beschikbaar voor dit product'|trans }}</p>
{% endif %}
</div>
{% endif %}
{% if product.psinfoodDocuments %}
<div class=\"tab-pane fade {{ default_tab == 5 ? 'show active' : '' }}\" id=\"tab-5\"
aria-labelledby=\"nav-tab-5\" role=\"tabpanel\">
<ul class=\"ingredients\">
{% for document in product.psinfoodDocuments|json_decode %}
<li>
<a href=\"{{ document.downloadurl }}\">
{{ document.labelname.value }}
{% if document.title.value is same as('string') %}
{{ document.title.value }}
{% endif %}
</a>
</li>
{% endfor %}
</ul>
</div>
{% endif %}
</div>
</div>
</div><!--/ .row -->
</div>
</div><!--/ .container-fluid -->
</section>
{% endblock %}", "products-detail.html.twig", "/data/sites/web/devliegerfilipbe/subsites/dev.devliegerfilip.dspdev.be/templates/products-detail.html.twig");
}
public function checkSecurity()
{
static $tags = array("include" => 5, "set" => 7, "if" => 13, "for" => 75);
static $filters = array("first" => 7, "escape" => 14, "trans" => 49, "join" => 52, "map" => 52, "json_decode" => 69, "currency" => 145, "date" => 154, "length" => 212, "nl2br" => 242, "raw" => 242);
static $functions = array("asset" => 104, "date" => 127, "product_order_message" => 171);
try {
$this->sandbox->checkSecurity(
['include', 'set', 'if', 'for'],
['first', 'escape', 'trans', 'join', 'map', 'json_decode', 'currency', 'date', 'length', 'nl2br', 'raw'],
['asset', 'date', 'product_order_message']
);
} 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;
}
}
}