@extends('front.main') @push('style') @endpush @section('content')

Checkout Form

@csrf

Billing address


Please enter your shipping address.
Please provide a valid state.
Please provide a valid state.
Please select a valid country.
Zip code required.

Order Summary

    @php $totalAmount = 0; // Initialize total amount @endphp @foreach ($cartItems as $item) @php // Check if productsItem and productsDetailsItem are not null $productItem = $item->productsItem ?? null; $productDetailsItem = $item->productsDetailsItem ?? null; // Calculate the product's total price $itemTotal = ($productDetailsItem && $productItem) ? $item->quantity * $productDetailsItem->price : 0; // Add to total amount $totalAmount += $itemTotal; @endphp
  • {{ $item->productsItem->name }}
    (X{{ $item->quantity }})
    ${{ number_format($totalAmount) }}
  • @endforeach

{{--

Payment




Expiration date required
Security code required
--}}
{{--

Checkout

@csrf

Billing Information

@error('first_name')
{{ $message }}
@enderror @error('last_name')
{{ $message }}
@enderror @error('email')
{{ $message }}
@enderror @error('phone')
{{ $message }}
@enderror @error('address')
{{ $message }}
@enderror @error('city')
{{ $message }}
@enderror @error('state')
{{ $message }}
@enderror @error('zip_code')
{{ $message }}
@enderror @error('country')
{{ $message }}
@enderror

Payment Information

Order Summary

@php $totalAmount = 0; // Initialize total amount @endphp @foreach ($cartItems as $item) @php // Check if productsItem and productsDetailsItem are not null $productItem = $item->productsItem ?? null; $productDetailsItem = $item->productsDetailsItem ?? null; // Calculate the product's total price $itemTotal = ($productDetailsItem && $productItem) ? $item->quantity * $productDetailsItem->price : 0; // Add to total amount $totalAmount += $itemTotal; @endphp
{{ $item->productsItem->name }}({{ $item->quantity }}): ${{ number_format($item->quantity * $item->productsDetailsItem->price ) }}
@endforeach
Total: ${{ number_format($totalAmount) }} @error('total')
{{ $message }}
@enderror
--}} @endsection @push('script') @endpush