@if (session('cart'))
@foreach (session('cart') as $cart)
Product Image
{{ $cart['title'] }}

{{ $cart['description'] }}

@if ($cart['discount'] != null && strtotime(date('Y-m-d')) < strtotime($cart['dateDiscountEnd']))
Rp. {{ number_format($cart['price_other'], 0, ',', '.') }}
Rp. {{ number_format($cart['price'], 0, ',', '.') }} Diskon {{ $cart['discount'] }}%
@else

Rp.{{ number_format($cart['price_other'], 0, ',', '.') }}

@endif
@endforeach
Summary

Subtotal Rp. {{ number_format(array_sum(array_column(session('cart', []), 'price_other')), 0, ',', '.') }}
Tax Rp. 500
Total Rp. {{ number_format(array_sum(array_column(session('cart', []), 'price_other')) + 500, 0, ',', '.') }}

@else

Tidak Ada Product!

@endif