add shipping to order, methods to calculate, little refactoring

This commit is contained in:
ludo
2023-11-15 23:20:42 +01:00
parent 04df068931
commit 2ebdc5f16b
10 changed files with 117 additions and 45 deletions

View File

@@ -13,27 +13,32 @@
<span id="basket-count">{{ $basket['quantity'] ?? 0 }}</span> ARTICLES
</div>
<div class="col-6 text-right font-weight-bold">
<span id="basket-total">{{ $basket['total'] ?? 0 }}</span>
<span id="basket-total">
{{ $basket['total_taxed'] ?? 0 }}
</span>
</div>
</div>
<!--
<div class="row mb-3">
<div class="col-6">
LIVRAISON
@if ($basket['shipping'])
<div class="row mb-3">
<div class="col-6">
LIVRAISON
</div>
<div class="col-6 text-right font-weight-bold">
<span id="shipping">
{{ $basket['shipping'] }}
</span>
</div>
</div>
<div class="col-6 text-right font-weight-bold">
<span id="shipping">5</span>
</div>
</div>
<hr>
-->
<hr>
@endif
<div class="row mb-3 font-weight-bold" style="font-size: 1.6em;">
<div class="col-6">
TOTAL TTC
</div>
<div class="col-6 text-right">
<span
id="basket-total-shipped">{{ App\Repositories\Core\User\ShopCart::fixDecimal($basket['total'] ?? 0) }}</span>
<span id="basket-total-shipped">
{{ $basket['total_shipped'] ?? 0 }}
</span>
</div>
</div>