@extends('admin.layouts.app') @section('title', 'Dashboard') @section('breadcrumb') / Dashboard @endsection @push('styles') @endpush @section('content')

Total Donations

₹{{ number_format($stats['total_donations'],2) }}

All time

Total Donors

{{ number_format($stats['total_donors']) }}

Registered donors

Active Projects

{{ $stats['active_projects'] }}

of {{ $stats['total_projects'] }} total

CSR Companies

{{ $stats['total_csr_companies'] }}

Active partners
Admin Expense
₹{{ number_format($stats['total_admin_expense']) }}
Campaign Expense
₹{{ number_format($stats['total_campaign_expense']) }}
Project Expense
₹{{ number_format($stats['total_project_expense']) }}
Beneficiary Fund
₹{{ number_format($stats['total_beneficiary_fund']) }}
CSR Fund Spent
₹{{ number_format($stats['total_csr_fund']) }}
Beneficiaries
{{ number_format($stats['total_beneficiaries']) }}
Donations Over Time
Last 12 months
Donation by Purpose
Today's Summary — {{ now()->format('d M Y') }}
Admin Expense
₹{{ number_format($todayStats['admin_expense']) }}
Campaign Expense
₹{{ number_format($todayStats['campaign_expense']) }}
Project Expense
₹{{ number_format($todayStats['project_expense']) }}
Beneficiary Expense
₹{{ number_format($todayStats['beneficiary_expense']) }}
CSR Expense
₹{{ number_format($todayStats['csr_expense']) }}
Today's Donations
₹{{ number_format($todayStats['donations']) }} ({{ $todayStats['new_donations'] }})
Recent Donations
View All
@forelse($recentDonations as $donation) @empty @endforelse
Donor Amount Purpose Status Date
{{ $donation->donor_name }}
{{ $donation->donation_id }}
₹{{ number_format($donation->amount) }} {{ Str::limit($donation->purpose, 20) ?? 'General' }} @if($donation->payment_status === 'completed') Completed @elseif($donation->payment_status === 'pending') Pending @else {{ ucfirst($donation->payment_status) }} @endif {{ $donation->donation_date->format('d M Y') }}
No donations yet
Active Projects
View All
@forelse($recentProjects as $project)
{{ $project->project_title }}
{{ $project->csrCompany->company_name ?? 'N/A' }}
@if($project->budget_allocation)
@php $pct = $project->budget_allocation > 0 ? min(100, ($project->total_spent/$project->budget_allocation)*100) : 0; @endphp
₹{{ number_format($project->total_spent) }} of ₹{{ number_format($project->budget_allocation) }}
@endif
@php $statusColors = ['draft'=>'secondary','pending'=>'warning','approved'=>'info','active'=>'success','completed'=>'primary','cancelled'=>'danger']; @endphp {{ ucfirst($project->status) }}
@empty
No active projects
@endforelse
@endsection @push('scripts') @endpush