@extends('layouts.app') @php $currencySymbol = match (($stats['currency'] ?? 'USD')) { 'EUR' => '€', 'GBP' => '£', default => '$', }; @endphp @push('style') @endpush @section('content')
@can('view referrals')
Current Balance
{{ number_format($stats['current_balance'] ?? 0, 2) }}{{ $currencySymbol }}
Can Be Withdraw
{{ number_format($stats['can_withdraw'] ?? 0, 2) }}{{ $currencySymbol }}
Successfully Withdraw
{{ number_format($stats['successful_withdraw'] ?? 0, 2) }}{{ $currencySymbol }}
Share Benefits
Total Revenue
{{ number_format($stats['total_revenue'] ?? 0, 2) }}{{ $currencySymbol }}
Coming Soon
00.00{{ $currencySymbol }}
{{ ($isSuperAdmin ?? false) ? 'All Referrals' : 'My Referrals' }}
Referral and earning history
count() > 0) id="referrals-table" @endif class="table"> @if($isSuperAdmin ?? false)@endif @forelse($referrals as $referral) @if($isSuperAdmin ?? false)@endif @empty @endforelse
ReferrerCode Referred User Reward Status Date Action
{{ $referral->referrer->name ?? 'N/A' }}{{ $referral->code }} {{ $referral->referredUser->name ?? 'N/A' }} {{ $currencySymbol }}{{ number_format($referral->reward_amount, 2) }} {{ ucfirst($referral->status) }} {{ $referral->created_at->format('Y-m-d') }} @if(auth()->check() && auth()->user()->hasRole('super admin'))
@csrf @method('DELETE')
@else - @endif
No referrals yet.
{{ $referrals->links() }}
@else
You do not have permission to view referrals.
@endcan
@endsection @if($referrals->count() > 0) @push('script') @endpush @endif