Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Rename variable
Mira Szewczyk447a81ac404d
diff --git a/saleor/cart/utils.py b/saleor/cart/utils.pyindex b85591ed21..95f563c56e 100644--- a/saleor/cart/utils.py+++ b/saleor/cart/utils.py@@ -220,21 +220,21 @@ def get_cart_data(cart, shipping_range, currency, discounts):cart_total = Nonelocal_cart_total = Noneshipping_required = False- total_with_shipment = None- local_total_with_shipment = None+ total_with_shipping = None+ local_total_with_shipping = Noneif cart:cart_total = cart.get_total(discounts=discounts)local_cart_total = to_local_currency(cart_total, currency)shipping_required = cart.is_shipping_required()- total_with_shipment = PriceRange(cart_total)+ total_with_shipping = PriceRange(cart_total)if shipping_required and shipping_range:- total_with_shipment = shipping_range + cart_total- local_total_with_shipment = to_local_currency(- total_with_shipment, currency)+ total_with_shipping = shipping_range + cart_total+ local_total_with_shipping = to_local_currency(+ total_with_shipping, currency)return {'cart_total': cart_total,'local_cart_total': local_cart_total,'shipping_required': shipping_required,- 'total_with_shipment': total_with_shipment,- 'local_total_with_shipment': local_total_with_shipment}+ 'total_with_shipping': total_with_shipping,+ 'local_total_with_shipping': local_total_with_shipping}diff --git a/templates/cart/_subtotal_table.html b/templates/cart/_subtotal_table.htmlindex 4608a18e63..fd6ba45cae 100644--- a/templates/cart/_subtotal_table.html+++ b/templates/cart/_subtotal_table.html@@ -53,12 +53,12 @@</div><div class="col-4">{% spaceless %}- <h3 class="text-right cart-total"><span>{% price_range total_with_shipment %}</span>- {% if local_total_with_shipment %}+ <h3 class="text-right cart-total"><span>{% price_range total_with_shipping %}</span>+ {% if local_total_with_shipping %}<br><small>≈- {% price_range local_total_with_shipment %}+ {% price_range local_total_with_shipping %}</small>{% endif %}</h3>