templates/course/cart.html.twig line 1

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% block body %}
  3.     
  4.                             
  5.         {% embed "nav.html.twig" %}{% endembed %}
  6.         
  7.                         <!-- Page Header Start -->
  8.                         <div class="page-header">
  9.                             <div class="container">
  10.                                 <div class="row">
  11.                                     <div class="col-12">
  12.                                         <h2>Warenkorb</h2>
  13.                                     </div>
  14.                                     
  15.                                 </div>
  16.                             </div>
  17.                         </div>
  18.                         <!-- Page Header End -->
  19.                 
  20.     <div class="content" style="text-align:center; padding-top: 3em;"  >
  21.         <div class="contact">
  22.             <div class="container">
  23.                     <div class="col-12 wow fadeInUp" data-wow-delay="0.1s">
  24.                         <div class="contact-form">
  25.                         {% if data %} 
  26.                         <div class="content" >
  27.                         {% if showSibling == true %}
  28.                             <span>Geschwisterrabatt verwenden</span> &nbsp; <input type="checkbox" class="form-check-input" id="siblingDiscount2" name="siblingDiscount2" onchange="loadCartSiblingDiscount('{{ url }}')" {% if sib == '1' %}checked{% endif %}><br>
  29.                             <label for="siblingDiscount2" class="form-check-label">Achtung! Sollte sich herausstellen, dass die angegebenen Personen keine Geschwister sind, wird die Geb&uuml;hr nachgefordert</label>
  30.                             <br>
  31.                         {% endif %}
  32.                         {% if showStudio == true %}
  33.                             <span><label for="studioDiscount">Ich bin Studiomitglied</label>&nbsp;&nbsp;&nbsp;<input type="checkbox"  id="studioDiscount" name="studioDiscount" style="height: 15px" onchange="loadCartStudioDiscount('{{ url }}')" {% if studio == '1' %}checked{% endif %} ></span> 
  34.                             <br>
  35.                             <label for="studioDiscount">Achtung! Sollte sich herausstellen, dass Sie kein Studiomitglied sind, wird die Geb&uuml;hr nachgefordert</label><br>
  36.                             <br>
  37.                         {% endif %}
  38.                         {% if company == 'KVO' %}
  39.                             <table width="100%" >
  40.                             <tr >
  41.                                 <th>&nbsp;</th>
  42.                                 <th>&nbsp;</th>
  43.                                 <th >Kurs</th>
  44.                                 <th >Datum</th>
  45.                                 <th >Zeitraum</th>
  46.                                 <th >Menge / Personen</th>
  47.                                 <th >Preis</th>
  48.                             </tr>
  49.                             
  50.                             {% for elem in data %}
  51.                             
  52.                                 <tr>
  53.                                     <td>
  54.                                         <a href="javascript:removeItem({{ elem.i }}, '{{ url }}')">
  55.                                         <svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" fill="red" class="bi bi-x" viewBox="0 0 16 16">
  56.                                         <path d="M4.646 4.646a.5.5 0 0 1 .708 0L8 7.293l2.646-2.647a.5.5 0 0 1 .708.708L8.707 8l2.647 2.646a.5.5 0 0 1-.708.708L8 8.707l-2.646 2.647a.5.5 0 0 1-.708-.708L7.293 8 4.646 5.354a.5.5 0 0 1 0-.708z"/>
  57.                                         </svg>
  58.                                         </a>
  59.                                     </td>
  60.                                     <td><img src="{{ url ~ elem.image }}" style="max-width: 100%; height: auto; max-height:100px" /></td>
  61.                                     {% if elem.itemMode == '1' %}
  62.                                     <td>{{ elem.course }}</td>
  63.                                     <td>{{ elem.date|raw }}</td>
  64.                                     <td>{{ elem.time }}</td>
  65.                                     <td>{{ elem.courseAmount }}</td>
  66.                                     <td>{{ elem.coursePrice }}</td>
  67.                                     {% endif %}
  68.                                     
  69.                                     {% if elem.itemMode == '2' %}
  70.                                     <td>{{ elem.article }}</td>
  71.                                     <td>&nbsp;</td>
  72.                                     <td>&nbsp;</td>
  73.                                     <td>{{ elem.articleAmount }}</td>
  74.                                     <td>{{ elem.articlePrice }}</td>
  75.                                     {% endif %}
  76.                                     
  77.                                 </tr>
  78.                             {% else %}
  79.                             
  80.                             {% endfor %}
  81.                             
  82.                             </table>
  83.                         {% else %}
  84.                             <table width="100%">
  85.                             <tr >
  86.                                 <th>&nbsp;</th>
  87.                                 <th >Person</th>
  88.                                 <th >Kurs</th>
  89.                                 <th >Datum</th>
  90.                                 <th >Zeitraum</th>
  91.                                 <th >Preis</th>
  92.                             </tr>
  93.                             
  94.                             {% for k,v in data2 %}
  95.                                 {% for elem2 in v %}
  96.                                 
  97.                                 <tr>
  98.                                     <td>
  99.                                     
  100.                                         <a href="javascript:removeItem2({{  elem2.i }}, '{{ url }}', '{{ k }}')">
  101.                                         <svg xmlns="http://www.w3.org/2000/svg" width="50" height="50" fill="red" class="bi bi-x" viewBox="0 0 16 16">
  102.                                         <path d="M4.646 4.646a.5.5 0 0 1 .708 0L8 7.293l2.646-2.647a.5.5 0 0 1 .708.708L8.707 8l2.647 2.646a.5.5 0 0 1-.708.708L8 8.707l-2.646 2.647a.5.5 0 0 1-.708-.708L7.293 8 4.646 5.354a.5.5 0 0 1 0-.708z"/>
  103.                                         </svg>
  104.                                         </a>
  105.                                     </td>
  106.                                     {% if elem2.itemMode == '1' %}
  107.                                     <td>{{ k }}</td>
  108.                                     <td>{{ elem2.course }}</td>
  109.                                     <td>{{ elem2.date|raw }}</td>
  110.                                     <td>{{ elem2.time }}</td>
  111.                                     <td>{{ elem2.coursePrice|number_format(2, ',', '.') }} &euro;
  112.                                     {% if elem2.discount != 0 %}
  113.                                         ({{ elem2.discount }}% Rabatt)
  114.                                     {% endif %}
  115.                                     </td>
  116.                                     {% endif %}
  117.                                     
  118.                                     {% if elem2.itemMode == '2' %}
  119.                                     <td>{{ elem2.article }}</td>
  120.                                     <td>&nbsp;</td>
  121.                                     <td>&nbsp;</td>
  122.                                     <td>{{ elem2.articleAmount }}</td>
  123.                                     <td>{{ elem2.articlePrice }}</td>
  124.                                     {% endif %}
  125.                                     
  126.                                 </tr>
  127.                                 {% else %}
  128.                             
  129.                                 {% endfor %}
  130.                             {% endfor %}
  131.                             
  132.                             </table>
  133.                         {% endif %}
  134.                         
  135.                         <table width="100%">
  136.                         <tr {% if company != "KVO" %} style="display:none" {% endif %}>
  137.                                 <td width="85%" align="right">Preis:</td>
  138.                                 <td width="15%">{{fullpricetax }}</td>        
  139.                         </tr>
  140.                         {% for key, tax in taxes %}
  141.                         <tr {% if company != "KVO" %} style="display:none" {% endif %}>
  142.                         <td align="right">+{{ key }}% MwSt.</td>
  143.                         <td>{{ tax }} </td>
  144.                         </tr>
  145.                         {% endfor %}
  146.                         {% if adminFee != 0 %}
  147.                         <tr {% if company != "KVO" %} style="display:none" {% endif %}>
  148.                                 <td width="85%" align="right">enthaltene Verwaltungsgebühren:</td>
  149.                                 <td width="15%">{{ adminFee|number_format(2, ',', '.') }} €</td>        
  150.                         </tr>
  151.                         {% endif %}
  152.                             <tr>
  153.                                     <td width="85%" align="right">Gesamtpreis:</td>
  154.                                     <td width="15%"><u>{{fullprice }}</u></td>        
  155.                             </tr>
  156.                             </table>
  157.                                 <br>
  158.                                 <input type="button" class="btn" value="zur Kasse" onclick="javascript:checkOut('{{url}}');" />&nbsp; 
  159.                                 {% if anonBuy == 1 %}
  160.                                     <!--<input type="button" class="btn" value="Als Gast Bestellen" onclick="javascript:anonCheckout('{{url}}');" />&nbsp;--> 
  161.                                 {% endif %}
  162.                                 <input type="button" class="btn" value="weiter Einkaufen" onclick="javascript:location.href='{{ path('homepage2',{placeid: placeid2}) }}'" /> 
  163.                                 <!--
  164.                                 <input type="button" class="btn btn-success" value="Weiter einkaufen" onclick="javacript:goShopping('{{url}}');" /> 
  165.                                 -->    
  166.                                 
  167.                             </div>
  168.                         {% else %}
  169.                         <div class="content" style="text-align:center; "  >
  170.                         Ihr Warenkorb ist Leer
  171.                         </div>
  172.                         {% endif  %}
  173.                         <input type="hidden" value="{{warning}}" id="warningText" name="warningText"> 
  174.                     </div>
  175.                 </div>
  176.             </div>
  177.         </div>
  178.     </div>
  179.     
  180.  {% block javascripts %}
  181.     {{ parent() }}
  182.     
  183.     <script src="{{ asset('js/cart.js') }}"></script>
  184.     {% endblock %}
  185.         <script>
  186.     openWarning();
  187.     </script>
  188. {% endblock %}