<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\CoreExtension;
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;
use Twig\TemplateWrapper;
/* product/single.html.twig */
class __TwigTemplate_8583491127f6493ae941c6b2f1948efc5092dc82a71f2fe653324c5065ed2645 extends Template
{
private Source $source;
/**
* @var array<string, Template>
*/
private array $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'content' => [$this, 'block_content'],
];
$this->sandbox = $this->extensions[SandboxExtension::class];
$this->checkSecurity();
}
protected function doGetParent(array $context): bool|string|Template|TemplateWrapper
{
// line 1
return "app/layout.html.twig";
}
protected function doDisplay(array $context, array $blocks = []): iterable
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "product/single.html.twig"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "product/single.html.twig"));
$this->parent = $this->loadTemplate("app/layout.html.twig", "product/single.html.twig", 1);
yield from $this->parent->unwrap()->yield($context, array_merge($this->blocks, $blocks));
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
}
// line 3
/**
* @return iterable<null|scalar|\Stringable>
*/
public function block_content(array $context, array $blocks = []): iterable
{
$macros = $this->macros;
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->enter($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02 = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->enter($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
// line 4
yield "
";
// line 5
yield from $this->loadTemplate("product/partials/editmode/_options.html.twig", "product/single.html.twig", 5)->unwrap()->yield($context);
// line 6
yield "
";
// line 7
yield from $this->loadTemplate("app/partials/navigation/_breadcrumbs.html.twig", "product/single.html.twig", 7)->unwrap()->yield($context);
// line 8
yield "
";
// line 10
yield " ";
yield $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "area", "content-brick-2", ["type" => "content-brick", "params" => ["content-brick" => ["product" => $this->sandbox->ensureToStringAllowed( // line 14
(isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 14, $this->source); })()), 14, $this->source), "forceH1" => true, "defaultLayout" => "text-image", "defaultBackgroundColor" => "bg-blue-200", "defaultInverted" => true, "defaultTitle" => (((((CoreExtension::getAttribute($this->env, $this->source, // line 19
($context["product"] ?? null), "title", [], "any", true, true, true, 19) && !(null === CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "title", [], "any", false, false, true, 19)))) ? (CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "title", [], "any", false, false, true, 19)) : (null))) ? ((((CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "title", [], "any", true, true, true, 19) && !(null === CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "title", [], "any", false, false, true, 19)))) ? (CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "title", [], "any", false, false, true, 19)) : (null))) : (((("<span class=\"text-blue\">" . (((CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "name", [], "any", true, true, true, 19) && !(null === CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "name", [], "any", false, false, true, 19)))) ? (CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "name", [], "any", false, false, true, 19)) : (""))) . "</span> ") . (((CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "code", [], "any", true, true, true, 19) && !(null === CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "code", [], "any", false, false, true, 19)))) ? (CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "code", [], "any", false, false, true, 19)) : (""))))), "defaultWysiwyg" => (((CoreExtension::getAttribute($this->env, $this->source, // line 20
($context["product"] ?? null), "description", [], "any", true, true, true, 20) && !(null === CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "description", [], "any", false, false, true, 20)))) ? (CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "description", [], "any", false, false, true, 20)) : (null)), "defaultGalleryItems" => (((CoreExtension::getAttribute($this->env, $this->source, // line 21
($context["product"] ?? null), "images", [], "any", true, true, true, 21) && !(null === CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "images", [], "any", false, false, true, 21)))) ? (CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "images", [], "any", false, false, true, 21)) : ([])), "overrideImage" => (((CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, // line 22
($context["product"] ?? null), "images", [], "any", false, true, true, 22), "items", [], "any", false, true, true, 22), 0, [], "array", true, true, true, 22) && !(null === CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "images", [], "any", false, true, true, 22), "items", [], "any", false, true, true, 22), 0, [], "array", false, false, true, 22)))) ? (CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "images", [], "any", false, true, true, 22), "items", [], "any", false, true, true, 22), 0, [], "array", false, false, true, 22)) : (null)), "showFloatingBanner" => true]]]);
// line 26
yield "
";
// line 28
yield from $this->loadTemplate("product/partials/_product-specifications.html.twig", "product/single.html.twig", 28)->unwrap()->yield($context);
// line 29
yield "
";
// line 31
yield "
";
// line 33
yield " ";
// line 34
yield "
";
// line 36
yield "
";
// line 37
yield $this->env->getFunction('pimcore_inc')->getCallable()($this->sandbox->ensureToStringAllowed(CoreExtension::getAttribute($this->env, $this->source, (isset($context["document"]) || array_key_exists("document", $context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.', 37, $this->source); })()), "getProperty", ["productCtaSnippet"], "method", false, false, true, 37), 37, $this->source));
yield "
";
// line 39
yield $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "area", "product-table-1", ["type" => "product-table-brick", "params" => ["product-table-brick" => ["defaultTitle" => $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("Alternatieven voor {{ productName }}", ["{{ productName }}" => (((" <span class=\"text-blue\">" . (((CoreExtension::getAttribute($this->env, $this->source, // line 44
($context["product"] ?? null), "name", [], "any", true, true, true, 44) && !(null === CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "name", [], "any", false, false, true, 44)))) ? (CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "name", [], "any", false, false, true, 44)) : ("?"))) . "</span> ") . (((CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "code", [], "any", true, true, true, 44) && !(null === CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "code", [], "any", false, false, true, 44)))) ? (CoreExtension::getAttribute($this->env, $this->source, ($context["product"] ?? null), "code", [], "any", false, false, true, 44)) : ("?")))])]]]);
// line 48
yield "
";
// line 51
yield " ";
yield $this->env->getFunction('pimcore_inc')->getCallable()($this->sandbox->ensureToStringAllowed(CoreExtension::getAttribute($this->env, $this->source, (isset($context["document"]) || array_key_exists("document", $context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.', 51, $this->source); })()), "getProperty", ["faqSnippet"], "method", false, false, true, 51), 51, $this->source));
yield "
";
// line 58
yield "
";
// line 59
yield $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "areablock", "afterContentAreaBlock", ["allowed" => ["faq-brick"], "group" => ( // line 61
$context["brickGroups"] ?? []), "params" => ( // line 62
$context["areaBrickParams"] ?? [])]);
// line 63
yield "
";
$__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02->leave($__internal_319393461309892924ff6e74d6d6e64287df64b63545b994e100d4ab223aed02_prof);
$__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e->leave($__internal_085b0142806202599c7fe3b329164a92397d8978207a37e79d70b8c52599e33e_prof);
yield from [];
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName(): string
{
return "product/single.html.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable(): bool
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo(): array
{
return array ( 144 => 63, 142 => 62, 141 => 61, 140 => 59, 137 => 58, 131 => 51, 127 => 48, 125 => 44, 124 => 39, 119 => 37, 116 => 36, 113 => 34, 111 => 33, 108 => 31, 105 => 29, 103 => 28, 99 => 26, 97 => 22, 96 => 21, 95 => 20, 94 => 19, 93 => 14, 91 => 10, 88 => 8, 86 => 7, 83 => 6, 81 => 5, 78 => 4, 65 => 3, 42 => 1,);
}
public function getSourceContext(): Source
{
return new Source("{% extends 'app/layout.html.twig' %}
{% block content %}
{% include 'product/partials/editmode/_options.html.twig' %}
{% include \"app/partials/navigation/_breadcrumbs.html.twig\" %}
{# TODO use `defaultTitle: product.parent.getEditable('content-brick-2.title')` oid ? #}
{{ pimcore_area('content-brick-2', {
'type':'content-brick',
'params':{
'content-brick': {
'product': product,
'forceH1' : true,
'defaultLayout': 'text-image',
'defaultBackgroundColor':'bg-blue-200',
'defaultInverted': true,
'defaultTitle' : (product.title ?? null) ?: \"<span class=\\\"text-blue\\\">#{product.name ?? ''}</span> #{product.code ?? ''}\",
\"defaultWysiwyg\" : product.description ?? null,
\"defaultGalleryItems\" : product.images ?? [],
\"overrideImage\" : product.images.items[0] ?? null,
'showFloatingBanner': true,
}
}
}) }}
{% include 'product/partials/_product-specifications.html.twig' %}
{# {% include 'product/partials/_standard-parts.html.twig' %} #}
{# Temporarily disabled because the current products have linked accessories to 'Old' products. #}
{# {% include 'product/partials/_standard-accessoires.html.twig' %} #}
{# {% include 'product/partials/_optional-accessoires.html.twig' %} #}
{{ pimcore_inc(document.getProperty('productCtaSnippet')) }}
{{ pimcore_area('product-table-1', {
'type':'product-table-brick',
'params': {
'product-table-brick': {
'defaultTitle': \"Alternatieven voor {{ productName }}\" | trans({
'{{ productName }}': \" <span class=\\\"text-blue\\\">#{ product.name ?? '?' }</span> #{ product.code ?? '?' }\"
})
}
}
}) }}
{# @BACKEND TODO: Get FAQ questions out of product. #}
{{ pimcore_inc(document.getProperty('faqSnippet')) }}
{#
{{ pimcore_area('contact-side-widget', {
type: 'contact-side-widget-brick'
}) }}
#}
{{ pimcore_areablock('afterContentAreaBlock', {
\"allowed\": ['faq-brick'],
\"group\" : brickGroups ?? [],
'params': areaBrickParams ?? []
} ) }}
{% endblock %}
", "product/single.html.twig", "/home/forge/testing.coolworld.ptchr.dev/templates/product/single.html.twig");
}
public function checkSecurity()
{
static $tags = ["extends" => 1, "include" => 5];
static $filters = ["trans" => 43];
static $functions = ["pimcore_area" => 10, "pimcore_inc" => 37, "pimcore_areablock" => 59];
try {
$this->sandbox->checkSecurity(
['extends', 'include'],
['trans'],
['pimcore_area', 'pimcore_inc', 'pimcore_areablock'],
$this->source
);
} 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;
}
}
}