var/cache/dev/twig/0b/0b38c013d7c167a491f05b3f168bc10a.php line 33

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\SandboxExtension;
  6. use Twig\Markup;
  7. use Twig\Sandbox\SecurityError;
  8. use Twig\Sandbox\SecurityNotAllowedTagError;
  9. use Twig\Sandbox\SecurityNotAllowedFilterError;
  10. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  11. use Twig\Source;
  12. use Twig\Template;
  13. /* areas/standard-teaser/view.html.twig */
  14. class __TwigTemplate_6266fe45c65449814c8c81d6ea138b51 extends Template
  15. {
  16.     private $source;
  17.     private $macros = [];
  18.     public function __construct(Environment $env)
  19.     {
  20.         parent::__construct($env);
  21.         $this->source $this->getSourceContext();
  22.         $this->parent false;
  23.         $this->blocks = [
  24.         ];
  25.     }
  26.     protected function doDisplay(array $context, array $blocks = [])
  27.     {
  28.         $macros $this->macros;
  29.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  30.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""areas/standard-teaser/view.html.twig"));
  31.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  32.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""areas/standard-teaser/view.html.twig"));
  33.         // line 1
  34.         echo "<section class=\"area-standard-teaser bg-light text-center\">
  35.     <div class=\"container\">
  36.         <h2>";
  37.         // line 3
  38.         echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""standardTeaserHeading");
  39.         echo "</h2>
  40.         <div class=\"card-deck mb-3 text-center ";
  41.         // line 4
  42.         echo (((isset($context["editmode"]) || array_key_exists("editmode"$context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.'4$this->source); })())) ? ("no-gutters") : (""));
  43.         echo " \">
  44.             ";
  45.         // line 5
  46.         $context['_parent'] = $context;
  47.         $context['_seq'] = twig_ensure_traversable(range(02));
  48.         $context['loop'] = [
  49.           'parent' => $context['_parent'],
  50.           'index0' => 0,
  51.           'index'  => 1,
  52.           'first'  => true,
  53.         ];
  54.         if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  55.             $length count($context['_seq']);
  56.             $context['loop']['revindex0'] = $length 1;
  57.             $context['loop']['revindex'] = $length;
  58.             $context['loop']['length'] = $length;
  59.             $context['loop']['last'] = === $length;
  60.         }
  61.         foreach ($context['_seq'] as $context["_key"] => $context["t"]) {
  62.             // line 6
  63.             echo "                ";
  64.             // line 7
  65.             $context["select"] = $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"select", ("type_" $context["t"]), ["width" => 110"reload" => true"store" => [=> [=> "direct"=> "direct"], => [=> "snippet"=> "snippet"], => [=> "news"=> "news"]], "class" => "align-middle"]);
  66.             // line 18
  67.             echo "
  68.                 ";
  69.             // line 19
  70.             if ((isset($context["editmode"]) || array_key_exists("editmode"$context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.'19$this->source); })())) {
  71.                 // line 20
  72.                 echo "                    <div class=\"col-md-4\">
  73.                         <div class=\"mb-3\">
  74.                             <span class=\"editmode-label align-middle\">Type:</span>
  75.                             ";
  76.                 // line 23
  77.                 echo (isset($context["select"]) || array_key_exists("select"$context) ? $context["select"] : (function () { throw new RuntimeError('Variable "select" does not exist.'23$this->source); })());
  78.                 echo "
  79.                         </div>
  80.                 ";
  81.             }
  82.             // line 26
  83.             echo "
  84.                 ";
  85.             // line 27
  86.             $context["type"] = twig_get_attribute($this->env$this->source, (isset($context["select"]) || array_key_exists("select"$context) ? $context["select"] : (function () { throw new RuntimeError('Variable "select" does not exist.'27$this->source); })()), "getData", [], "method"falsefalsefalse27);
  87.             // line 28
  88.             echo "                ";
  89.             if (((isset($context["type"]) || array_key_exists("type"$context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.'28$this->source); })()) == "direct")) {
  90.                 // line 29
  91.                 echo "                    ";
  92.                 echo twig_include($this->env$context"snippets/standard-teaser.html.twig", ["suffix" => (                // line 31
  93. $context["t"] + 1)]);
  94.                 // line 33
  95.                 echo "
  96.                 ";
  97.             } elseif ((            // line 34
  98. (isset($context["type"]) || array_key_exists("type"$context) ? $context["type"] : (function () { throw new RuntimeError('Variable "type" does not exist.'34$this->source); })()) == "news")) {
  99.                 // line 35
  100.                 echo "                    ";
  101.                 echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"renderlet", ("newsteaser_" .                 // line 36
  102. $context["t"]), ["type" => "object""editmode" =>                 // line 38
  103. (isset($context["editmode"]) || array_key_exists("editmode"$context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.'38$this->source); })()), "controller" => "App\\Controller\\NewsController::newsTeaserAction""title" => "Drag a news object here""height" => "auto""width" => "100%"]);
  104.                 // line 44
  105.                 echo "
  106.                 ";
  107.             } else {
  108.                 // line 46
  109.                 echo "                    ";
  110.                 echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"snippet", ("teaser_" $context["t"]));
  111.                 echo "
  112.                 ";
  113.             }
  114.             // line 48
  115.             echo "
  116.                 ";
  117.             // line 49
  118.             if ((isset($context["editmode"]) || array_key_exists("editmode"$context) ? $context["editmode"] : (function () { throw new RuntimeError('Variable "editmode" does not exist.'49$this->source); })())) {
  119.                 // line 50
  120.                 echo "                    </div>
  121.                 ";
  122.             }
  123.             // line 52
  124.             echo "
  125.             ";
  126.             ++$context['loop']['index0'];
  127.             ++$context['loop']['index'];
  128.             $context['loop']['first'] = false;
  129.             if (isset($context['loop']['length'])) {
  130.                 --$context['loop']['revindex0'];
  131.                 --$context['loop']['revindex'];
  132.                 $context['loop']['last'] = === $context['loop']['revindex0'];
  133.             }
  134.         }
  135.         $_parent $context['_parent'];
  136.         unset($context['_seq'], $context['_iterated'], $context['_key'], $context['t'], $context['_parent'], $context['loop']);
  137.         $context array_intersect_key($context$_parent) + $_parent;
  138.         // line 55
  139.         echo "        </div>
  140.     </div>
  141. </section>
  142. ";
  143.         
  144.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  145.         
  146.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  147.     }
  148.     public function getTemplateName()
  149.     {
  150.         return "areas/standard-teaser/view.html.twig";
  151.     }
  152.     public function isTraitable()
  153.     {
  154.         return false;
  155.     }
  156.     public function getDebugInfo()
  157.     {
  158.         return array (  149 => 55,  133 => 52,  129 => 50,  127 => 49,  124 => 48,  118 => 46,  114 => 44,  112 => 38,  111 => 36,  109 => 35,  107 => 34,  104 => 33,  102 => 31,  100 => 29,  97 => 28,  95 => 27,  92 => 26,  86 => 23,  81 => 20,  79 => 19,  76 => 18,  74 => 7,  72 => 6,  55 => 5,  51 => 4,  47 => 3,  43 => 1,);
  159.     }
  160.     public function getSourceContext()
  161.     {
  162.         return new Source("<section class=\"area-standard-teaser bg-light text-center\">
  163.     <div class=\"container\">
  164.         <h2>{{ pimcore_input('standardTeaserHeading') }}</h2>
  165.         <div class=\"card-deck mb-3 text-center {{ editmode ? 'no-gutters' : '' }} \">
  166.             {% for t in 0..2 %}
  167.                 {%
  168.                     set select = pimcore_select('type_' ~ t, {
  169.                         width: 110,
  170.                         reload: true,
  171.                         store: [
  172.                             ['direct','direct'],
  173.                             ['snippet','snippet'],
  174.                             ['news','news']
  175.                         ],
  176.                         class: 'align-middle'
  177.                     })
  178.                 %}
  179.                 {% if editmode %}
  180.                     <div class=\"col-md-4\">
  181.                         <div class=\"mb-3\">
  182.                             <span class=\"editmode-label align-middle\">Type:</span>
  183.                             {{ select|raw }}
  184.                         </div>
  185.                 {% endif %}
  186.                 {% set type = select.getData() %}
  187.                 {% if type == \"direct\" %}
  188.                     {{
  189.                         include('snippets/standard-teaser.html.twig', {
  190.                             suffix: (t+1)
  191.                         })
  192.                     }}
  193.                 {% elseif type == \"news\" %}
  194.                     {{
  195.                         pimcore_renderlet('newsteaser_' ~ t, {
  196.                             type: 'object',
  197.                             editmode: editmode,
  198.                             controller: 'App\\\\Controller\\\\NewsController::newsTeaserAction',
  199.                             title: 'Drag a news object here',
  200.                             height : 'auto',
  201.                             width: '100%'
  202.                         })
  203.                     }}
  204.                 {% else %}
  205.                     {{ pimcore_snippet('teaser_' ~ t) }}
  206.                 {% endif %}
  207.                 {% if editmode %}
  208.                     </div>
  209.                 {% endif %}
  210.             {% endfor %}
  211.         </div>
  212.     </div>
  213. </section>
  214. ""areas/standard-teaser/view.html.twig""/var/www/html/siteone/templates/areas/standard-teaser/view.html.twig");
  215.     }
  216. }