var/cache/dev/twig/a0/a0de7266a56ab8ee90a9efc83656048e.php line 216

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. /* movie/movies.html.twig */
  14. class __TwigTemplate_87b49ca136bd1e115f5397ae669e0ddb 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->blocks = [
  23.             'content' => [$this'block_content'],
  24.         ];
  25.     }
  26.     protected function doGetParent(array $context)
  27.     {
  28.         // line 1
  29.         return "layouts/layout.html.twig";
  30.     }
  31.     protected function doDisplay(array $context, array $blocks = [])
  32.     {
  33.         $macros $this->macros;
  34.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  35.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""movie/movies.html.twig"));
  36.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  37.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""movie/movies.html.twig"));
  38.         $this->parent $this->loadTemplate("layouts/layout.html.twig""movie/movies.html.twig"1);
  39.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  40.         
  41.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  42.         
  43.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  44.     }
  45.     // line 2
  46.     public function block_content($context, array $blocks = [])
  47.     {
  48.         $macros $this->macros;
  49.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  50.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""content"));
  51.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  52.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""content"));
  53.         // line 3
  54.         echo "
  55.     <div id=\"main-content\" class=\"main-content\">
  56.         ";
  57.         // line 6
  58.         if (twig_test_empty(twig_get_attribute($this->env$this->source, (isset($context["document"]) || array_key_exists("document"$context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.'6$this->source); })()), "getTitle", [], "method"falsefalsefalse6))) {
  59.             // line 7
  60.             echo "            ";
  61.             $this->env->getFunction('pimcore_head_title')->getCallable()(twig_get_attribute($this->env$this->source$this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""headline"), "getData", [], "method"falsefalsefalse7), "PREPEND");
  62.             // line 8
  63.             echo "        ";
  64.         }
  65.         // line 9
  66.         echo "
  67.         <div class=\"page-header\">
  68.             <h1>";
  69.         // line 11
  70.         echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""headline", ["placeholder" => "Headline"]);
  71.         echo "</h1>
  72.         </div>
  73.         ";
  74.         // line 14
  75.         echo $this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"areablock""content", ["allowed" => [=> "headlines"=> "hero-teaser"=> "horizontal-line"=> "wysiwyg"]]);
  76.         // line 23
  77.         echo "
  78.         ";
  79.         // line 25
  80.         if (twig_test_empty(twig_get_attribute($this->env$this->source, (isset($context["document"]) || array_key_exists("document"$context) ? $context["document"] : (function () { throw new RuntimeError('Variable "document" does not exist.'25$this->source); })()), "getTitle", [], "method"falsefalsefalse25))) {
  81.             // line 26
  82.             echo "            ";
  83.             $this->env->getFunction('pimcore_head_title')->getCallable()(twig_get_attribute($this->env$this->source$this->extensions['Pimcore\Twig\Extension\DocumentEditableExtension']->renderEditable($context"input""headline"), "getData", [], "method"falsefalsefalse26), "PREPEND");
  84.             // line 27
  85.             echo "        ";
  86.         }
  87.         // line 28
  88.         echo "
  89.         ";
  90.         // line 29
  91.         if ((twig_length_filter($this->env, (isset($context["movies"]) || array_key_exists("movies"$context) ? $context["movies"] : (function () { throw new RuntimeError('Variable "movies" does not exist.'29$this->source); })())) > 0)) {
  92.             echo 
  93.           <div>
  94.             ";
  95.             // line 31
  96.             if ((isset($context["searchTerm"]) || array_key_exists("searchTerm"$context) ? $context["searchTerm"] : (function () { throw new RuntimeError('Variable "searchTerm" does not exist.'31$this->source); })())) {
  97.                 // line 32
  98.                 echo "            <h1 class=\"d-flex justify-content-center\">Suchergebnisse für \"";
  99.                 echo twig_escape_filter($this->env, (isset($context["searchTerm"]) || array_key_exists("searchTerm"$context) ? $context["searchTerm"] : (function () { throw new RuntimeError('Variable "searchTerm" does not exist.'32$this->source); })()), "html"nulltrue);
  100.                 echo "\" </h1>
  101.             ";
  102.             } elseif (            // line 33
  103. (isset($context["sortByLatest"]) || array_key_exists("sortByLatest"$context) ? $context["sortByLatest"] : (function () { throw new RuntimeError('Variable "sortByLatest" does not exist.'33$this->source); })())) {
  104.                 // line 34
  105.                 echo "            <h1 class=\"d-flex justify-content-center\">Latest Additions</h1>
  106.             ";
  107.             } else {
  108.                 // line 36
  109.                 echo "            <h1 class=\"d-flex justify-content-center\">All Movies </h1>
  110.             ";
  111.             }
  112.             // line 38
  113.             echo "        </div> 
  114.         <div class=\"row\">
  115.             <div class=\"d-flex flex-wrap\">
  116.                  ";
  117.             // line 41
  118.             $context['_parent'] = $context;
  119.             $context['_seq'] = twig_ensure_traversable((isset($context["movies"]) || array_key_exists("movies"$context) ? $context["movies"] : (function () { throw new RuntimeError('Variable "movies" does not exist.'41$this->source); })()));
  120.             foreach ($context['_seq'] as $context["_key"] => $context["movie"]) {
  121.                 echo "  
  122.                  <a href=\"/movie-detail/";
  123.                 // line 42
  124.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["movie"], "id", [], "any"falsefalsefalse42), "html"nulltrue);
  125.                 echo "\">  
  126.                  ";
  127.                 // line 43
  128.                 if (twig_in_filter("Not Owned"twig_join_filter(twig_get_attribute($this->env$this->source$context["movie"], "status", [], "any"falsefalsefalse43), ", "))) {
  129.                     // line 44
  130.                     echo "                    <div class=\"badge\">";
  131.                     echo twig_escape_filter($this->envtwig_join_filter(twig_get_attribute($this->env$this->source$context["movie"], "status", [], "any"falsefalsefalse44), ", "), "html"nulltrue);
  132.                     echo "</div>
  133.                  ";
  134.                 } elseif (twig_in_filter("Ordered"twig_join_filter(twig_get_attribute($this->env$this->source,                 // line 45
  135. $context["movie"], "status", [], "any"falsefalsefalse45), ", "))) {
  136.                     // line 46
  137.                     echo "                    <div class=\"badge\">";
  138.                     echo twig_escape_filter($this->envtwig_join_filter(twig_get_attribute($this->env$this->source$context["movie"], "status", [], "any"falsefalsefalse46), ", "), "html"nulltrue);
  139.                     echo "</div>
  140.                 ";
  141.                 } elseif (twig_test_empty(twig_get_attribute($this->env$this->source,                 // line 47
  142. $context["movie"], "status", [], "any"falsefalsefalse47))) {
  143.                     // line 48
  144.                     echo "                    <div class=\"badge\">Not owned</div>
  145.                  ";
  146.                 } else {
  147.                     // line 50
  148.                     echo "                    
  149.                  ";
  150.                 }
  151.                 // line 52
  152.                 echo "                 <div data-content=\"";
  153.                 echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source$context["movie"], "title", [=> "de"], "method"falsefalsefalse52), "html"nulltrue);
  154.                 echo "\" class=\"image\">                
  155.                          ";
  156.                 // line 54
  157.                 echo "                            ";
  158.                 if ($context["movie"]) {
  159.                     // line 55
  160.                     echo "                                ";
  161.                     if ((twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["movie"], "getImageURL", [], "method"falsefalsefalse55), "getUrl", [], "method"falsefalsefalse55) != "")) {
  162.                         // line 56
  163.                         echo "                                ";
  164.                         // line 57
  165.                         echo "                                <img class\"img-fluid\" src=\"";
  166.                         echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["movie"], "getImageURL", [], "method"falsefalsefalse57), "getUrl", [], "method"falsefalsefalse57), "html"nulltrue);
  167.                         echo "\"/>
  168.                                 ";
  169.                     } else {
  170.                         // line 59
  171.                         echo "                                <img class\"img-fluid\" style=\"margin-right: 25px; margin-bottom: 15px;\" src=\"";
  172.                         echo twig_escape_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["fallbackImage"]) || array_key_exists("fallbackImage"$context) ? $context["fallbackImage"] : (function () { throw new RuntimeError('Variable "fallbackImage" does not exist.'59$this->source); })()), "getThumbnail", [=> "MovieGrid"], "method"falsefalsefalse59), "html"nulltrue);
  173.                         echo "\" />
  174.                                 ";
  175.                     }
  176.                     // line 61
  177.                     echo "                            ";
  178.                 }
  179.                 // line 62
  180.                 echo "                            
  181.                  </div>
  182.                  </a>
  183.                  
  184.                 ";
  185.             }
  186.             $_parent $context['_parent'];
  187.             unset($context['_seq'], $context['_iterated'], $context['_key'], $context['movie'], $context['_parent'], $context['loop']);
  188.             $context array_intersect_key($context$_parent) + $_parent;
  189.             // line 67
  190.             echo "
  191.                 
  192.             </div>
  193.         </div>
  194.           <div class=\"pt-5\">
  195.             ";
  196.             // line 74
  197.             $this->loadTemplate("includes/pagination.html.twig""movie/movies.html.twig"74)->display($context);
  198.             // line 75
  199.             echo "
  200.         </div>
  201.         ";
  202.         } else {
  203.             // line 79
  204.             echo "            <h1 class=\"d-flex justify-content-center\">Keine Suchergebnisse für \"";
  205.             echo twig_escape_filter($this->env, (isset($context["searchTerm"]) || array_key_exists("searchTerm"$context) ? $context["searchTerm"] : (function () { throw new RuntimeError('Variable "searchTerm" does not exist.'79$this->source); })()), "html"nulltrue);
  206.             echo "\" </h1>
  207.         ";
  208.         }
  209.         // line 82
  210.         echo "
  211.     </div> 
  212. ";
  213.         
  214.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  215.         
  216.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  217.     }
  218.     public function getTemplateName()
  219.     {
  220.         return "movie/movies.html.twig";
  221.     }
  222.     public function isTraitable()
  223.     {
  224.         return false;
  225.     }
  226.     public function getDebugInfo()
  227.     {
  228.         return array (  231 => 82,  224 => 79,  218 => 75,  216 => 74,  207 => 67,  197 => 62,  194 => 61,  188 => 59,  182 => 57,  180 => 56,  177 => 55,  174 => 54,  169 => 52,  165 => 50,  161 => 48,  159 => 47,  154 => 46,  152 => 45,  147 => 44,  145 => 43,  141 => 42,  135 => 41,  130 => 38,  126 => 36,  122 => 34,  120 => 33,  115 => 32,  113 => 31,  108 => 29,  105 => 28,  102 => 27,  99 => 26,  97 => 25,  93 => 23,  91 => 14,  85 => 11,  81 => 9,  78 => 8,  75 => 7,  73 => 6,  68 => 3,  58 => 2,  35 => 1,);
  229.     }
  230.     public function getSourceContext()
  231.     {
  232.         return new Source("{% extends 'layouts/layout.html.twig' %}
  233. {% block content %}
  234.     <div id=\"main-content\" class=\"main-content\">
  235.         {% if document.getTitle() is empty %}
  236.             {% do pimcore_head_title(pimcore_input('headline').getData(), 'PREPEND') %}
  237.         {% endif %}
  238.         <div class=\"page-header\">
  239.             <h1>{{ pimcore_input('headline', {'placeholder':'Headline'}) }}</h1>
  240.         </div>
  241.         {{
  242.             pimcore_areablock('content', {
  243.                 'allowed': [
  244.                     'headlines',
  245.                     'hero-teaser',
  246.                     'horizontal-line',
  247.                     'wysiwyg'
  248.                 ]
  249.             })
  250.         }}
  251.         {% if document.getTitle() is empty %}
  252.             {% do pimcore_head_title(pimcore_input('headline').getData(), 'PREPEND') %}
  253.         {% endif %}
  254.         {% if movies|length > 0 %} 
  255.           <div>
  256.             {% if searchTerm %}
  257.             <h1 class=\"d-flex justify-content-center\">Suchergebnisse für \"{{searchTerm}}\" </h1>
  258.             {% elseif sortByLatest %}
  259.             <h1 class=\"d-flex justify-content-center\">Latest Additions</h1>
  260.             {% else %}
  261.             <h1 class=\"d-flex justify-content-center\">All Movies </h1>
  262.             {% endif %}
  263.         </div> 
  264.         <div class=\"row\">
  265.             <div class=\"d-flex flex-wrap\">
  266.                  {%  for movie in movies %}  
  267.                  <a href=\"/movie-detail/{{movie.id}}\">  
  268.                  {% if \"Not Owned\" in movie.status|join(', ') %}
  269.                     <div class=\"badge\">{{movie.status|join(', ')}}</div>
  270.                  {% elseif \"Ordered\" in movie.status|join(', ')  %}
  271.                     <div class=\"badge\">{{movie.status|join(', ')}}</div>
  272.                 {% elseif movie.status is empty %}
  273.                     <div class=\"badge\">Not owned</div>
  274.                  {% else %}
  275.                     
  276.                  {% endif %}
  277.                  <div data-content=\"{{ movie.title(\"de\")}}\" class=\"image\">                
  278.                          {# @var movies \\Pimcore\\Model\\DataObject\\Movies #}
  279.                             {% if movie %}
  280.                                 {% if movie.getImageURL().getUrl() != \"\"  %}
  281.                                 {# TODO get Image Thumbnail #}
  282.                                 <img class\"img-fluid\" src=\"{{ movie.getImageURL().getUrl() }}\"/>
  283.                                 {% else %}
  284.                                 <img class\"img-fluid\" style=\"margin-right: 25px; margin-bottom: 15px;\" src=\"{{fallbackImage.getThumbnail(\"MovieGrid\") }}\" />
  285.                                 {% endif %}
  286.                             {% endif %}
  287.                             
  288.                  </div>
  289.                  </a>
  290.                  
  291.                 {% endfor %}
  292.                 
  293.             </div>
  294.         </div>
  295.           <div class=\"pt-5\">
  296.             {% include 'includes/pagination.html.twig' %}
  297.         </div>
  298.         {% else %}
  299.             <h1 class=\"d-flex justify-content-center\">Keine Suchergebnisse für \"{{searchTerm}}\" </h1>
  300.         {% endif %}
  301.     </div> 
  302. {%  endblock %}
  303. ""movie/movies.html.twig""/var/www/pimcore/MovieCollection/templates/movie/movies.html.twig");
  304.     }
  305. }