var/cache/dev/twig/ba/baea5ef18a3717c42da92b990bc0eef7.php line 39

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. /* front/blog/list-articles.html.twig */
  14. class __TwigTemplate_6c9c81591f4c872b3420e748de3857bd 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.             'title' => [$this'block_title'],
  24.             'body' => [$this'block_body'],
  25.         ];
  26.     }
  27.     protected function doGetParent(array $context)
  28.     {
  29.         // line 1
  30.         return "front/base.html.twig";
  31.     }
  32.     protected function doDisplay(array $context, array $blocks = [])
  33.     {
  34.         $macros $this->macros;
  35.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  36.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""front/blog/list-articles.html.twig"));
  37.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  38.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""front/blog/list-articles.html.twig"));
  39.         $this->parent $this->loadTemplate("front/base.html.twig""front/blog/list-articles.html.twig"1);
  40.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  41.         
  42.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  43.         
  44.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  45.     }
  46.     // line 3
  47.     public function block_title($context, array $blocks = [])
  48.     {
  49.         $macros $this->macros;
  50.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  51.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""title"));
  52.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  53.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""title"));
  54.         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("blog.title"), "html"nulltrue);
  55.         echo "
  56. ";
  57.         
  58.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  59.         
  60.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  61.     }
  62.     // line 6
  63.     public function block_body($context, array $blocks = [])
  64.     {
  65.         $macros $this->macros;
  66.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  67.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""body"));
  68.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  69.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""body"));
  70.         // line 7
  71.         echo "
  72. \t<section class=\"mt-0 first-section\" id=\"blog-search\">
  73. \t\t<div class=\"container\">
  74. \t\t\t<div class=\"row justify-content-center\">\t
  75. \t\t\t\t<div class=\"col-lg-8\">
  76. \t\t\t\t\t";
  77.         // line 12
  78.         echo         $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->renderBlock((isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'12$this->source); })()), 'form_start', ["attr" => ["class" => "blog-main-search"]]);
  79.         echo "
  80. \t\t\t\t\t\t<div class=\"form-inline\">
  81. \t\t\t\t\t\t\t";
  82.         // line 14
  83.         echo $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->searchAndRenderBlock(twig_get_attribute($this->env$this->source, (isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'14$this->source); })()), "title", [], "any"falsefalsefalse14), 'widget', ["attr" => ["class" => "input-main-search"]]);
  84.         echo "
  85. \t\t\t\t\t\t\t<button class=\"btn btn-main-search\" type=\"submit\">
  86. \t\t\t\t\t\t\t\t<span class=\"hide-mobile\">";
  87.         // line 16
  88.         echo twig_escape_filter($this->envtwig_capitalize_string_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("global.search")), "html"nulltrue);
  89.         echo "</span>
  90. \t\t\t\t\t\t\t\t<i class=\"far fa-search hide-desktop\"></i>
  91. \t\t\t\t\t\t\t</button>
  92. \t\t\t\t\t\t</div>
  93. \t\t\t\t\t";
  94.         // line 20
  95.         echo         $this->env->getRuntime('Symfony\Component\Form\FormRenderer')->renderBlock((isset($context["form"]) || array_key_exists("form"$context) ? $context["form"] : (function () { throw new RuntimeError('Variable "form" does not exist.'20$this->source); })()), 'form_end');
  96.         echo "
  97. \t\t\t\t</div>
  98. \t\t\t</div>
  99. \t\t</div>
  100. \t</section>
  101. \t<section id=\"blog\" class=\"pt-0\">
  102. \t\t<div class=\"container\">
  103. \t\t\t<h2 class=\"section-title-underline\">";
  104.         // line 28
  105.         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans((isset($context["title"]) || array_key_exists("title"$context) ? $context["title"] : (function () { throw new RuntimeError('Variable "title" does not exist.'28$this->source); })())), "html"nulltrue);
  106.         echo "</h2>
  107. \t\t\t<div class=\"row\">
  108. \t\t\t\t";
  109.         // line 30
  110.         if ((twig_get_attribute($this->env$this->source, (isset($context["articles"]) || array_key_exists("articles"$context) ? $context["articles"] : (function () { throw new RuntimeError('Variable "articles" does not exist.'30$this->source); })()), "getTotalItemCount", [], "any"falsefalsefalse30) > 0)) {
  111.             // line 31
  112.             echo "\t\t\t\t\t";
  113.             $context['_parent'] = $context;
  114.             $context['_seq'] = twig_ensure_traversable((isset($context["articles"]) || array_key_exists("articles"$context) ? $context["articles"] : (function () { throw new RuntimeError('Variable "articles" does not exist.'31$this->source); })()));
  115.             $context['loop'] = [
  116.               'parent' => $context['_parent'],
  117.               'index0' => 0,
  118.               'index'  => 1,
  119.               'first'  => true,
  120.             ];
  121.             if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  122.                 $length count($context['_seq']);
  123.                 $context['loop']['revindex0'] = $length 1;
  124.                 $context['loop']['revindex'] = $length;
  125.                 $context['loop']['length'] = $length;
  126.                 $context['loop']['last'] = === $length;
  127.             }
  128.             foreach ($context['_seq'] as $context["_key"] => $context["article"]) {
  129.                 // line 32
  130.                 echo "\t\t\t\t\t\t<div class=\"col-xl-3 col-lg-4 col-md-6 col-sm-12 blog-col\">
  131. \t\t\t\t\t\t\t";
  132.                 // line 33
  133.                 $this->loadTemplate("front/blog/_blog-card.html.twig""front/blog/list-articles.html.twig"33)->display($context);
  134.                 // line 34
  135.                 echo "\t\t\t\t\t\t</div>
  136. \t\t\t\t\t";
  137.                 ++$context['loop']['index0'];
  138.                 ++$context['loop']['index'];
  139.                 $context['loop']['first'] = false;
  140.                 if (isset($context['loop']['length'])) {
  141.                     --$context['loop']['revindex0'];
  142.                     --$context['loop']['revindex'];
  143.                     $context['loop']['last'] = === $context['loop']['revindex0'];
  144.                 }
  145.             }
  146.             $_parent $context['_parent'];
  147.             unset($context['_seq'], $context['_iterated'], $context['_key'], $context['article'], $context['_parent'], $context['loop']);
  148.             $context array_intersect_key($context$_parent) + $_parent;
  149.             // line 36
  150.             echo "
  151. \t\t\t\t";
  152.         } else {
  153.             // line 38
  154.             echo "\t\t\t\t\t<div class=\"col-lg-12\">
  155. \t\t\t\t\t\t<div class=\"blog-box\">
  156. \t\t\t\t\t\t\t<p class=\"empty-blog\">";
  157.             // line 40
  158.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("blog.no_articles_found"), "html"nulltrue);
  159.             echo "</p>
  160. \t\t\t\t\t\t</div>
  161. \t\t\t\t\t</div>
  162. \t\t\t\t";
  163.         }
  164.         // line 44
  165.         echo "\t\t\t</div>
  166. \t\t\t<div class=\"row d-flex justify-content-center\">
  167. \t\t\t\t";
  168.         // line 47
  169.         echo $this->extensions['Knp\Bundle\PaginatorBundle\Twig\Extension\PaginationExtension']->render($this->env, (isset($context["articles"]) || array_key_exists("articles"$context) ? $context["articles"] : (function () { throw new RuntimeError('Variable "articles" does not exist.'47$this->source); })()), "front/_partials/availabilities-pagination.html.twig");
  170.         echo "
  171. \t\t\t</div>
  172. \t\t</div>
  173. \t</section>
  174. \t";
  175.         // line 53
  176.         $this->loadTemplate("front/blog/_blog-cta.html.twig""front/blog/list-articles.html.twig"53)->display($context);
  177.         // line 54
  178.         echo "
  179. ";
  180.         
  181.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  182.         
  183.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  184.     }
  185.     /**
  186.      * @codeCoverageIgnore
  187.      */
  188.     public function getTemplateName()
  189.     {
  190.         return "front/blog/list-articles.html.twig";
  191.     }
  192.     /**
  193.      * @codeCoverageIgnore
  194.      */
  195.     public function isTraitable()
  196.     {
  197.         return false;
  198.     }
  199.     /**
  200.      * @codeCoverageIgnore
  201.      */
  202.     public function getDebugInfo()
  203.     {
  204.         return array (  201 => 54,  199 => 53,  190 => 47,  185 => 44,  178 => 40,  174 => 38,  170 => 36,  155 => 34,  153 => 33,  150 => 32,  132 => 31,  130 => 30,  125 => 28,  114 => 20,  107 => 16,  102 => 14,  97 => 12,  90 => 7,  80 => 6,  59 => 3,  36 => 1,);
  205.     }
  206.     public function getSourceContext()
  207.     {
  208.         return new Source("{% extends \"front/base.html.twig\" %}
  209. {% block title %}{{ 'blog.title' | trans }}
  210. {% endblock %}
  211. {% block body %}
  212. \t<section class=\"mt-0 first-section\" id=\"blog-search\">
  213. \t\t<div class=\"container\">
  214. \t\t\t<div class=\"row justify-content-center\">\t
  215. \t\t\t\t<div class=\"col-lg-8\">
  216. \t\t\t\t\t{{ form_start(form, {'attr': {'class': 'blog-main-search'}}) }}
  217. \t\t\t\t\t\t<div class=\"form-inline\">
  218. \t\t\t\t\t\t\t{{ form_widget(form.title, {'attr': {'class': 'input-main-search'}}) }}
  219. \t\t\t\t\t\t\t<button class=\"btn btn-main-search\" type=\"submit\">
  220. \t\t\t\t\t\t\t\t<span class=\"hide-mobile\">{{ 'global.search' | trans | capitalize }}</span>
  221. \t\t\t\t\t\t\t\t<i class=\"far fa-search hide-desktop\"></i>
  222. \t\t\t\t\t\t\t</button>
  223. \t\t\t\t\t\t</div>
  224. \t\t\t\t\t{{ form_end(form) }}
  225. \t\t\t\t</div>
  226. \t\t\t</div>
  227. \t\t</div>
  228. \t</section>
  229. \t<section id=\"blog\" class=\"pt-0\">
  230. \t\t<div class=\"container\">
  231. \t\t\t<h2 class=\"section-title-underline\">{{ title | trans }}</h2>
  232. \t\t\t<div class=\"row\">
  233. \t\t\t\t{% if articles.getTotalItemCount > 0 %}
  234. \t\t\t\t\t{% for article in articles %}
  235. \t\t\t\t\t\t<div class=\"col-xl-3 col-lg-4 col-md-6 col-sm-12 blog-col\">
  236. \t\t\t\t\t\t\t{% include \"front/blog/_blog-card.html.twig\" %}
  237. \t\t\t\t\t\t</div>
  238. \t\t\t\t\t{% endfor %}
  239. \t\t\t\t{% else %}
  240. \t\t\t\t\t<div class=\"col-lg-12\">
  241. \t\t\t\t\t\t<div class=\"blog-box\">
  242. \t\t\t\t\t\t\t<p class=\"empty-blog\">{{ \"blog.no_articles_found\" | trans }}</p>
  243. \t\t\t\t\t\t</div>
  244. \t\t\t\t\t</div>
  245. \t\t\t\t{% endif %}
  246. \t\t\t</div>
  247. \t\t\t<div class=\"row d-flex justify-content-center\">
  248. \t\t\t\t{{ knp_pagination_render(articles, 'front/_partials/availabilities-pagination.html.twig') }}
  249. \t\t\t</div>
  250. \t\t</div>
  251. \t</section>
  252. \t{% include \"front/blog/_blog-cta.html.twig\" %}
  253. {% endblock %}
  254. ""front/blog/list-articles.html.twig""/var/www/preprod/racket-trip/templates/front/blog/list-articles.html.twig");
  255.     }
  256. }