@php use Illuminate\Support\Str; $user = auth()->user(); $activeProfileId = session('active_profile_id'); $resolveMediaUrl = function ($path) { if (empty($path)) { return null; } $path = trim($path); if (Str::startsWith($path, ['http://', 'https://'])) { return $path; } if (Str::startsWith($path, ['uploads/', '/uploads/'])) { return asset(ltrim($path, '/')); } if (Str::startsWith($path, ['storage/', '/storage/'])) { return asset(ltrim($path, '/')); } if (Str::startsWith($path, ['movies/', '/movies/'])) { return asset('storage/' . ltrim($path, '/')); } return asset(ltrim($path, '/')); }; $firstName = $user->name ?? 'Member'; $email = $user->email ?? 'No email'; $avatar = null; if (!empty($user->avatar)) { $avatar = $resolveMediaUrl($user->avatar); } $activePlan = $activePlan ?? null; $continueWatching = collect($continueWatching ?? []); $myListItems = collect($myListItems ?? []); $recentDevices = collect($recentDevices ?? []); $billingHistory = collect($billingHistory ?? []); $profiles = collect($profiles ?? []); $planName = $activePlan->name ?? ($user->plan_name ?? 'Free Plan'); $planStatus = $activePlan->status ?? ($user->subscription_status ?? 'Active'); $planRenewal = $activePlan->renews_at ?? null; $formatDate = function ($date) { if (empty($date)) { return 'Not available'; } try { return \Illuminate\Support\Carbon::parse($date)->format('M d, Y'); } catch (\Throwable $e) { return (string) $date; } }; $fallbackContinue = $continueWatching->isEmpty() ? collect([ (object)[ 'title' => 'Continue Watching', 'slug' => null, 'poster' => null, 'backdrop' => null, 'duration' => null, 'progress_percent' => 42, 'episode_label' => 'Resume anytime', 'description' => 'Track Your in-progress you start playback.', ] ]) : $continueWatching; $fallbackMyList = $myListItems->isEmpty() ? collect([ (object)[ 'title' => 'My List', 'slug' => null, 'poster' => null, 'backdrop' => null, 'duration' => null, 'description' => 'Your saved movies.', ] ]) : $myListItems; @endphp
Member Center

Account

Manage your profile, membership, saved movies, and playback activity from one premium dashboard.

@if($avatar) {{ $firstName }} @else {{ strtoupper(substr($firstName, 0, 1)) }} @endif
{{ $firstName }}
{{ $email }}
{{ $profiles->count() ?: 1 }} Profiles
{{ $continueWatching->count() }} In Progress
{{ $myListItems->count() }} saved movies
{{ $activeProfileId ?: 'N/A' }} Active Profile

Membership

Subscription status, renewal details, and plan overview.

{{ $planStatus }}
Current Plan {{ $planName }}
Renewal Date {{ $formatDate($planRenewal) }}
Email Address {{ $email }}
Account Created {{ $formatDate($user->created_at ?? null) }}

Continue Watching

Jump back into movies you already started.

@foreach($fallbackContinue as $item) @php $itemTitle = $item->title ?? $item->name ?? 'Untitled'; $itemSlug = $item->slug ?? null; $itemPoster = $resolveMediaUrl($item->backdrop ?? $item->poster ?? $item->thumbnail ?? null); $itemUrl = $itemSlug ? route('watch.movie', $itemSlug) : route('browse'); $progress = (int)($item->progress_percent ?? 0); @endphp @endforeach

My List Snapshot

Quick access to movies you have saved.

@foreach($fallbackMyList as $item) @php $itemTitle = $item->title ?? $item->name ?? 'Untitled'; $itemSlug = $item->slug ?? null; $itemPoster = $resolveMediaUrl($item->backdrop ?? $item->poster ?? $item->thumbnail ?? null); $itemUrl = $itemSlug ? route('title.show', $itemSlug) : route('mylist'); @endphp @endforeach

Profiles

Manage viewer profiles and switch active usage.

@if($profiles->count())
@foreach($profiles as $profile)
{{ $profile->name ?? 'Profile' }} @if((int)($profile->id ?? 0) === (int)$activeProfileId) Currently active @else Available profile @endif
@if(!empty($profile->id)) Use @endif
@endforeach
@else
No profiles were passed from the controller yet. Once you send `$profiles`, they will show here automatically.
@endif

Recent Devices

Track sessions and account access points.

@if($recentDevices->count())
@foreach($recentDevices as $device)
{{ $device->name ?? 'Unknown Device' }} {{ $device->location ?? 'Unknown location' }} @if(!empty($device->last_seen)) • Last seen {{ $formatDate($device->last_seen) }} @endif
{{ $device->status ?? 'Active' }}
@endforeach
@else
No recent devices were passed from the controller yet. This section is ready for device history whenever you want it.
@endif

Billing History

Recent subscription or payment activity.

@if($billingHistory->count())
@foreach($billingHistory as $bill)
{{ $bill->label ?? 'Subscription Payment' }} {{ $formatDate($bill->date ?? null) }} @if(!empty($bill->gateway)) • {{ $bill->gateway }} @endif
{{ $bill->amount ?? '' }} {{ strtoupper($bill->status ?? 'pending') }}
@endforeach
@else
No billing history was passed from the controller yet. When you connect transactions here, this section will render automatically.
@endif

Quick Actions

Fast links for common account tasks.