<?php
use Twig\Environment;
use Twig\Error\LoaderError;
use Twig\Error\RuntimeError;
use Twig\Extension\SandboxExtension;
use Twig\Markup;
use Twig\Sandbox\SecurityError;
use Twig\Sandbox\SecurityNotAllowedTagError;
use Twig\Sandbox\SecurityNotAllowedFilterError;
use Twig\Sandbox\SecurityNotAllowedFunctionError;
use Twig\Source;
use Twig\Template;
/* Cart/list.html.twig */
class __TwigTemplate_1f8b5d33146c74944fb328ae6b5468d7 extends Template
{
private $source;
private $macros = [];
public function __construct(Environment $env)
{
parent::__construct($env);
$this->source = $this->getSourceContext();
$this->blocks = [
'content' => [$this, 'block_content'],
];
$this->sandbox = $this->env->getExtension('\Twig\Extension\SandboxExtension');
$this->checkSecurity();
}
protected function doGetParent(array $context)
{
// line 1
return "cart.html.twig";
}
protected function doDisplay(array $context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Cart/list.html.twig"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "template", "Cart/list.html.twig"));
$this->parent = $this->loadTemplate("cart.html.twig", "Cart/list.html.twig", 1);
$this->parent->display($context, array_merge($this->blocks, $blocks));
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
}
// line 2
public function block_content($context, array $blocks = [])
{
$macros = $this->macros;
$__internal_5a27a8ba21ca79b61932376b2fa922d2 = $this->extensions["Symfony\\Bundle\\WebProfilerBundle\\Twig\\WebProfilerExtension"];
$__internal_5a27a8ba21ca79b61932376b2fa922d2->enter($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
$__internal_6f47bbe9983af81f1e7450e9a3e3768f = $this->extensions["Symfony\\Bridge\\Twig\\Extension\\ProfilerExtension"];
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->enter($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof = new \Twig\Profiler\Profile($this->getTemplateName(), "block", "content"));
// line 3
echo "<div class=\"breadcrumb-block\">
<div class=\"container\">
<!-- breadcrumb of the page -->
<ul class=\"breadcrumb\">
<li><a href=\"/";
// line 7
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", null, true);
echo "/\" class=\"home\">";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("espirits.header.home"), "html", null, true);
echo "</a></li>
<li>";
// line 8
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("espirits.delivery.product-file-list"), "html", null, true);
echo "</li>
</ul>
</div>
</div>
<div class=\"row container\">
<div class=\"col-xs-12\">\t
\t<div class=\"row\">
\t <h1 class=\"page-heading-title\">";
// line 15
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("espirits.delivery.product-file-list"), "html", null, true);
echo "</h1>
\t ";
// line 17
if ((twig_length_filter($this->env, 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.', 17, $this->source); })()), "getItems", [], "method", false, false, true, 17)) == 0)) {
// line 18
echo "\t ";
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("cart.empty"), "html", null, true);
echo "
\t ";
} else {
// line 20
echo "\t <form method=\"post\" action=\"";
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("cart-update");
echo "\">
\t \t<div class=\"col-xs-12 button-bar top\">
\t \t\t<p class=\"product-count\"><b>";
// line 22
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("cart.downloadlist"), "html", null, true);
echo ": ";
echo twig_escape_filter($this->env, twig_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", false, false, true, 22), 22, $this->source)), "html", null, true);
echo "</b></p>
\t \t\t<div class=\"pull-right\">
\t\t \t\t<a href=\"/";
// line 24
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", null, true);
echo "/product/\" type=\"button\" class=\"btn secondary\">
\t\t ";
// line 25
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("general.continue-shopping"), "html", null, true);
echo "
\t\t </a>
\t\t <a id=\"js-checkout-button\" href=\"";
// line 27
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("checkout");
echo "\" class=\"btn primary\">
\t\t ";
// line 28
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("cart.checkoutnow"), "html", null, true);
echo " <span class=\"glyphicon glyphicon-play\"></span>
\t\t </a>
\t\t </div>
\t\t <div class=\"clearfix\"></div>
\t \t</div>
\t <div class=\"col-sm-12 section-wrap\">
\t \t<div class=\"row is-table-row\">
\t\t ";
// line 35
$context['_parent'] = $context;
$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", false, false, true, 35));
foreach ($context['_seq'] as $context["_key"] => $context["item"]) {
// line 36
echo "\t\t
\t\t ";
// line 37
$context["linkDetail"] = twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["item"], "getProduct", [], "method", false, false, true, 37), "getDetailUrl", [], "method", false, false, true, 37);
// line 38
echo "\t\t
\t\t <div class=\"col-xs-6 col-sm-3 col-md-2 product-wrap\">
\t\t \t<div class=\"product\">
\t\t\t \t<div class=\"inside\">
\t\t\t\t <a href=\"";
// line 42
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", null, true);
echo "\">
\t\t\t\t \t<div class=\"product-image\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t<img src=\"";
// line 44
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["item"], "getProduct", [], "method", false, false, true, 44), "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", false, false, true, 44), 44, $this->source), "html", null, true);
echo "\">
\t\t\t\t </div>
\t\t\t\t <div class=\"product-details\">
\t\t\t\t\t <h4 class=\"media-heading\"><a href=\"";
// line 47
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", null, true);
echo "\">";
echo twig_escape_filter($this->env, $this->sandbox->ensureToStringAllowed(twig_get_attribute($this->env, $this->source, twig_get_attribute($this->env, $this->source, $context["item"], "getProduct", [], "method", false, false, true, 47), "getOSName", [], "method", false, false, true, 47), 47, $this->source), "html", null, true);
echo "</a></h4>
\t\t\t\t\t </div>
\t\t\t\t </a>
\t\t\t\t <a class=\"btn close-button\" href=\"";
// line 50
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", false, false, true, 50)]), "html", null, true);
echo "\">
\t\t\t\t <span>╳</span>
\t\t\t\t </a>
\t\t\t\t </div>
\t\t\t </div>
\t\t </div>
\t\t \t";
}
$_parent = $context['_parent'];
unset($context['_seq'], $context['_iterated'], $context['_key'], $context['item'], $context['_parent'], $context['loop']);
$context = array_intersect_key($context, $_parent) + $_parent;
// line 57
echo "\t </div>
\t </div>
\t <div class=\"col-sm-12 button-bar bottom\">
\t \t\t<div class=\"pull-right\">
\t\t \t\t<a href=\"/";
// line 61
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", null, true);
echo "/product/\" type=\"button\" class=\"btn secondary\">
\t\t ";
// line 62
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("general.continue-shopping"), "html", null, true);
echo "
\t\t </a>
\t\t <a id=\"js-checkout-button\" href=\"";
// line 64
echo $this->extensions['Symfony\Bridge\Twig\Extension\RoutingExtension']->getPath("checkout");
echo "\" class=\"btn primary\">
\t\t ";
// line 65
echo twig_escape_filter($this->env, $this->extensions['Symfony\Bridge\Twig\Extension\TranslationExtension']->trans("cart.checkoutnow"), "html", null, true);
echo " <span class=\"glyphicon glyphicon-play\"></span>
\t\t </a>
\t\t </div>
\t\t <div class=\"clearfix\"></div>
\t \t</div>
\t </form>
\t ";
}
// line 73
echo "\t </div>
</div>
</div>
<script>
\$(document).ready(function(){
\$('.js-quantity').on('change', function() {
\$('#js-update-button').removeClass('hidden');
\$('#js-checkout-button').hide();
});
});
</script>
";
$__internal_6f47bbe9983af81f1e7450e9a3e3768f->leave($__internal_6f47bbe9983af81f1e7450e9a3e3768f_prof);
$__internal_5a27a8ba21ca79b61932376b2fa922d2->leave($__internal_5a27a8ba21ca79b61932376b2fa922d2_prof);
}
/**
* @codeCoverageIgnore
*/
public function getTemplateName()
{
return "Cart/list.html.twig";
}
/**
* @codeCoverageIgnore
*/
public function isTraitable()
{
return false;
}
/**
* @codeCoverageIgnore
*/
public function getDebugInfo()
{
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,);
}
public function getSourceContext()
{
return new Source("{% extends 'cart.html.twig' %}
{% block content %}
<div class=\"breadcrumb-block\">
<div class=\"container\">
<!-- breadcrumb of the page -->
<ul class=\"breadcrumb\">
<li><a href=\"/{{ locale }}/\" class=\"home\">{{ 'espirits.header.home'|trans }}</a></li>
<li>{{ 'espirits.delivery.product-file-list'|trans }}</li>
</ul>
</div>
</div>
<div class=\"row container\">
<div class=\"col-xs-12\">\t
\t<div class=\"row\">
\t <h1 class=\"page-heading-title\">{{ 'espirits.delivery.product-file-list'|trans }}</h1>
\t {% if cart.getItems()|length == 0 %}
\t {{ 'cart.empty'|trans }}
\t {% else %}
\t <form method=\"post\" action=\"{{ path('cart-update') }}\">
\t \t<div class=\"col-xs-12 button-bar top\">
\t \t\t<p class=\"product-count\"><b>{{ 'cart.downloadlist'|trans }}: {{ cart.getItems()|length }}</b></p>
\t \t\t<div class=\"pull-right\">
\t\t \t\t<a href=\"/{{ locale }}/product/\" type=\"button\" class=\"btn secondary\">
\t\t {{ 'general.continue-shopping'|trans }}
\t\t </a>
\t\t <a id=\"js-checkout-button\" href=\"{{ path('checkout') }}\" class=\"btn primary\">
\t\t {{ 'cart.checkoutnow'|trans }} <span class=\"glyphicon glyphicon-play\"></span>
\t\t </a>
\t\t </div>
\t\t <div class=\"clearfix\"></div>
\t \t</div>
\t <div class=\"col-sm-12 section-wrap\">
\t \t<div class=\"row is-table-row\">
\t\t {% for item in cart.getItems() %}
\t\t
\t\t {% set linkDetail = item.getProduct().getDetailUrl() %}
\t\t
\t\t <div class=\"col-xs-6 col-sm-3 col-md-2 product-wrap\">
\t\t \t<div class=\"product\">
\t\t\t \t<div class=\"inside\">
\t\t\t\t <a href=\"{{ linkDetail }}\">
\t\t\t\t \t<div class=\"product-image\">
\t\t\t\t\t\t\t\t\t\t\t\t\t\t<img src=\"{{ item.getProduct().getFirstImage('downloadList', country) }}\">
\t\t\t\t </div>
\t\t\t\t <div class=\"product-details\">
\t\t\t\t\t <h4 class=\"media-heading\"><a href=\"{{ linkDetail }}\">{{ item.getProduct().getOSName() }}</a></h4>
\t\t\t\t\t </div>
\t\t\t\t </a>
\t\t\t\t <a class=\"btn close-button\" href=\"{{ path('shop-remove-from-cart',{'item': item.getItemKey()}) }}\">
\t\t\t\t <span>╳</span>
\t\t\t\t </a>
\t\t\t\t </div>
\t\t\t </div>
\t\t </div>
\t\t \t{% endfor %}
\t </div>
\t </div>
\t <div class=\"col-sm-12 button-bar bottom\">
\t \t\t<div class=\"pull-right\">
\t\t \t\t<a href=\"/{{ locale }}/product/\" type=\"button\" class=\"btn secondary\">
\t\t {{ 'general.continue-shopping'|trans }}
\t\t </a>
\t\t <a id=\"js-checkout-button\" href=\"{{ path('checkout') }}\" class=\"btn primary\">
\t\t {{ 'cart.checkoutnow'|trans }} <span class=\"glyphicon glyphicon-play\"></span>
\t\t </a>
\t\t </div>
\t\t <div class=\"clearfix\"></div>
\t \t</div>
\t </form>
\t {% endif %}
\t </div>
</div>
</div>
<script>
\$(document).ready(function(){
\$('.js-quantity').on('change', function() {
\$('#js-update-button').removeClass('hidden');
\$('#js-checkout-button').hide();
});
});
</script>
{% endblock %}", "Cart/list.html.twig", "/var/www/vhosts/centricdxb.com/pim2.centricdxb.com/templates/Cart/list.html.twig");
}
public function checkSecurity()
{
static $tags = array("if" => 17, "for" => 35, "set" => 37);
static $filters = array("escape" => 7, "trans" => 7, "length" => 17);
static $functions = array("path" => 20);
try {
$this->sandbox->checkSecurity(
['if', 'for', 'set'],
['escape', 'trans', 'length'],
['path']
);
} catch (SecurityError $e) {
$e->setSourceContext($this->source);
if ($e instanceof SecurityNotAllowedTagError && isset($tags[$e->getTagName()])) {
$e->setTemplateLine($tags[$e->getTagName()]);
} elseif ($e instanceof SecurityNotAllowedFilterError && isset($filters[$e->getFilterName()])) {
$e->setTemplateLine($filters[$e->getFilterName()]);
} elseif ($e instanceof SecurityNotAllowedFunctionError && isset($functions[$e->getFunctionName()])) {
$e->setTemplateLine($functions[$e->getFunctionName()]);
}
throw $e;
}
}
}