@extends('layouts.app') @section('title') Checkout @endsection @section('css') @endsection @section('content')

Checkout

@if ($cart->items->count() == 0)

There are nothing in your shopping bag to checkout.

@else

Please ensure all the details are accurate and correct.

@endif
@if ($cart->items->count() > 0)
@foreach ($cart->items as $item) @php $variation = $item->productVariation; $product = $variation->product; @endphp @endforeach
Item Price Quantity Total
@if ($product->images->count()) {{ $product->name }} @endif
{{ str_limit($product->name, 15, '...') }} Variation: {{ $variation->title }} @if ($variation->stock == 0) Out of stock

@elseif ($variation->stock < $item->quantity) Insufficient stock ({{ $variation->stock }} remaining)

@elseif ($product->deleted_at or $variation->deleted_at) Unavailable

@endif
{{ $product->unit_price }} Points {{ $item->quantity }} {{ $item->price }} Points
Order Summary
  • My Point {{ auth()->user()->point }}
  • Total {{ $total }} Points
@endif
@endsection @section('js') @endsection