<?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;
/* @App/Areas/content/basisbundle-content-form/variant-evalanche-partner.html.twig */
class __TwigTemplate_fbffde80c3e98d88f7b36cb7e094da6a 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", "@App/Areas/content/basisbundle-content-form/variant-evalanche-partner.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "@App/Areas/content/basisbundle-content-form/variant-evalanche-partner.html.twig"));
// line 1
$macros["wrap_macro"] = $this->macros["wrap_macro"] = $this->loadTemplate("@FoxHabbitBasis/Macro/wrap.html.twig", "@App/Areas/content/basisbundle-content-form/variant-evalanche-partner.html.twig", 1)->unwrap();
// line 2
echo "
";
// line 3
$context["evalanche_user"] = ((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["app"] ?? null), "request", [], "any", false, true, true, 3), "getSession", [], "method", false, true, true, 3), "get", ["evalanche_user"], "method", true, true, true, 3)) ? (_twig_default_filter($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["app"] ?? null), "request", [], "any", false, true, true, 3), "getSession", [], "method", false, true, true, 3), "get", ["evalanche_user"], "method", false, false, true, 3), 3, $this->source), null)) : (null));
// line 4
if ((isset($context["editmode"]) || array_key_exists("editmode", $context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.', 4, $this->source); })())) {
// line 5
echo "\t";
echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "select", "form_url", ["store" => twig_get_attribute($this->env, $this->source, (isset($context["evalancheConnector"]) || array_key_exists("evalancheConnector", $context) ? $context["evalancheConnector"] : (function () { throw new RuntimeError('Variable "evalancheConnector" does not exist.', 5, $this->source); })()), "getFormsAsPimcoreSelectStore", [], "method", false, false, true, 5), "width" => "100%"]);
echo "
";
} else {
// line 7
echo "\t";
$context["iframeUrl"] = twig_get_attribute($this->env, $this->source, $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context, "select", "form_url"), "getValue", [], "method", false, false, true, 7);
// line 8
echo "
\t";
// line 9
if (((twig_get_attribute($this->env, $this->source, ($context["config"] ?? null), "forceHttps", [], "any", true, true, true, 9)) ? (_twig_default_filter(twig_get_attribute($this->env, $this->source, ($context["config"] ?? null), "forceHttps", [], "any", false, false, true, 9), null)) : (null))) {
// line 10
echo "\t\t";
$context["iframeUrl"] = twig_replace_filter($this->sandbox->ensureToStringAllowed((isset($context["iframeUrl"]) || array_key_exists("iframeUrl", $context) ? $context["iframeUrl"] : (function () { throw new RuntimeError('Variable "iframeUrl" does not exist.', 10, $this->source); })()), 10, $this->source), ["http:" => "https:"]);
// line 11
echo "\t";
}
// line 12
echo "
\t";
// line 13
if (((twig_get_attribute($this->env, $this->source, ($context["config"] ?? null), "forceHttp", [], "any", true, true, true, 13)) ? (_twig_default_filter(twig_get_attribute($this->env, $this->source, ($context["config"] ?? null), "forceHttp", [], "any", false, false, true, 13), null)) : (null))) {
// line 14
echo "\t\t";
$context["iframeUrl"] = twig_replace_filter($this->sandbox->ensureToStringAllowed((isset($context["iframeUrl"]) || array_key_exists("iframeUrl", $context) ? $context["iframeUrl"] : (function () { throw new RuntimeError('Variable "iframeUrl" does not exist.', 14, $this->source); })()), 14, $this->source), ["https:" => "http:"]);
// line 15
echo "\t";
}
// line 16
echo "
\t";
// line 17
if ((((twig_get_attribute($this->env, $this->source, ($context["config"] ?? null), "prefillUserData", [], "any", true, true, true, 17)) ? (_twig_default_filter(twig_get_attribute($this->env, $this->source, ($context["config"] ?? null), "prefillUserData", [], "any", false, false, true, 17), null)) : (null)) && (isset($context["evalanche_user"]) || array_key_exists("evalanche_user", $context) ? $context["evalanche_user"] : (function () { throw new RuntimeError('Variable "evalanche_user" does not exist.', 17, $this->source); })()))) {
// line 18
echo "\t\t";
$context["iframeUrl"] = (($this->sandbox->ensureToStringAllowed((isset($context["iframeUrl"]) || array_key_exists("iframeUrl", $context) ? $context["iframeUrl"] : (function () { throw new RuntimeError('Variable "iframeUrl" does not exist.', 18, $this->source); })()), 18, $this->source) . ",u=") . $this->sandbox->ensureToStringAllowed((isset($context["evalanche_user"]) || array_key_exists("evalanche_user", $context) ? $context["evalanche_user"] : (function () { throw new RuntimeError('Variable "evalanche_user" does not exist.', 18, $this->source); })()), 18, $this->source));
// line 19
echo "\t";
}
// line 20
echo "\t";
$context["partnerObject"] = ((twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["container"] ?? null), "get", ["request_stack"], "method", false, true, true, 20), "getMasterRequest", [], "method", false, true, true, 20), "get", ["partnerObject"], "method", true, true, true, 20)) ? (_twig_default_filter($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, ($context["container"] ?? null), "get", ["request_stack"], "method", false, true, true, 20), "getMasterRequest", [], "method", false, true, true, 20), "get", ["partnerObject"], "method", false, false, true, 20), 20, $this->source), null)) : (null));
// line 21
echo "\t";
if (((isset($context["partnerObject"]) || array_key_exists("partnerObject", $context) ? $context["partnerObject"] : (function () { throw new RuntimeError('Variable "partnerObject" does not exist.', 21, $this->source); })()) && twig_get_attribute($this->env, $this->source, (isset($context["partnerObject"]) || array_key_exists("partnerObject", $context) ? $context["partnerObject"] : (function () { throw new RuntimeError('Variable "partnerObject" does not exist.', 21, $this->source); })()), "getEvaID", [], "method", false, false, true, 21))) {
// line 22
echo "\t\t\t\t
\t\t";
// line 23
if (twig_get_attribute($this->env, $this->source, (isset($context["partnerObject"]) || array_key_exists("partnerObject", $context) ? $context["partnerObject"] : (function () { throw new RuntimeError('Variable "partnerObject" does not exist.', 23, $this->source); })()), "getEmail", [], "method", false, false, true, 23)) {
// line 24
echo "\t\t\t";
$context["iframeUrl"] = (($this->sandbox->ensureToStringAllowed((isset($context["iframeUrl"]) || array_key_exists("iframeUrl", $context) ? $context["iframeUrl"] : (function () { throw new RuntimeError('Variable "iframeUrl" does not exist.', 24, $this->source); })()), 24, $this->source) . "&form_PARTNERCOBOTWEITERLEITUNG=") . $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["partnerObject"]) || array_key_exists("partnerObject", $context) ? $context["partnerObject"] : (function () { throw new RuntimeError('Variable "partnerObject" does not exist.', 24, $this->source); })()), "getEvaID", [], "method", false, false, true, 24), 24, $this->source));
// line 25
echo "\t\t";
}
// line 26
echo "
\t\t";
// line 27
$context["uinique_id"] = ("iframe_sizetracker_" . twig_random($this->env));
// line 28
echo "
\t\t<iframe
\t\t\tclass=\"iframe-resizer\"
\t\t\tid=\"";
// line 31
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed((isset($context["uinique_id"]) || array_key_exists("uinique_id", $context) ? $context["uinique_id"] : (function () { throw new RuntimeError('Variable "uinique_id" does not exist.', 31, $this->source); })()), 31, $this->source), "html", null, true);
echo "\"
\t\t\tscrolling=\"no\"
\t\t\tsrc=\"";
// line 33
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed((isset($context["iframeUrl"]) || array_key_exists("iframeUrl", $context) ? $context["iframeUrl"] : (function () { throw new RuntimeError('Variable "iframeUrl" does not exist.', 33, $this->source); })()), 33, $this->source), "html", null, true);
echo "\"
\t\t\tframeborder=\"0\"
\t\t\twidth=\"100%\"
\t\t\theight=\"1280px\">
\t\t\t<p>Ihr Browser unterstützt leider keine eingebetteten Frames (iframes)
\t\t\t<a href=\"";
// line 38
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed((isset($context["iframeUrl"]) || array_key_exists("iframeUrl", $context) ? $context["iframeUrl"] : (function () { throw new RuntimeError('Variable "iframeUrl" does not exist.', 38, $this->source); })()), 38, $this->source), "html", null, true);
echo "\" target=\"_blank\">weiter</a></p>
\t\t</iframe>
\t\t";
// line 41
if (((twig_get_attribute($this->env, $this->source, ($context["config"] ?? null), "text_below", [], "any", true, true, true, 41)) ? (_twig_default_filter(twig_get_attribute($this->env, $this->source, ($context["config"] ?? null), "text_below", [], "any", false, false, true, 41), null)) : (null))) {
// line 42
echo "\t\t\t";
echo twig_call_macro($macros["wrap_macro"], "macro_wrapperOpen", [twig_get_attribute($this->env, $this->source, (isset($context["config"]) || array_key_exists("config", $context) ? $context["config"] : (function () { throw new RuntimeError('Variable "config" does not exist.', 42, $this->source); })()), "wrapper_text_below", [], "any", false, false, true, 42), $context], 42, $context, $this->getSourceContext());
echo "
\t\t\t\t";
// line 43
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans($this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, (isset($context["config"]) || array_key_exists("config", $context) ? $context["config"] : (function () { throw new RuntimeError('Variable "config" does not exist.', 43, $this->source); })()), "text_below", [], "any", false, false, true, 43), 43, $this->source)), "html", null, true);
echo "
\t\t\t";
// line 44
echo twig_call_macro($macros["wrap_macro"], "macro_wrapperClose", [twig_get_attribute($this->env, $this->source, (isset($context["config"]) || array_key_exists("config", $context) ? $context["config"] : (function () { throw new RuntimeError('Variable "config" does not exist.', 44, $this->source); })()), "wrapper_text_below", [], "any", false, false, true, 44)], 44, $context, $this->getSourceContext());
echo "
\t\t";
}
// line 46
echo "\t";
} else {
// line 47
echo "\t\t<div class=\"alert aler-danger\">Internal error: Contact form currently not available</div>
\t";
}
}
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
public function getTemplateName()
{
return "@App/Areas/content/basisbundle-content-form/variant-evalanche-partner.html.twig";
}
public function isTraitable()
{
return false;
}
public function getDebugInfo()
{
return array ( 161 => 47, 158 => 46, 153 => 44, 149 => 43, 144 => 42, 142 => 41, 136 => 38, 128 => 33, 123 => 31, 118 => 28, 116 => 27, 113 => 26, 110 => 25, 107 => 24, 105 => 23, 102 => 22, 99 => 21, 96 => 20, 93 => 19, 90 => 18, 88 => 17, 85 => 16, 82 => 15, 79 => 14, 77 => 13, 74 => 12, 71 => 11, 68 => 10, 66 => 9, 63 => 8, 60 => 7, 54 => 5, 52 => 4, 50 => 3, 47 => 2, 45 => 1,);
}
public function getSourceContext()
{
return new Source("{% import '@FoxHabbitBasis/Macro/wrap.html.twig' as wrap_macro %}
{% set evalanche_user = app.request.getSession().get('evalanche_user')|default(null) %}
{% if editmode %}
\t{{ pimcore_select( 'form_url', { store: evalancheConnector.getFormsAsPimcoreSelectStore(), width: '100%' }) }}
{% else %}
\t{% set iframeUrl = pimcore_select( 'form_url').getValue() %}
\t{% if config.forceHttps|default(null) %}
\t\t{% set iframeUrl = iframeUrl|replace({'http:':'https:'}) %}
\t{% endif %}
\t{% if config.forceHttp|default(null) %}
\t\t{% set iframeUrl = iframeUrl|replace({'https:':'http:'}) %}
\t{% endif %}
\t{% if config.prefillUserData|default(null) and evalanche_user %}
\t\t{% set iframeUrl = iframeUrl ~ ',u=' ~ evalanche_user %}
\t{% endif %}
\t{% set partnerObject = container.get('request_stack').getMasterRequest().get('partnerObject')|default(null) %}
\t{% if partnerObject and partnerObject.getEvaID() %}
\t\t\t\t
\t\t{% if partnerObject.getEmail() %}
\t\t\t{% set iframeUrl = iframeUrl ~ '&form_PARTNERCOBOTWEITERLEITUNG=' ~ partnerObject.getEvaID() %}
\t\t{% endif %}
\t\t{% set uinique_id = 'iframe_sizetracker_'~random() %}
\t\t<iframe
\t\t\tclass=\"iframe-resizer\"
\t\t\tid=\"{{uinique_id}}\"
\t\t\tscrolling=\"no\"
\t\t\tsrc=\"{{ iframeUrl }}\"
\t\t\tframeborder=\"0\"
\t\t\twidth=\"100%\"
\t\t\theight=\"1280px\">
\t\t\t<p>Ihr Browser unterstützt leider keine eingebetteten Frames (iframes)
\t\t\t<a href=\"{{ iframeUrl }}\" target=\"_blank\">weiter</a></p>
\t\t</iframe>
\t\t{% if config.text_below|default(null) %}
\t\t\t{{ wrap_macro.wrapperOpen( config.wrapper_text_below, _context) }}
\t\t\t\t{{ config.text_below|trans }}
\t\t\t{{ wrap_macro.wrapperClose( config.wrapper_text_below) }}
\t\t{% endif %}
\t{% else %}
\t\t<div class=\"alert aler-danger\">Internal error: Contact form currently not available</div>
\t{% endif %}
{% endif %}
", "@App/Areas/content/basisbundle-content-form/variant-evalanche-partner.html.twig", "/srv/httpd/vhosts/lorch-test/releases/51/src/AppBundle/Resources/views/Areas/content/basisbundle-content-form/variant-evalanche-partner.html.twig");
}
public function checkSecurity()
{
static $tags = array("import" => 1, "set" => 3, "if" => 4);
static $filters = array("default" => 3, "replace" => 10, "escape" => 31, "trans" => 43);
static $functions = array("pimcore_select" => 5, "random" => 27);
try {
$this->sandbox->checkSecurity(
['import', 'set', 'if'],
['default', 'replace', 'escape', 'trans'],
['pimcore_select', 'random']
);
} 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;
}
}
}