@extends('layouts.app') @section('title', 'Abandoned Checkout Details') @section('content')
← Back to Abandoned Checkouts

Abandoned Checkout Details

ID: #{{ $abandonment->id }} • {{ $abandonment->created_at->format('M d, Y h:i A') }}

@if($abandonment->recovered) ✓ Recovered @else Not Recovered @endif

Customer Information

{{ $abandonment->customer_name ?: 'N/A' }}

{{ $abandonment->customer_email ?: 'N/A' }}

{{ $abandonment->customer_phone ?: 'N/A' }}

@if($abandonment->marketing_consent) ✓ Yes @else ✗ No @endif

@if($abandonment->customer_address)

{{ $abandonment->customer_address }}
@if($abandonment->customer_city) {{ $abandonment->customer_city }}, {{ $abandonment->customer_state }} {{ $abandonment->customer_postcode }} @endif

@endif

Cart Items

@if(is_array($abandonment->items) && count($abandonment->items) > 0)
@foreach($abandonment->items as $item)

{{ $item['name'] ?? 'Product' }}

Quantity: {{ $item['quantity'] ?? 1 }}

RM {{ number_format($item['price'] ?? 0, 2) }}

@endforeach
Total RM {{ number_format($abandonment->total_amount, 2) }}
@else

No cart items recorded

@endif

Activity Timeline

@if($abandonment->events->count() > 0)
@foreach($abandonment->events as $event)
{{ $event->getEventIcon() }}

{{ $event->getEventLabel() }}

{{ $event->created_at->format('M d, Y h:i A') }}

@if($event->event_data)

{{ json_encode($event->event_data) }}

@endif
@endforeach
@else

No events recorded

@endif

Abandonment Details

{{ $abandonment->getStageLabel() }}

@if($abandonment->abandonment_reason)

{{ ucfirst($abandonment->abandonment_reason) }}

@endif

{{ $abandonment->days_since_abandonment }} days ago

{{ $abandonment->hours_since_abandonment }} hours

{{ $abandonment->last_activity_at->format('M d, Y h:i A') }}

@if($abandonment->salesPage)

{{ $abandonment->salesPage->title }}

@endif
@if($abandonment->utm_source || $abandonment->utm_medium || $abandonment->utm_campaign)

Marketing Source

@if($abandonment->utm_source)

{{ $abandonment->utm_source }}

@endif @if($abandonment->utm_medium)

{{ $abandonment->utm_medium }}

@endif @if($abandonment->utm_campaign)

{{ $abandonment->utm_campaign }}

@endif
@endif

Follow-up Status

@if($abandonment->follow_up_sent)

✓ Follow-up sent

Method: {{ ucfirst($abandonment->follow_up_method) }}
Sent: {{ $abandonment->follow_up_sent_at->format('M d, Y h:i A') }}

@else

No follow-up sent yet

@endif
@if($abandonment->recovered)

Recovery Info

Recovered: {{ $abandonment->recovered_at->format('M d, Y h:i A') }}

@if($abandonment->recoveredOrder)

Order: {{ $abandonment->recoveredOrder->order_number }}

@endif
@endif

Actions

@if(!$abandonment->recovered && $abandonment->customer_phone) Send WhatsApp @endif @if(!$abandonment->recovered && $abandonment->customer_email) Send Email @endif @if(!$abandonment->recovered) @endif

Technical Details

{{ $abandonment->session_id }}

@if($abandonment->ip_address)

{{ $abandonment->ip_address }}

@endif @if($abandonment->user_agent)

{{ Str::limit($abandonment->user_agent, 50) }}

@endif
@endsection