Suspend free shipping for now
This commit is contained in:
parent
087728b827
commit
388556723e
@ -60,7 +60,7 @@ class CartItem:
|
|||||||
|
|
||||||
class Cart:
|
class Cart:
|
||||||
item_class = CartItem
|
item_class = CartItem
|
||||||
site_settings = SiteSettings.load()
|
# site_settings = SiteSettings.load()
|
||||||
|
|
||||||
def __init__(self, request):
|
def __init__(self, request):
|
||||||
self.request = request
|
self.request = request
|
||||||
@ -170,9 +170,9 @@ class Cart:
|
|||||||
return containers
|
return containers
|
||||||
|
|
||||||
def get_shipping_cost(self, container=None):
|
def get_shipping_cost(self, container=None):
|
||||||
free_shipping_min = self.site_settings.free_shipping_min
|
# free_shipping_min = self.site_settings.free_shipping_min
|
||||||
if self.get_total_price() >= free_shipping_min:
|
# if self.get_total_price() >= free_shipping_min:
|
||||||
return Decimal('0.00')
|
# return Decimal('0.00')
|
||||||
|
|
||||||
if container is None:
|
if container is None:
|
||||||
container = self.session.get('shipping_container').container
|
container = self.session.get('shipping_container').container
|
||||||
|
|||||||
@ -21,7 +21,7 @@
|
|||||||
</figure>
|
</figure>
|
||||||
<div class="item__info">
|
<div class="item__info">
|
||||||
<h3>{{product.name}}</h3>
|
<h3>{{product.name}}</h3>
|
||||||
<h4>{{ item.variant.name }}</h4>
|
<h2 class="item__variant">{{ item.variant.name }}</h2>
|
||||||
{% for key, value in item.options.items %}
|
{% for key, value in item.options.items %}
|
||||||
<p><strong>{{ key }}</strong>: {{ value }}</p>
|
<p><strong>{{ key }}</strong>: {{ value }}</p>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
@ -58,7 +58,7 @@
|
|||||||
<input type="submit" value="Apply" class="action-button">
|
<input type="submit" value="Apply" class="action-button">
|
||||||
</p>
|
</p>
|
||||||
</form>
|
</form>
|
||||||
<h5>Free shipping on orders over ${{ site_settings.free_shipping_min|floatformat:"2" }}</h5>
|
<!-- <h5>Free shipping on orders over ${{ site_settings.free_shipping_min|floatformat:"2" }}</h5> -->
|
||||||
<div class="cart__table-wrapper">
|
<div class="cart__table-wrapper">
|
||||||
<table class="cart__totals">
|
<table class="cart__totals">
|
||||||
<tr>
|
<tr>
|
||||||
|
|||||||
@ -79,11 +79,7 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
<tr>
|
<tr>
|
||||||
<td>Shipping</td>
|
<td>Shipping</td>
|
||||||
{% if cart.get_total_price >= site_settings.free_shipping_min %}
|
|
||||||
<td>Free!</td>
|
|
||||||
{% else %}
|
|
||||||
<td>${{ cart.get_shipping_cost }}</td>
|
<td>${{ cart.get_shipping_cost }}</td>
|
||||||
{% endif %}
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<th>Total</th>
|
<th>Total</th>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user