Jane Goldberg

{{ $user->first_name }} {{ $user->last_name }}

Customer since {{ \Carbon\Carbon::parse($user->created_at)->diffForHumans(['parts' => 2, 'join' => ', ']) }}

Phone Icon {{ $user->phone }} {{ $user->email }}
Overview
Beneficiaries
Policies
Details
Claims
Active
Expired

Products

@foreach ($covers as $cover)
@if ($cover->status === 'Active') {{ $cover->cover_type }} Icon @else {{ $cover->cover_type }} Icon @endif
@endforeach
@php // Determine how many claims to show based on the query parameter $initialLimit = 1; // Number of claims to show initially $batchSize = 2; // Number of claims to reveal with each "More" click $totalClaims = $claims->count(); $showCount = request('show') ? intval(request('show')) : $initialLimit; @endphp

Open Claims

Product
Claim Number
Amount
Action
@foreach ($claims->take($showCount) as $claim)
{{ $claim->product_type }} Icon
{{ $claim->claim_number }}
{{ number_format($claim->amount, 2) }}
@endforeach @if($showCount < $totalClaims)
More
@endif @if($showCount > $initialLimit) @endif
@php use Carbon\Carbon; // Calculate the date one week ago $oneWeekAgo = Carbon::now()->subWeek(); // Filter covers created within the past week $latestCovers = $covers->filter(function ($cover) use ($oneWeekAgo) { return $cover->created_at >= $oneWeekAgo; }); // Determine how many policies to show initially and batch size $initialLimit = 1; // Number of policies to show initially $batchSize = 2; // Number of policies to reveal with each "More" click $totalLatestPolicies = $latestCovers->count(); $showLatestPoliciesCount = request('showLatestPolicies') ? intval(request('showLatestPolicies')) : $initialLimit; @endphp

Latest Policies

Product
Policy Number
Premium
Action
@foreach ($latestCovers->take($showLatestPoliciesCount) as $policy)
{{ $policy->cover_type }} Icon
PER/20240908/MzPuGW
{{ number_format($policy->premium, 2) }}
@endforeach @if($showLatestPoliciesCount < $totalLatestPolicies)
More
@endif @if($showLatestPoliciesCount > $initialLimit) @endif

Recent activity

@csrf
@foreach ($notes as $note)
User Icon
{{ $note->user->first_name }} on {{ $note->created_at->format('j F Y') }} at {{ $note->created_at->format('H:i') }}
{{ $note->note }}
@if ($note->file) View Attachment @endif
@endforeach
@php // Filter covers to include only those expiring within the next week $expiringCovers = $covers->filter(function ($cover) { return $cover->expiry_date && Carbon::parse($cover->expiry_date)->isBetween(Carbon::now(), Carbon::now()->addWeek()); }); // Determine how many policies to show initially and batch size $initialLimit = 1; // Number of policies to show initially $batchSize = 2; // Number of policies to reveal with each "More" click $totalExpiringPolicies = $expiringCovers->count(); $showExpiringPoliciesCount = request('showExpiringPolicies') ? intval(request('showExpiringPolicies')) : $initialLimit; @endphp

Expiring Policies

Product
Policy Number
Expiring
Action
@foreach ($expiringCovers->take($showExpiringPoliciesCount) as $policy)
{{ $policy->cover_type }} Icon
{{ $policy->policy_number }}
{{ Carbon::parse($policy->expiry_date)->format('d F Y') }}
@endforeach @if($showExpiringPoliciesCount < $totalExpiringPolicies)
More
@endif @if($showExpiringPoliciesCount > $initialLimit) @endif
@foreach($beneficiaries as $beneficiary) @endforeach
Name Relationship Phone Date added Passport number Action
{{ $beneficiary['name'] }} {{ $beneficiary['relationship'] ?? 'N/A' }} {{ $beneficiary['phone'] ?? 'N/A' }} {{ $beneficiary['date_added'] ?? 'N/A' }} {{ $beneficiary['passport'] ?? 'N/A' }} Edit
@foreach($covers as $cover) @endforeach
Cover Policy number Date of issue Date of expire Autorenew Action
{{ $cover->cover_type }} {{ $cover->policy_number }} {{ \Carbon\Carbon::parse($cover->created_at)->format('d/m/Y') }} {{ \Carbon\Carbon::parse($cover->expiry_date)->format('d/m/Y') }} {{ $cover->autorenew ? 'Yes' : 'No' }}
Profile
@if ($userDetails)
📅 Date of Birth: {{ \Carbon\Carbon::parse($userDetails->date_of_birth)->format('d/m/Y') }}
📍 Address:
🆔 ID: {{ $userDetails->id_number }}
@endif @if ($user)
📧 Email: {{ $user->email }}
📞 Phone: {{ $user->phone }}
@endif
@foreach($claims as $claim) @endforeach
Policy Claim number Date filed Last updated Status Action
{{ $claim->policy }} {{ $claim->claim_number }} {{ $claim->date_filed }} {{ $claim->last_updated }} {{ $claim->status }}

Status: Date filed: