@php $cart = Session::has('cart') ? Session::get('cart') : []; $total = 0; $option_price = 0; $cartTotal = 0; @endphp
@foreach ($cart as $key => $item) @php $cartTotal += ($item['main_price'] + $total + $item['attribute_price']) * $item['qty']; @endphp @endforeach
{{ __('Product Name') }} {{ __('Product Price') }} {{ __('Quantity') }} {{ __('Subtotal') }} {{ __('Clear Cart') }}
Product

{{ Str::limit($item['name'], 45) }}

@foreach ($item['attribute']['option_name'] as $optionkey => $option_name) {{ $item['attribute']['names'][$optionkey] }}: {{ $option_name }} @endforeach
@php $totalAttributePrice = 0; foreach ($item['attribute']['option_price'] as $option_price) { $totalAttributePrice += $option_price; } $price = $item['main_price'] + $totalAttributePrice; @endphp {{ PriceHelper::setCurrencyPrice($price) }} @if ($item['item_type'] == 'normal')
@endif
{{ PriceHelper::setCurrencyPrice($price * $item['qty']) }}