diff --git a/browser/templates/_types/cart/_cart.html b/browser/templates/_types/cart/_cart.html deleted file mode 100644 index a89fe0f..0000000 --- a/browser/templates/_types/cart/_cart.html +++ /dev/null @@ -1,159 +0,0 @@ -{% macro show_cart(oob=False) %} -
- {# Empty cart #} - {% if not cart and not calendar_cart_entries %} -
-
- -
-

- Your cart is empty -

- {# -

- Add some items from the shop to see them here. -

- #} -
- - {% else %} - -
- {# Items list #} -
- {% for item in cart %} - {% from '_types/product/_cart.html' import cart_item with context %} - {{ cart_item()}} - {% endfor %} - {% if calendar_cart_entries %} -
-

- Calendar bookings -

- -
    - {% for entry in calendar_cart_entries %} -
  • -
    -
    - {{ entry.name or entry.calendar_name }} -
    -
    - {{ entry.start_at }} - {% if entry.end_at %} - – {{ entry.end_at }} - {% endif %} -
    -
    -
    - £{{ "%.2f"|format(entry.cost or 0) }} -
    -
  • - {% endfor %} -
-
- {% endif %} -
- {{summary(cart, total, calendar_total, calendar_cart_entries,)}} - -
- - {% endif %} -
-{% endmacro %} - - -{% macro summary(cart, total, calendar_total, calendar_cart_entries, oob=False) %} - -{% endmacro %} - -{% macro cart_total(cart, total) %} - {% set cart_total = total(cart) %} - {% if cart_total %} - {% set symbol = "£" if cart[0].product.regular_price_currency == "GBP" else cart[0].product.regular_price_currency %} - {{ symbol }}{{ "%.2f"|format(cart_total) }} - {% else %} - – - {% endif %} -{% endmacro %} - - -{% macro cart_grand_total(cart, total, calendar_total, calendar_cart_entries) %} - {% set product_total = total(cart) or 0 %} - {% set cal_total = calendar_total(calendar_cart_entries) or 0 %} - {% set grand = product_total + cal_total %} - - {% if cart and cart[0].product.regular_price_currency %} - {% set symbol = "£" if cart[0].product.regular_price_currency == "GBP" else cart[0].product.regular_price_currency %} - {% else %} - {% set symbol = "£" %} - {% endif %} - - {{ symbol }}{{ "%.2f"|format(grand) }} -{% endmacro %} \ No newline at end of file