var/cache/dev/twig/0a/0ad3d7b1437b69b69303f6b0f59ea154.php line 40

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. /* Cart/list.html.twig */
  14. class __TwigTemplate_1f8b5d33146c74944fb328ae6b5468d7 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.         $this->sandbox $this->env->getExtension('\Twig\Extension\SandboxExtension');
  26.         $this->checkSecurity();
  27.     }
  28.     protected function doGetParent(array $context)
  29.     {
  30.         // line 1
  31.         return "cart.html.twig";
  32.     }
  33.     protected function doDisplay(array $context, array $blocks = [])
  34.     {
  35.         $macros $this->macros;
  36.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  37.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Cart/list.html.twig"));
  38.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  39.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template""Cart/list.html.twig"));
  40.         $this->parent $this->loadTemplate("cart.html.twig""Cart/list.html.twig"1);
  41.         $this->parent->display($contextarray_merge($this->blocks$blocks));
  42.         
  43.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  44.         
  45.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  46.     }
  47.     // line 2
  48.     public function block_content($context, array $blocks = [])
  49.     {
  50.         $macros $this->macros;
  51.         $__internal_5a27a8ba21ca79b61932376b2fa922d2 $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
  52.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""content"));
  53.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
  54.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block""content"));
  55.         // line 3
  56.         echo "<div class=\"breadcrumb-block\">
  57.     <div class=\"container\">
  58.       <!-- breadcrumb of the page -->
  59.       <ul class=\"breadcrumb\">
  60.         <li><a href=\"/";
  61.         // line 7
  62.         echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed((isset($context["locale"]) || array_key_exists("locale"$context) ? $context["locale"] : (function () { throw new RuntimeError('Variable "locale" does not exist.'7$this->source); })()), 7$this->source), "html"nulltrue);
  63.         echo "/\" class=\"home\">";
  64.         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("espirits.header.home"), "html"nulltrue);
  65.         echo "</a></li>
  66.         <li>";
  67.         // line 8
  68.         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("espirits.delivery.product-file-list"), "html"nulltrue);
  69.         echo "</li>
  70.       </ul>
  71.     </div>
  72. </div>
  73. <div class=\"row container\">
  74.     <div class=\"col-xs-12\">\t
  75.     \t<div class=\"row\">
  76. \t        <h1 class=\"page-heading-title\">";
  77.         // line 15
  78.         echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("espirits.delivery.product-file-list"), "html"nulltrue);
  79.         echo "</h1>
  80. \t        ";
  81.         // line 17
  82.         if ((twig_length_filter($this->envtwig_get_attribute($this->env$this->source, (isset($context["cart"]) || array_key_exists("cart"$context) ? $context["cart"] : (function () { throw new RuntimeError('Variable "cart" does not exist.'17$this->source); })()), "getItems", [], "method"falsefalsetrue17)) == 0)) {
  83.             // line 18
  84.             echo "\t            ";
  85.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("cart.empty"), "html"nulltrue);
  86.             echo "
  87. \t        ";
  88.         } else {
  89.             // line 20
  90.             echo "\t            <form method=\"post\" action=\"";
  91.             echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("cart-update");
  92.             echo "\">
  93. \t            \t<div class=\"col-xs-12 button-bar top\">
  94. \t            \t\t<p class=\"product-count\"><b>";
  95.             // line 22
  96.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("cart.downloadlist"), "html"nulltrue);
  97.             echo ": ";
  98.             echo twig_escape_filter($this->envtwig_length_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->source, (isset($context["cart"]) || array_key_exists("cart"$context) ? $context["cart"] : (function () { throw new RuntimeError('Variable "cart" does not exist.'22$this->source); })()), "getItems", [], "method"falsefalsetrue22), 22$this->source)), "html"nulltrue);
  99.             echo "</b></p>
  100. \t            \t\t<div class=\"pull-right\">
  101. \t\t            \t\t<a href=\"/";
  102.             // line 24
  103.             echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed((isset($context["locale"]) || array_key_exists("locale"$context) ? $context["locale"] : (function () { throw new RuntimeError('Variable "locale" does not exist.'24$this->source); })()), 24$this->source), "html"nulltrue);
  104.             echo "/product/\" type=\"button\" class=\"btn secondary\">
  105. \t\t                        ";
  106.             // line 25
  107.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("general.continue-shopping"), "html"nulltrue);
  108.             echo "
  109. \t\t                    </a>
  110. \t\t                    <a id=\"js-checkout-button\" href=\"";
  111.             // line 27
  112.             echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("checkout");
  113.             echo "\" class=\"btn primary\">
  114. \t\t                        ";
  115.             // line 28
  116.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("cart.checkoutnow"), "html"nulltrue);
  117.             echo " <span class=\"glyphicon glyphicon-play\"></span>
  118. \t\t                    </a>
  119. \t\t                </div>
  120. \t\t                <div class=\"clearfix\"></div>
  121. \t            \t</div>
  122. \t                <div class=\"col-sm-12 section-wrap\">
  123. \t                \t<div class=\"row is-table-row\">
  124. \t\t                    ";
  125.             // line 35
  126.             $context['_parent'] = $context;
  127.             $context['_seq'] = twig_ensure_traversable(twig_get_attribute($this->env$this->source, (isset($context["cart"]) || array_key_exists("cart"$context) ? $context["cart"] : (function () { throw new RuntimeError('Variable "cart" does not exist.'35$this->source); })()), "getItems", [], "method"falsefalsetrue35));
  128.             foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
  129.                 // line 36
  130.                 echo "\t\t                        
  131. \t\t                            ";
  132.                 // line 37
  133.                 $context["linkDetail"] = twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["item"], "getProduct", [], "method"falsefalsetrue37), "getDetailUrl", [], "method"falsefalsetrue37);
  134.                 // line 38
  135.                 echo "\t\t                        
  136. \t\t                            <div class=\"col-xs-6 col-sm-3 col-md-2 product-wrap\">
  137. \t\t                            \t<div class=\"product\">
  138. \t\t\t                            \t<div class=\"inside\">
  139. \t\t\t\t                                <a href=\"";
  140.                 // line 42
  141.                 echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed((isset($context["linkDetail"]) || array_key_exists("linkDetail"$context) ? $context["linkDetail"] : (function () { throw new RuntimeError('Variable "linkDetail" does not exist.'42$this->source); })()), 42$this->source), "html"nulltrue);
  142.                 echo "\">
  143. \t\t\t\t                                \t<div class=\"product-image\">
  144. \t\t\t\t\t\t\t\t\t\t\t\t\t\t<img src=\"";
  145.                 // line 44
  146.                 echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["item"], "getProduct", [], "method"falsefalsetrue44), "getFirstImage", ["downloadList", (isset($context["country"]) || array_key_exists("country"$context) ? $context["country"] : (function () { throw new RuntimeError('Variable "country" does not exist.'44$this->source); })())], "method"falsefalsetrue44), 44$this->source), "html"nulltrue);
  147.                 echo "\">
  148. \t\t\t\t                                    </div>
  149. \t\t\t\t                                    <div class=\"product-details\">
  150. \t\t\t\t\t                                    <h4 class=\"media-heading\"><a href=\"";
  151.                 // line 47
  152.                 echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed((isset($context["linkDetail"]) || array_key_exists("linkDetail"$context) ? $context["linkDetail"] : (function () { throw new RuntimeError('Variable "linkDetail" does not exist.'47$this->source); })()), 47$this->source), "html"nulltrue);
  153.                 echo "\">";
  154.                 echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env$this->sourcetwig_get_attribute($this->env$this->source$context["item"], "getProduct", [], "method"falsefalsetrue47), "getOSName", [], "method"falsefalsetrue47), 47$this->source), "html"nulltrue);
  155.                 echo "</a></h4>
  156. \t\t\t\t\t                                </div>
  157. \t\t\t\t                                </a>
  158. \t\t\t\t                                <a class=\"btn close-button\" href=\"";
  159.                 // line 50
  160.                 echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("shop-remove-from-cart", ["item" => twig_get_attribute($this->env$this->source$context["item"], "getItemKey", [], "method"falsefalsetrue50)]), "html"nulltrue);
  161.                 echo "\">
  162. \t\t\t\t                                    <span>&#x2573;</span>
  163. \t\t\t\t                                </a>
  164. \t\t\t\t                            </div>
  165. \t\t\t                            </div>
  166. \t\t                            </div>
  167. \t\t                    \t";
  168.             }
  169.             $_parent $context['_parent'];
  170.             unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
  171.             $context array_intersect_key($context$_parent) + $_parent;
  172.             // line 57
  173.             echo "\t                    </div>
  174. \t                </div>
  175. \t                <div class=\"col-sm-12 button-bar bottom\">
  176. \t            \t\t<div class=\"pull-right\">
  177. \t\t            \t\t<a href=\"/";
  178.             // line 61
  179.             echo twig_escape_filter($this->env$this->sandbox->ensureToStringAllowed((isset($context["locale"]) || array_key_exists("locale"$context) ? $context["locale"] : (function () { throw new RuntimeError('Variable "locale" does not exist.'61$this->source); })()), 61$this->source), "html"nulltrue);
  180.             echo "/product/\" type=\"button\" class=\"btn secondary\">
  181. \t\t                        ";
  182.             // line 62
  183.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("general.continue-shopping"), "html"nulltrue);
  184.             echo "
  185. \t\t                    </a>
  186. \t\t                    <a id=\"js-checkout-button\" href=\"";
  187.             // line 64
  188.             echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("checkout");
  189.             echo "\" class=\"btn primary\">
  190. \t\t                        ";
  191.             // line 65
  192.             echo twig_escape_filter($this->env$this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("cart.checkoutnow"), "html"nulltrue);
  193.             echo " <span class=\"glyphicon glyphicon-play\"></span>
  194. \t\t                    </a>
  195. \t\t                </div>
  196. \t\t                <div class=\"clearfix\"></div>
  197. \t            \t</div>
  198. \t            </form>
  199. \t        ";
  200.         }
  201.         // line 73
  202.         echo "\t    </div>
  203.     </div>
  204. </div>
  205.     <script>
  206.         \$(document).ready(function(){
  207.             \$('.js-quantity').on('change', function() {
  208.                 \$('#js-update-button').removeClass('hidden');
  209.                 \$('#js-checkout-button').hide();
  210.             });
  211.         });
  212.     </script>
  213. ";
  214.         
  215.         $__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
  216.         
  217.         $__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
  218.     }
  219.     /**
  220.      * @codeCoverageIgnore
  221.      */
  222.     public function getTemplateName()
  223.     {
  224.         return "Cart/list.html.twig";
  225.     }
  226.     /**
  227.      * @codeCoverageIgnore
  228.      */
  229.     public function isTraitable()
  230.     {
  231.         return false;
  232.     }
  233.     /**
  234.      * @codeCoverageIgnore
  235.      */
  236.     public function getDebugInfo()
  237.     {
  238.         return array (  218 => 73,  207 => 65,  203 => 64,  198 => 62,  194 => 61,  188 => 57,  175 => 50,  167 => 47,  161 => 44,  156 => 42,  150 => 38,  148 => 37,  145 => 36,  141 => 35,  131 => 28,  127 => 27,  122 => 25,  118 => 24,  111 => 22,  105 => 20,  99 => 18,  97 => 17,  92 => 15,  82 => 8,  76 => 7,  70 => 3,  60 => 2,  37 => 1,);
  239.     }
  240.     public function getSourceContext()
  241.     {
  242.         return new Source("{% extends 'cart.html.twig' %}
  243. {% block content %}
  244. <div class=\"breadcrumb-block\">
  245.     <div class=\"container\">
  246.       <!-- breadcrumb of the page -->
  247.       <ul class=\"breadcrumb\">
  248.         <li><a href=\"/{{ locale }}/\" class=\"home\">{{ 'espirits.header.home'|trans }}</a></li>
  249.         <li>{{ 'espirits.delivery.product-file-list'|trans }}</li>
  250.       </ul>
  251.     </div>
  252. </div>
  253. <div class=\"row container\">
  254.     <div class=\"col-xs-12\">\t
  255.     \t<div class=\"row\">
  256. \t        <h1 class=\"page-heading-title\">{{ 'espirits.delivery.product-file-list'|trans }}</h1>
  257. \t        {% if cart.getItems()|length == 0 %}
  258. \t            {{ 'cart.empty'|trans }}
  259. \t        {% else %}
  260. \t            <form method=\"post\" action=\"{{ path('cart-update') }}\">
  261. \t            \t<div class=\"col-xs-12 button-bar top\">
  262. \t            \t\t<p class=\"product-count\"><b>{{ 'cart.downloadlist'|trans }}: {{ cart.getItems()|length }}</b></p>
  263. \t            \t\t<div class=\"pull-right\">
  264. \t\t            \t\t<a href=\"/{{ locale }}/product/\" type=\"button\" class=\"btn secondary\">
  265. \t\t                        {{ 'general.continue-shopping'|trans }}
  266. \t\t                    </a>
  267. \t\t                    <a id=\"js-checkout-button\" href=\"{{ path('checkout') }}\" class=\"btn primary\">
  268. \t\t                        {{ 'cart.checkoutnow'|trans }} <span class=\"glyphicon glyphicon-play\"></span>
  269. \t\t                    </a>
  270. \t\t                </div>
  271. \t\t                <div class=\"clearfix\"></div>
  272. \t            \t</div>
  273. \t                <div class=\"col-sm-12 section-wrap\">
  274. \t                \t<div class=\"row is-table-row\">
  275. \t\t                    {% for item in cart.getItems() %}
  276. \t\t                        
  277. \t\t                            {% set linkDetail = item.getProduct().getDetailUrl() %}
  278. \t\t                        
  279. \t\t                            <div class=\"col-xs-6 col-sm-3 col-md-2 product-wrap\">
  280. \t\t                            \t<div class=\"product\">
  281. \t\t\t                            \t<div class=\"inside\">
  282. \t\t\t\t                                <a href=\"{{ linkDetail }}\">
  283. \t\t\t\t                                \t<div class=\"product-image\">
  284. \t\t\t\t\t\t\t\t\t\t\t\t\t\t<img src=\"{{ item.getProduct().getFirstImage('downloadList', country) }}\">
  285. \t\t\t\t                                    </div>
  286. \t\t\t\t                                    <div class=\"product-details\">
  287. \t\t\t\t\t                                    <h4 class=\"media-heading\"><a href=\"{{ linkDetail }}\">{{ item.getProduct().getOSName() }}</a></h4>
  288. \t\t\t\t\t                                </div>
  289. \t\t\t\t                                </a>
  290. \t\t\t\t                                <a class=\"btn close-button\" href=\"{{ path('shop-remove-from-cart',{'item': item.getItemKey()}) }}\">
  291. \t\t\t\t                                    <span>&#x2573;</span>
  292. \t\t\t\t                                </a>
  293. \t\t\t\t                            </div>
  294. \t\t\t                            </div>
  295. \t\t                            </div>
  296. \t\t                    \t{% endfor %}
  297. \t                    </div>
  298. \t                </div>
  299. \t                <div class=\"col-sm-12 button-bar bottom\">
  300. \t            \t\t<div class=\"pull-right\">
  301. \t\t            \t\t<a href=\"/{{ locale }}/product/\" type=\"button\" class=\"btn secondary\">
  302. \t\t                        {{ 'general.continue-shopping'|trans }}
  303. \t\t                    </a>
  304. \t\t                    <a id=\"js-checkout-button\" href=\"{{ path('checkout') }}\" class=\"btn primary\">
  305. \t\t                        {{ 'cart.checkoutnow'|trans }} <span class=\"glyphicon glyphicon-play\"></span>
  306. \t\t                    </a>
  307. \t\t                </div>
  308. \t\t                <div class=\"clearfix\"></div>
  309. \t            \t</div>
  310. \t            </form>
  311. \t        {% endif %}
  312. \t    </div>
  313.     </div>
  314. </div>
  315.     <script>
  316.         \$(document).ready(function(){
  317.             \$('.js-quantity').on('change', function() {
  318.                 \$('#js-update-button').removeClass('hidden');
  319.                 \$('#js-checkout-button').hide();
  320.             });
  321.         });
  322.     </script>
  323. {% endblock %}""Cart/list.html.twig""/var/www/vhosts/centricdxb.com/pim2.centricdxb.com/templates/Cart/list.html.twig");
  324.     }
  325.     
  326.     public function checkSecurity()
  327.     {
  328.         static $tags = array("if" => 17"for" => 35"set" => 37);
  329.         static $filters = array("escape" => 7"trans" => 7"length" => 17);
  330.         static $functions = array("path" => 20);
  331.         try {
  332.             $this->sandbox->checkSecurity(
  333.                 ['if''for''set'],
  334.                 ['escape''trans''length'],
  335.                 ['path']
  336.             );
  337.         } catch (SecurityError $e) {
  338.             $e->setSourceContext($this->source);
  339.             if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
  340.                 $e->setTemplateLine($tags[$e->getTagName()]);
  341.             } elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
  342.                 $e->setTemplateLine($filters[$e->getFilterName()]);
  343.             } elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
  344.                 $e->setTemplateLine($functions[$e->getFunctionName()]);
  345.             }
  346.             throw $e;
  347.         }
  348.     }
  349. }