<?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;
/* areas/watch-landing/_image.html.twig */
class __TwigTemplate_de6a546e644bbb5f390d9fd5c2c60f53 extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->parent = false;
$this->blocks = [
];
$this->sandbox = $this->env->getExtension('\Twig\Extension\SandboxExtension');
$this->checkSecurity();
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "areas/watch-landing/_image.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "areas/watch-landing/_image.html.twig"));
// line 1
echo "<div class=\"col-lg-6 watch-landing-example-container\">
";
// line 2
$context["thumbnailName"] = "seiko_productDetails";
// line 3
echo " ";
if ((isset($context["editmode"]) || array_key_exists("editmode", $context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.', 3, $this->source); })())) {
// line 4
echo " <div style=\"width: 300px; height: 430px\">
<div>
<h6 class=\"banner-style\">THUMBNAIL</h6>
";
// line 7
echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "select", "thumbnail_for_image", ["store" => [["seiko_productDetails", "Seiko ProductDetails"], ["seiko_brandAmbassadorDetails", "Seiko Brandambassador Details"]], "defaultValue" => "seiko_productDetails"]);
// line 13
echo "
</div>
<h6 class=\"banner-style\">ÓRA WEB KÉP</h6>
";
// line 16
echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "image", "watch-example", ["reload" => true]);
echo "
<h6 class=\"banner-style\">Link a képen ";
// line 17
echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "link", "picture_link");
echo "</h6>
</div>
";
} else {
// line 20
echo " ";
$context["image"] = $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "image", "watch-example");
// line 21
echo " ";
if (((isset($context["image"]) || array_key_exists("image", $context) ? $context["image"] : (function () { throw new RuntimeError('Variable "image" does not exist.', 21, $this->source); })()) && twig_get_attribute($this->env, $this->source, (isset($context["image"]) || array_key_exists("image", $context) ? $context["image"] : (function () { throw new RuntimeError('Variable "image" does not exist.', 21, $this->source); })()), "getImage", [], "method", false, false, true, 21))) {
// line 22
echo " ";
if (twig_get_attribute($this->env, $this->source, $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "select", "thumbnail_for_image"), "getData", [], "method", false, false, true, 22)) {
// line 23
echo " ";
$context["thumbnailName"] = twig_get_attribute($this->env, $this->source, $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "select", "thumbnail_for_image"), "getData", [], "method", false, false, true, 23);
// line 24
echo " ";
}
// line 25
echo " ";
$context["anchorNeeded"] = ($this->env->getTest('instanceof')->getCallable()(twig_get_attribute($this->env, $this->source, $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "relation", "additional_news"), "getElement", [], "method", false, false, true, 25), "\\Pimcore\\Model\\DataObject\\News") && !(isset($context["editmode"]) || array_key_exists("editmode", $context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.', 25, $this->source); })()));
// line 26
echo " ";
if (( !twig_get_attribute($this->env, $this->source, $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "link", "picture_link"), "isEmpty", [], "method", false, false, true, 26) && !(isset($context["anchorNeeded"]) || array_key_exists("anchorNeeded", $context) ? $context["anchorNeeded"] : (function () { throw new RuntimeError('Variable "anchorNeeded" does not exist.', 26, $this->source); })()))) {
// line 27
echo " ";
echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "link", "picture_link", ["noText" => true, "textPrefix" => $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, // line 29
(isset($context["image"]) || array_key_exists("image", $context) ? $context["image"] : (function () { throw new RuntimeError('Variable "image" does not exist.', 29, $this->source); })()), "getImage", [], "method", false, false, true, 29), "thumbnail", [(isset($context["thumbnailName"]) || array_key_exists("thumbnailName", $context) ? $context["thumbnailName"] : (function () { throw new RuntimeError('Variable "thumbnailName" does not exist.', 29, $this->source); })())], "method", false, false, true, 29), "getHtml", [["imgAttributes" => ["alt" => "example", "class" => "img-fluid"]]], "method", false, false, true, 29), 29, $this->source)]);
// line 35
echo "
";
} else {
// line 37
echo "
";
// line 38
if ((isset($context["anchorNeeded"]) || array_key_exists("anchorNeeded", $context) ? $context["anchorNeeded"] : (function () { throw new RuntimeError('Variable "anchorNeeded" does not exist.', 38, $this->source); })())) {
// line 39
echo " <a class=\"div-link\" href=\"";
echo twig_escape_filter($this->env, $this->env->getFunction('pimcore_url')->getCallable()(["object" => twig_get_attribute($this->env, $this->source, $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "relation", "additional_news"), "getElement", [], "method", false, false, true, 39)]), "html", null, true);
echo "\">
";
}
// line 41
echo " ";
echo $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, (isset($context["image"]) || array_key_exists("image", $context) ? $context["image"] : (function () { throw new RuntimeError('Variable "image" does not exist.', 41, $this->source); })()), "getImage", [], "method", false, false, true, 41), "thumbnail", [(isset($context["thumbnailName"]) || array_key_exists("thumbnailName", $context) ? $context["thumbnailName"] : (function () { throw new RuntimeError('Variable "thumbnailName" does not exist.', 41, $this->source); })())], "method", false, false, true, 41), "getHtml", [["imgAttributes" => ["alt" => "example", "class" => "img-fluid"]]], "method", false, false, true, 41), 41, $this->source);
// line 46
echo "
";
// line 47
if ((isset($context["anchorNeeded"]) || array_key_exists("anchorNeeded", $context) ? $context["anchorNeeded"] : (function () { throw new RuntimeError('Variable "anchorNeeded" does not exist.', 47, $this->source); })())) {
// line 48
echo " </a>
";
}
// line 50
echo "
";
}
// line 52
echo " ";
}
// line 53
echo " ";
}
// line 54
echo "</div>";
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
public function getTemplateName()
{
return "areas/watch-landing/_image.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 137 => 54, 134 => 53, 131 => 52, 127 => 50, 123 => 48, 121 => 47, 118 => 46, 115 => 41, 109 => 39, 107 => 38, 104 => 37, 100 => 35, 98 => 29, 96 => 27, 93 => 26, 90 => 25, 87 => 24, 84 => 23, 81 => 22, 78 => 21, 75 => 20, 69 => 17, 65 => 16, 60 => 13, 58 => 7, 53 => 4, 50 => 3, 48 => 2, 45 => 1,);
}
public function getSourceContext()
{
return new Source("<div class=\"col-lg-6 watch-landing-example-container\">
{% set thumbnailName = 'seiko_productDetails' %}
{% if editmode %}
<div style=\"width: 300px; height: 430px\">
<div>
<h6 class=\"banner-style\">THUMBNAIL</h6>
{{ pimcore_select(\"thumbnail_for_image\", {
\"store\": [
[\"seiko_productDetails\", \"Seiko ProductDetails\"],
[\"seiko_brandAmbassadorDetails\", \"Seiko Brandambassador Details\"],
],
\"defaultValue\": \"seiko_productDetails\"
}) }}
</div>
<h6 class=\"banner-style\">ÓRA WEB KÉP</h6>
{{ pimcore_image('watch-example', {'reload':true}) }}
<h6 class=\"banner-style\">Link a képen {{ pimcore_link('picture_link') }}</h6>
</div>
{% else %}
{% set image = pimcore_image('watch-example') %}
{% if image and image.getImage() %}
{% if pimcore_select(\"thumbnail_for_image\").getData() %}
{% set thumbnailName = pimcore_select(\"thumbnail_for_image\").getData() %}
{% endif %}
{% set anchorNeeded = pimcore_relation(\"additional_news\").getElement() is instanceof('\\\\Pimcore\\\\Model\\\\DataObject\\\\News') and not editmode %}
{% if not pimcore_link('picture_link').isEmpty() and not anchorNeeded %}
{{ pimcore_link('picture_link', {
'noText': true,
'textPrefix': image.getImage().thumbnail(thumbnailName).getHtml({
'imgAttributes': {
'alt': 'example',
'class': 'img-fluid'
}
}) | raw
}) }}
{% else %}
{% if anchorNeeded %}
<a class=\"div-link\" href=\"{{ pimcore_url({'object': pimcore_relation(\"additional_news\").getElement()}) }}\">
{% endif %}
{{ image.getImage().thumbnail(thumbnailName).getHtml({
'imgAttributes': {
'alt': 'example',
'class': 'img-fluid'
}
}) | raw }}
{% if anchorNeeded %}
</a>
{% endif %}
{% endif %}
{% endif %}
{% endif %}
</div>", "areas/watch-landing/_image.html.twig", "/home/zoltan/public_html/boutique-v2/templates/areas/watch-landing/_image.html.twig");
}
public function checkSecurity()
{
static $tags = array("set" => 2, "if" => 3);
static $filters = array("raw" => 34, "escape" => 39);
static $functions = array("pimcore_select" => 7, "pimcore_image" => 16, "pimcore_link" => 17, "pimcore_relation" => 25, "pimcore_url" => 39);
try {
$this->sandbox->checkSecurity(
['set', 'if'],
['raw', 'escape'],
['pimcore_select', 'pimcore_image', 'pimcore_link', 'pimcore_relation', 'pimcore_url']
);
} 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;
}
}
}