{{ $patientEnrollments->total() }}
{{ $businessEnrollments->total() }}
${{ number_format($commissions->sum('commission_amount'), 2) }}
You haven't enrolled any patients yet.
| Patient | Plan | Status | Enrolled On | Commission |
|---|---|---|---|---|
|
{{ $enrollment->user->name }}
{{ $enrollment->user->email }}
|
{{ $enrollment->plan->name ?? 'N/A' }}
${{ number_format($enrollment->plan->price ?? 0, 2) }}/month
|
{{ ucfirst($enrollment->status) }}
@if($enrollment->status === 'pending_payment')
|
{{ $enrollment->created_at->format('M d, Y') }} | ${{ number_format(($enrollment->plan->price ?? 0) * (Auth::user()->agent->commission_rate / 100), 2) }} |
You haven't enrolled any businesses yet.
| Business | Admin | Status | Enrolled On | Commission |
|---|---|---|---|---|
|
@php
$metaData = $enrollment->meta_data ?? [];
$businessId = $metaData['business_id'] ?? null;
$business = $businessId ? \App\Models\Business::find($businessId) : null;
@endphp
{{ $business->name ?? 'N/A' }}
{{ $business->email ?? 'N/A' }}
|
{{ $enrollment->user->name }}
{{ $enrollment->user->email }}
|
{{ ucfirst($enrollment->status) }}
@if($enrollment->status === 'pending_payment')
|
{{ $enrollment->created_at->format('M d, Y') }} | @php $businessPlanId = $metaData['business_plan_id'] ?? null; $businessPlan = $businessPlanId ? \App\Models\BusinessPlan::find($businessPlanId) : null; $totalPrice = 0; if ($businessPlan) { if ($businessPlan->total_price) { $totalPrice = $businessPlan->total_price_in_dollars; } elseif ($businessPlan->price_per_plan && $businessPlan->plan_quantity) { $totalPrice = $businessPlan->price_per_plan_in_dollars * $businessPlan->plan_quantity; } } $commission = $totalPrice * (Auth::user()->agent->commission_rate / 100); @endphp ${{ number_format($commission, 2) }} |
You haven't earned any commissions yet.
| Date | Type | Amount | Commission | Status |
|---|---|---|---|---|
| {{ $commission->created_at->format('M d, Y') }} |
@if($commission->subscription)
@if($commission->subscription->user->hasRole('business_admin'))
Business Enrollment
@else
Patient Enrollment
@endif
@else
Transaction
@endif
|
${{ number_format($commission->total_amount, 2) }} |
${{ number_format($commission->commission_amount, 2) }}
{{ $commission->agent_rate }}%
|
{{ ucfirst($commission->status) }} |