templates/Cart/list.html.twig line 1

Open in your IDE?
  1. {% extends 'cart.html.twig' %}
  2. {% block content %}
  3. <div class="breadcrumb-block">
  4.     <div class="container">
  5.       <!-- breadcrumb of the page -->
  6.       <ul class="breadcrumb">
  7.         <li><a href="/{{ locale }}/" class="home">{{ 'espirits.header.home'|trans }}</a></li>
  8.         <li>{{ 'espirits.delivery.product-file-list'|trans }}</li>
  9.       </ul>
  10.     </div>
  11. </div>
  12. <div class="row container">
  13.     <div class="col-xs-12">    
  14.         <div class="row">
  15.             <h1 class="page-heading-title">{{ 'espirits.delivery.product-file-list'|trans }}</h1>
  16.             {% if cart.getItems()|length == 0 %}
  17.                 {{ 'cart.empty'|trans }}
  18.             {% else %}
  19.                 <form method="post" action="{{ path('cart-update') }}">
  20.                     <div class="col-xs-12 button-bar top">
  21.                         <p class="product-count"><b>{{ 'cart.downloadlist'|trans }}: {{ cart.getItems()|length }}</b></p>
  22.                         <div class="pull-right">
  23.                             <a href="/{{ locale }}/product/" type="button" class="btn secondary">
  24.                                 {{ 'general.continue-shopping'|trans }}
  25.                             </a>
  26.                             <a id="js-checkout-button" href="{{ path('checkout') }}" class="btn primary">
  27.                                 {{ 'cart.checkoutnow'|trans }} <span class="glyphicon glyphicon-play"></span>
  28.                             </a>
  29.                         </div>
  30.                         <div class="clearfix"></div>
  31.                     </div>
  32.                     <div class="col-sm-12 section-wrap">
  33.                         <div class="row is-table-row">
  34.                             {% for item in cart.getItems() %}
  35.                                 
  36.                                     {% set linkDetail = item.getProduct().getDetailUrl() %}
  37.                                 
  38.                                     <div class="col-xs-6 col-sm-3 col-md-2 product-wrap">
  39.                                         <div class="product">
  40.                                             <div class="inside">
  41.                                                 <a href="{{ linkDetail }}">
  42.                                                     <div class="product-image">
  43.                                                         <img src="{{ item.getProduct().getFirstImage('downloadList', country) }}">
  44.                                                     </div>
  45.                                                     <div class="product-details">
  46.                                                         <h4 class="media-heading"><a href="{{ linkDetail }}">{{ item.getProduct().getOSName() }}</a></h4>
  47.                                                     </div>
  48.                                                 </a>
  49.                                                 <a class="btn close-button" href="{{ path('shop-remove-from-cart',{'item': item.getItemKey()}) }}">
  50.                                                     <span>&#x2573;</span>
  51.                                                 </a>
  52.                                             </div>
  53.                                         </div>
  54.                                     </div>
  55.                                 {% endfor %}
  56.                         </div>
  57.                     </div>
  58.                     <div class="col-sm-12 button-bar bottom">
  59.                         <div class="pull-right">
  60.                             <a href="/{{ locale }}/product/" type="button" class="btn secondary">
  61.                                 {{ 'general.continue-shopping'|trans }}
  62.                             </a>
  63.                             <a id="js-checkout-button" href="{{ path('checkout') }}" class="btn primary">
  64.                                 {{ 'cart.checkoutnow'|trans }} <span class="glyphicon glyphicon-play"></span>
  65.                             </a>
  66.                         </div>
  67.                         <div class="clearfix"></div>
  68.                     </div>
  69.                 </form>
  70.             {% endif %}
  71.         </div>
  72.     </div>
  73. </div>
  74.     <script>
  75.         $(document).ready(function(){
  76.             $('.js-quantity').on('change', function() {
  77.                 $('#js-update-button').removeClass('hidden');
  78.                 $('#js-checkout-button').hide();
  79.             });
  80.         });
  81.     </script>
  82. {% endblock %}