var/cache/dev/twig/0a/0a730e394f8eae2a0e2c90a34ca61365.php line 77

Open in your IDE?
  1. <?php
  2. use Twig\Environment;
  3. use Twig\Error\LoaderError;
  4. use Twig\Error\RuntimeError;
  5. use Twig\Extension\CoreExtension;
  6. use Twig\Extension\SandboxExtension;
  7. use Twig\Markup;
  8. use Twig\Sandbox\SecurityError;
  9. use Twig\Sandbox\SecurityNotAllowedTagError;
  10. use Twig\Sandbox\SecurityNotAllowedFilterError;
  11. use Twig\Sandbox\SecurityNotAllowedFunctionError;
  12. use Twig\Source;
  13. use Twig\Template;
  14. /* front/catalog/product/view/list.html.twig */
  15. class __TwigTemplate_7d6b2f665ec77d034bad1480fe5aecdc extends Template
  16. {
  17. private $source;
  18. private $macros = [];
  19. public function __construct(Environment $env)
  20. {
  21. parent::__construct($env);
  22. $this->source = $this->getSourceContext();
  23. $this->parent = false;
  24. $this->blocks = [
  25. ];
  26. }
  27. protected function doDisplay(array $context, array $blocks = [])
  28. {
  29. $macros = $this->macros;
  30. $__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  31. $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "front/catalog/product/view/list.html.twig"));
  32. $__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  33. $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "front/catalog/product/view/list.html.twig"));
  34. // line 1
  35. if ( !array_key_exists("wrapperTag", $context)) {
  36. // line 2
  37. yield " ";
  38. $context["wrapperTag"] = "ul";
  39. }
  40. // line 4
  41. if ((isset($context["wrapperTag"]) || array_key_exists("wrapperTag", $context) ? $context["wrapperTag"] : (function () { throw new RuntimeError('Variable "wrapperTag" does not exist.', 4, $this->source); })())) {
  42. // line 5
  43. yield "<";
  44. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["wrapperTag"]) || array_key_exists("wrapperTag", $context) ? $context["wrapperTag"] : (function () { throw new RuntimeError('Variable "wrapperTag" does not exist.', 5, $this->source); })()), "html", null, true);
  45. yield " class=\"product-list\">
  46. ";
  47. }
  48. // line 7
  49. yield " ";
  50. $context['_parent'] = $context;
  51. $context['_seq'] = CoreExtension::ensureTraversable((isset($context["products"]) || array_key_exists("products", $context) ? $context["products"] : (function () { throw new RuntimeError('Variable "products" does not exist.', 7, $this->source); })()));
  52. $context['loop'] = [
  53. 'parent' => $context['_parent'],
  54. 'index0' => 0,
  55. 'index' => 1,
  56. 'first' => true,
  57. ];
  58. if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  59. $length = count($context['_seq']);
  60. $context['loop']['revindex0'] = $length - 1;
  61. $context['loop']['revindex'] = $length;
  62. $context['loop']['length'] = $length;
  63. $context['loop']['last'] = 1 === $length;
  64. }
  65. foreach ($context['_seq'] as $context["_key"] => $context["p"]) {
  66. // line 8
  67. yield " ";
  68. yield from $this->loadTemplate("front/catalog/product/view/list-item.html.twig", "front/catalog/product/view/list.html.twig", 8)->unwrap()->yield(CoreExtension::merge($context, ["product" => $context["p"]]));
  69. // line 9
  70. yield " ";
  71. ++$context['loop']['index0'];
  72. ++$context['loop']['index'];
  73. $context['loop']['first'] = false;
  74. if (isset($context['loop']['length'])) {
  75. --$context['loop']['revindex0'];
  76. --$context['loop']['revindex'];
  77. $context['loop']['last'] = 0 === $context['loop']['revindex0'];
  78. }
  79. }
  80. $_parent = $context['_parent'];
  81. unset($context['_seq'], $context['_iterated'], $context['_key'], $context['p'], $context['_parent'], $context['loop']);
  82. $context = array_intersect_key($context, $_parent) + $_parent;
  83. // line 10
  84. if ((isset($context["wrapperTag"]) || array_key_exists("wrapperTag", $context) ? $context["wrapperTag"] : (function () { throw new RuntimeError('Variable "wrapperTag" does not exist.', 10, $this->source); })())) {
  85. // line 11
  86. yield "</";
  87. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["wrapperTag"]) || array_key_exists("wrapperTag", $context) ? $context["wrapperTag"] : (function () { throw new RuntimeError('Variable "wrapperTag" does not exist.', 11, $this->source); })()), "html", null, true);
  88. yield ">
  89. ";
  90. }
  91. $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  92. $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  93. return; yield '';
  94. }
  95. /**
  96. * @codeCoverageIgnore
  97. */
  98. public function getTemplateName()
  99. {
  100. return "front/catalog/product/view/list.html.twig";
  101. }
  102. /**
  103. * @codeCoverageIgnore
  104. */
  105. public function isTraitable()
  106. {
  107. return false;
  108. }
  109. /**
  110. * @codeCoverageIgnore
  111. */
  112. public function getDebugInfo()
  113. {
  114. return array ( 95 => 11, 93 => 10, 79 => 9, 76 => 8, 58 => 7, 52 => 5, 50 => 4, 46 => 2, 44 => 1,);
  115. }
  116. public function getSourceContext()
  117. {
  118. return new Source("{% if wrapperTag is not defined %}
  119. {% set wrapperTag = 'ul' %}
  120. {% endif %}
  121. {% if wrapperTag %}
  122. <{{ wrapperTag }} class=\"product-list\">
  123. {% endif %}
  124. {% for p in products %}
  125. {% include 'front/catalog/product/view/list-item.html.twig' with {product:p} %}
  126. {% endfor %}
  127. {% if wrapperTag %}
  128. </{{ wrapperTag }}>
  129. {% endif %}", "front/catalog/product/view/list.html.twig", "/var/www/dogcat.com/v2-test/templates/front/catalog/product/view/list.html.twig");
  130. }
  131. }