{{-- Page Header --}}

My Purchases

All your acquired digital products in one place.

Browse More
{{-- Filters --}}
{{-- Purchases Table --}}
@if(isset($purchases) && $purchases->count() > 0)
@foreach ($purchases as $item) @endforeach
Product Status Actions
@if($item->plan_id) {{ strtoupper(substr($item->product_title ?? 'SU', 0, 2)) }} @else {{ strtoupper(substr($item->product->title ?? 'PR', 0, 2)) }} @endif

@if($item->plan_id) {{ $item->product_title ?? 'Subscription Plan' }} @else {{ $item->product->title ?? 'Unknown Product' }} @endif

@if($item->plan_id) @php $subscription = \App\Modules\CustomerSubscription\Models\CustomerSubscription::where('user_id', Auth::id()) ->where('plan_id', $item->plan_id) ->latest() ->first(); @endphp

@if($subscription && $subscription->isActive()) Ends: {{ $subscription->ends_at ? $subscription->ends_at->format('M d, Y') : 'Never' }} @else Order #{{ $item->order->ulid ?? 'N/A' }} @endif

@else

Order #{{ $item->order->ulid ?? 'N/A' }}

@endif
@php $displayStatus = 'Active'; $statusColorClass = 'bg-emerald-500/10 text-emerald-400 border-emerald-500/20 shadow-[0_0_10px_rgba(16,185,129,0.1)]'; if($item->plan_id && isset($subscription)) { if ($subscription->status === 'suspended') { $displayStatus = 'Suspended'; $statusColorClass = 'bg-amber-500/10 text-amber-400 border-amber-500/20 shadow-[0_0_10px_rgba(245,158,11,0.1)]'; } elseif ($subscription->status !== 'active') { $displayStatus = ucfirst($subscription->status); $statusColorClass = 'bg-slate-500/10 text-slate-400 border-slate-500/20'; } } @endphp @if($item->order->isPaid()) {{ $displayStatus }} @elseif($item->order->isPending()) Pending @else {{ $item->order->status }} @endif
@if($item->order->isPaid()) @if($item->plan_id) Browse Products @else Download License @endif @else Verification Required @endif
{{-- Pagination --}} @if($purchases->hasPages())

Showing {{ $purchases->firstItem() }}–{{ $purchases->lastItem() }} of {{ $purchases->total() }} purchases

@if($purchases->onFirstPage()) ← Prev @else ← Prev @endif @if($purchases->hasMorePages()) Next → @else Next → @endif
@endif @else

No purchases yet

Discover thousands of premium digital products in our marketplace.

Browse Products
@endif