var/cache/dev/twig/c8/c8f54ac783ffe04fea78a1fdc3990389.php line 34

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/reference-line.html.twig */
  15. class __TwigTemplate_98900b5431a17cc8d97cf352289c6e71 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/reference-line.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/reference-line.html.twig"));
  34. // line 1
  35. yield "<div class=\"reference\">
  36. ";
  37. // line 2
  38. $context["country"] = CoreExtension::getAttribute($this->env, $this->source, (isset($context["customerMgr"]) || array_key_exists("customerMgr", $context) ? $context["customerMgr"] : (function () { throw new RuntimeError('Variable "customerMgr" does not exist.', 2, $this->source); })()), "getCustomerCountry", [], "method", false, false, false, 2);
  39. // line 3
  40. yield " <div class=\"reference-ctn\">
  41. ";
  42. // line 4
  43. if (CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 4, $this->source); })()), "picture", [], "any", false, false, false, 4)) {
  44. // line 5
  45. yield " <div class=\"img\">
  46. <a href=\"";
  47. // line 6
  48. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getRuntime('Liip\ImagineBundle\Templating\LazyFilterRuntime')->filter($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 6, $this->source); })()), "picture", [], "any", false, false, false, 6), "webPath", [], "any", false, false, false, 6)), "product_zoom"), "html", null, true);
  49. yield "\" data-caption=\"";
  50. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 6, $this->source); })()), "name", [], "any", false, false, false, 6), "html_attr");
  51. yield "\" data-fancybox=\"references\"><img src=\"";
  52. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->env->getRuntime('Liip\ImagineBundle\Templating\LazyFilterRuntime')->filter($this->extensions['Symfony\Bridge\Twig\Extension\AssetExtension']->getAssetUrl(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 6, $this->source); })()), "picture", [], "any", false, false, false, 6), "webPath", [], "any", false, false, false, 6)), "product_small"), "html", null, true);
  53. yield "\" alt=\"";
  54. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 6, $this->source); })()), "name", [], "any", false, false, false, 6), "html_attr");
  55. yield "\"></a>
  56. </div>
  57. ";
  58. }
  59. // line 9
  60. yield " ";
  61. yield from $this->loadTemplate("front/catalog/product/view/soleil.html.twig", "front/catalog/product/view/reference-line.html.twig", 9)->unwrap()->yield($context);
  62. // line 10
  63. yield " <div class=\"stock-ctn\">
  64. ";
  65. // line 11
  66. yield from $this->loadTemplate("front/catalog/product/view/stock.html.twig", "front/catalog/product/view/reference-line.html.twig", 11)->unwrap()->yield($context);
  67. // line 12
  68. yield " ";
  69. if (CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 12, $this->source); })()), "isAvailableForCountry", [(isset($context["country"]) || array_key_exists("country", $context) ? $context["country"] : (function () { throw new RuntimeError('Variable "country" does not exist.', 12, $this->source); })())], "method", false, false, false, 12)) {
  70. // line 13
  71. yield " ";
  72. if (CoreExtension::inFilter(CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 13, $this->source); })()), "id", [], "any", false, false, false, 13), Twig\Extension\CoreExtension::keys((isset($context["discounts"]) || array_key_exists("discounts", $context) ? $context["discounts"] : (function () { throw new RuntimeError('Variable "discounts" does not exist.', 13, $this->source); })())))) {
  73. // line 14
  74. yield " ";
  75. $context["productsDiscounts"] = CoreExtension::getAttribute($this->env, $this->source, (isset($context["discounts"]) || array_key_exists("discounts", $context) ? $context["discounts"] : (function () { throw new RuntimeError('Variable "discounts" does not exist.', 14, $this->source); })()), CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 14, $this->source); })()), "id", [], "any", false, false, false, 14), [], "any", false, false, false, 14);
  76. // line 15
  77. yield " ";
  78. $context['_parent'] = $context;
  79. $context['_seq'] = CoreExtension::ensureTraversable((isset($context["productsDiscounts"]) || array_key_exists("productsDiscounts", $context) ? $context["productsDiscounts"] : (function () { throw new RuntimeError('Variable "productsDiscounts" does not exist.', 15, $this->source); })()));
  80. $context['loop'] = [
  81. 'parent' => $context['_parent'],
  82. 'index0' => 0,
  83. 'index' => 1,
  84. 'first' => true,
  85. ];
  86. if (is_array($context['_seq']) || (is_object($context['_seq']) && $context['_seq'] instanceof \Countable)) {
  87. $length = count($context['_seq']);
  88. $context['loop']['revindex0'] = $length - 1;
  89. $context['loop']['revindex'] = $length;
  90. $context['loop']['length'] = $length;
  91. $context['loop']['last'] = 1 === $length;
  92. }
  93. foreach ($context['_seq'] as $context["_key"] => $context["discount"]) {
  94. // line 16
  95. yield " ";
  96. yield from $this->loadTemplate("front/catalog/product/view/discount.html.twig", "front/catalog/product/view/reference-line.html.twig", 16)->unwrap()->yield(CoreExtension::merge($context, ["discount" => $context["discount"]]));
  97. // line 17
  98. yield " ";
  99. ++$context['loop']['index0'];
  100. ++$context['loop']['index'];
  101. $context['loop']['first'] = false;
  102. if (isset($context['loop']['length'])) {
  103. --$context['loop']['revindex0'];
  104. --$context['loop']['revindex'];
  105. $context['loop']['last'] = 0 === $context['loop']['revindex0'];
  106. }
  107. }
  108. $_parent = $context['_parent'];
  109. unset($context['_seq'], $context['_iterated'], $context['_key'], $context['discount'], $context['_parent'], $context['loop']);
  110. $context = array_intersect_key($context, $_parent) + $_parent;
  111. // line 18
  112. yield " ";
  113. }
  114. // line 19
  115. yield " ";
  116. }
  117. // line 20
  118. yield " </div>
  119. <div class=\"name-ctn\">
  120. ";
  121. // line 22
  122. if (CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 22, $this->source); })()), "parent", [], "any", false, false, false, 22)) {
  123. // line 23
  124. yield " <div class=\"name\">";
  125. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(Twig\Extension\CoreExtension::slice($this->env->getCharset(), CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 23, $this->source); })()), "name", [], "any", false, false, false, 23), (Twig\Extension\CoreExtension::length($this->env->getCharset(), CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 23, $this->source); })()), "parent", [], "any", false, false, false, 23), "name", [], "any", false, false, false, 23)) + 2), Twig\Extension\CoreExtension::length($this->env->getCharset(), CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 23, $this->source); })()), "name", [], "any", false, false, false, 23))), "html", null, true);
  126. yield "</div>
  127. ";
  128. } else {
  129. // line 25
  130. yield " <div class=\"name\"></div>
  131. ";
  132. }
  133. // line 27
  134. yield " ";
  135. if (CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 27, $this->source); })()), "isAvailableForCountry", [(isset($context["country"]) || array_key_exists("country", $context) ? $context["country"] : (function () { throw new RuntimeError('Variable "country" does not exist.', 27, $this->source); })())], "method", false, false, false, 27)) {
  136. // line 28
  137. yield " ";
  138. if (CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 28, $this->source); })()), "getPrice", [false, (isset($context["priceGroup"]) || array_key_exists("priceGroup", $context) ? $context["priceGroup"] : (function () { throw new RuntimeError('Variable "priceGroup" does not exist.', 28, $this->source); })())], "method", false, false, false, 28)) {
  139. // line 29
  140. yield " ";
  141. if ((CoreExtension::getAttribute($this->env, $this->source, (isset($context["customerMgr"]) || array_key_exists("customerMgr", $context) ? $context["customerMgr"] : (function () { throw new RuntimeError('Variable "customerMgr" does not exist.', 29, $this->source); })()), "canSeePrices", [], "method", false, false, false, 29) && !CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 29, $this->source); })()), "isStopped", [], "method", false, false, false, 29))) {
  142. // line 30
  143. yield " ";
  144. yield from $this->loadTemplate("front/catalog/product/view/price-grid.html.twig", "front/catalog/product/view/reference-line.html.twig", 30)->unwrap()->yield(CoreExtension::merge($context, ["priceGrid" => CoreExtension::getAttribute($this->env, $this->source, (isset($context["priceGrids"]) || array_key_exists("priceGrids", $context) ? $context["priceGrids"] : (function () { throw new RuntimeError('Variable "priceGrids" does not exist.', 30, $this->source); })()), CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 30, $this->source); })()), "id", [], "any", false, false, false, 30), [], "any", false, false, false, 30)]));
  145. // line 31
  146. yield " ";
  147. }
  148. // line 32
  149. yield " ";
  150. $context["currentQty"] = CoreExtension::getAttribute($this->env, $this->source, (isset($context["cartMgr"]) || array_key_exists("cartMgr", $context) ? $context["cartMgr"] : (function () { throw new RuntimeError('Variable "cartMgr" does not exist.', 32, $this->source); })()), "qtyInCart", [(isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 32, $this->source); })())], "method", false, false, false, 32);
  151. // line 33
  152. yield " <div class=\"bt-cart ";
  153. yield ((((isset($context["currentQty"]) || array_key_exists("currentQty", $context) ? $context["currentQty"] : (function () { throw new RuntimeError('Variable "currentQty" does not exist.', 33, $this->source); })()) > 0)) ? ("in-cart") : (""));
  154. yield "\">
  155. ";
  156. // line 34
  157. if ((CoreExtension::getAttribute($this->env, $this->source, (isset($context["customerMgr"]) || array_key_exists("customerMgr", $context) ? $context["customerMgr"] : (function () { throw new RuntimeError('Variable "customerMgr" does not exist.', 34, $this->source); })()), "canSeePrices", [], "method", false, false, false, 34) && CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 34, $this->source); })()), "isAvailable", [], "method", false, false, false, 34))) {
  158. // line 35
  159. yield " ";
  160. yield from $this->loadTemplate("front/cart/bt.html.twig", "front/catalog/product/view/reference-line.html.twig", 35)->unwrap()->yield(CoreExtension::merge($context, ["product" => (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 35, $this->source); })())]));
  161. // line 36
  162. yield " <div class=\"qty\">
  163. <a class=\"down\">-</a>
  164. <input type=\"text\" value=\"";
  165. // line 38
  166. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape((isset($context["currentQty"]) || array_key_exists("currentQty", $context) ? $context["currentQty"] : (function () { throw new RuntimeError('Variable "currentQty" does not exist.', 38, $this->source); })()), "html", null, true);
  167. yield "\" name=\"qty[";
  168. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 38, $this->source); })()), "id", [], "any", false, false, false, 38), "html", null, true);
  169. yield "]\" class=\"qty-value\" data-id=\"";
  170. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 38, $this->source); })()), "id", [], "any", false, false, false, 38), "html", null, true);
  171. yield "\">
  172. <a class=\"up\">+</a>
  173. </div>
  174. ";
  175. }
  176. // line 42
  177. yield " </div>
  178. ";
  179. } elseif (CoreExtension::getAttribute($this->env, $this->source, // line 43
  180. (isset($context["customerMgr"]) || array_key_exists("customerMgr", $context) ? $context["customerMgr"] : (function () { throw new RuntimeError('Variable "customerMgr" does not exist.', 43, $this->source); })()), "isExpert", [], "method", false, false, false, 43)) {
  181. // line 44
  182. yield " <p>";
  183. yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Produit non disponible pour les Experts", [], "messages");
  184. yield "</p>
  185. ";
  186. }
  187. // line 46
  188. yield " ";
  189. }
  190. // line 47
  191. yield " </div>
  192. </div>
  193. ";
  194. // line 49
  195. if ((CoreExtension::getAttribute($this->env, $this->source, (isset($context["customerMgr"]) || array_key_exists("customerMgr", $context) ? $context["customerMgr"] : (function () { throw new RuntimeError('Variable "customerMgr" does not exist.', 49, $this->source); })()), "canSeePrices", [], "method", false, false, false, 49) && (CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 49, $this->source); })()), "ecotax", [], "any", false, false, false, 49) > 0))) {
  196. // line 50
  197. yield " <div class=\"eco-tax\">";
  198. yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Eco-participation", [], "messages");
  199. yield " : ";
  200. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape($this->extensions['App\Twig\PriceExtension']->priceFilter(CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 50, $this->source); })()), "ecotax", [], "any", false, false, false, 50)), "html", null, true);
  201. yield "</div>
  202. ";
  203. }
  204. // line 52
  205. yield " ";
  206. if (((CoreExtension::getAttribute($this->env, $this->source, (isset($context["customerMgr"]) || array_key_exists("customerMgr", $context) ? $context["customerMgr"] : (function () { throw new RuntimeError('Variable "customerMgr" does not exist.', 52, $this->source); })()), "canSeePrices", [], "method", false, false, false, 52) && !CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 52, $this->source); })()), "isStopped", [], "method", false, false, false, 52)) && !CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 52, $this->source); })()), "isAvailable", [], "method", false, false, false, 52))) {
  207. // line 53
  208. yield " <div class=\"stock-alert\" style=\"height:30px; line-height:15px;\">
  209. <a data-product=\"";
  210. // line 54
  211. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["product"]) || array_key_exists("product", $context) ? $context["product"] : (function () { throw new RuntimeError('Variable "product" does not exist.', 54, $this->source); })()), "id", [], "any", false, false, false, 54), "html", null, true);
  212. yield "\" data-customer=\"";
  213. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, (isset($context["customer"]) || array_key_exists("customer", $context) ? $context["customer"] : (function () { throw new RuntimeError('Variable "customer" does not exist.', 54, $this->source); })()), "id", [], "any", false, false, false, 54), "html", null, true);
  214. yield "\" data-language=\"";
  215. yield $this->env->getRuntime('Twig\Runtime\EscaperRuntime')->escape(CoreExtension::getAttribute($this->env, $this->source, CoreExtension::getAttribute($this->env, $this->source, (isset($context["app"]) || array_key_exists("app", $context) ? $context["app"] : (function () { throw new RuntimeError('Variable "app" does not exist.', 54, $this->source); })()), "request", [], "any", false, false, false, 54), "getLocale", [], "method", false, false, false, 54), "html", null, true);
  216. yield "\" class=\"bt-stock-alert\">";
  217. yield $this->env->getExtension('Symfony\Bridge\Twig\Extension\TranslationExtension')->trans("Prévenez-moi par email dès que l'article est en stock.", [], "messages");
  218. yield "</a><br>
  219. </div>
  220. ";
  221. }
  222. // line 57
  223. yield "</div>";
  224. $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  225. $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  226. return; yield '';
  227. }
  228. /**
  229. * @codeCoverageIgnore
  230. */
  231. public function getTemplateName()
  232. {
  233. return "front/catalog/product/view/reference-line.html.twig";
  234. }
  235. /**
  236. * @codeCoverageIgnore
  237. */
  238. public function isTraitable()
  239. {
  240. return false;
  241. }
  242. /**
  243. * @codeCoverageIgnore
  244. */
  245. public function getDebugInfo()
  246. {
  247. return array ( 232 => 57, 220 => 54, 217 => 53, 214 => 52, 206 => 50, 204 => 49, 200 => 47, 197 => 46, 191 => 44, 189 => 43, 186 => 42, 175 => 38, 171 => 36, 168 => 35, 166 => 34, 161 => 33, 158 => 32, 155 => 31, 152 => 30, 149 => 29, 146 => 28, 143 => 27, 139 => 25, 133 => 23, 131 => 22, 127 => 20, 124 => 19, 121 => 18, 107 => 17, 104 => 16, 86 => 15, 83 => 14, 80 => 13, 77 => 12, 75 => 11, 72 => 10, 69 => 9, 57 => 6, 54 => 5, 52 => 4, 49 => 3, 47 => 2, 44 => 1,);
  248. }
  249. public function getSourceContext()
  250. {
  251. return new Source("<div class=\"reference\">
  252. {% set country = customerMgr.getCustomerCountry() %}
  253. <div class=\"reference-ctn\">
  254. {% if product.picture %}
  255. <div class=\"img\">
  256. <a href=\"{{ asset(product.picture.webPath) | imagine_filter('product_zoom') }}\" data-caption=\"{{ product.name|escape('html_attr') }}\" data-fancybox=\"references\"><img src=\"{{ asset(product.picture.webPath) | imagine_filter('product_small') }}\" alt=\"{{ product.name|e('html_attr') }}\"></a>
  257. </div>
  258. {% endif %}
  259. {% include 'front/catalog/product/view/soleil.html.twig' %}
  260. <div class=\"stock-ctn\">
  261. {% include 'front/catalog/product/view/stock.html.twig' %}
  262. {% if product.isAvailableForCountry(country) %}
  263. {% if product.id in discounts|keys %}
  264. {% set productsDiscounts = attribute(discounts, product.id) %}
  265. {% for discount in productsDiscounts %}
  266. {% include 'front/catalog/product/view/discount.html.twig' with {discount:discount} %}
  267. {% endfor %}
  268. {% endif %}
  269. {% endif %}
  270. </div>
  271. <div class=\"name-ctn\">
  272. {% if product.parent %}
  273. <div class=\"name\">{{ product.name|slice(product.parent.name|length+2, product.name|length) }}</div>
  274. {% else %}
  275. <div class=\"name\"></div>
  276. {% endif %}
  277. {% if product.isAvailableForCountry(country) %}
  278. {% if product.getPrice(false, priceGroup) %}
  279. {% if customerMgr.canSeePrices() and not product.isStopped() %}
  280. {% include 'front/catalog/product/view/price-grid.html.twig' with {priceGrid:attribute(priceGrids,product.id)} %}
  281. {% endif %}
  282. {% set currentQty = cartMgr.qtyInCart(product) %}
  283. <div class=\"bt-cart {{ currentQty > 0 ? 'in-cart' : ''}}\">
  284. {% if customerMgr.canSeePrices() and product.isAvailable() %}
  285. {% include 'front/cart/bt.html.twig' with {product:product} %}
  286. <div class=\"qty\">
  287. <a class=\"down\">-</a>
  288. <input type=\"text\" value=\"{{ currentQty }}\" name=\"qty[{{ product.id }}]\" class=\"qty-value\" data-id=\"{{ product.id }}\">
  289. <a class=\"up\">+</a>
  290. </div>
  291. {% endif %}
  292. </div>
  293. {% elseif customerMgr.isExpert() %}
  294. <p>{% trans %}Produit non disponible pour les Experts{% endtrans %}</p>
  295. {% endif %}
  296. {% endif %}
  297. </div>
  298. </div>
  299. {% if customerMgr.canSeePrices() and (product.ecotax > 0) %}
  300. <div class=\"eco-tax\">{% trans %}Eco-participation{% endtrans %} : {{ product.ecotax|price }}</div>
  301. {% endif %}
  302. {% if customerMgr.canSeePrices() and not product.isStopped() and not product.isAvailable() %}
  303. <div class=\"stock-alert\" style=\"height:30px; line-height:15px;\">
  304. <a data-product=\"{{ product.id }}\" data-customer=\"{{ customer.id }}\" data-language=\"{{ app.request.getLocale() }}\" class=\"bt-stock-alert\">{% trans %}Prévenez-moi par email dès que l'article est en stock.{% endtrans %}</a><br>
  305. </div>
  306. {% endif %}
  307. </div>", "front/catalog/product/view/reference-line.html.twig", "/var/www/dogcat.com/v2-test/templates/front/catalog/product/view/reference-line.html.twig");
  308. }
  309. }