card drawer show amount for free delivery

main
alexanderroese 2024-06-18 22:34:53 +02:00
parent 4838a6fff9
commit 9279569ad6
1 changed files with 5 additions and 3 deletions

View File

@ -71,9 +71,7 @@
</button>
</div>
<script>
console.log("cart3", {{ cart | json }})
</script>
{% assign free_shipping_threshold = 10 %}
{% assign total_price = cart.total_price %}
@ -81,6 +79,10 @@
<span>price5 {{ total_price | money }} {% render 'shx-shipping-costs' %}</span>
<script>
console.log("cart4", {{ cart | json }}, {{ remaining_amount }})
</script>
{% if total_price < free_shipping_threshold %}
<span>Du bist nur noch {{ remaining_amount | money }} von kostenfreiem Versand entfernt!</span>
{% endif %}