@extends('components.app-layout') @section('title', 'Staff Dashboard') @section('content')
@if(auth()->user()->profile_photo) {{ auth()->user()->name }} @else
{{ substr(auth()->user()->name, 0, 1) }}
@endif

Welcome back, {{ auth()->user()->name }}!

{{ $roleInfo['name'] }} Dashboard

{{ now()->format('l, F j, Y') }}
{{ now()->format('g:i A') }}
@if($roleInfo['permissions_count'] > 0)
{{ $roleInfo['permissions_count'] }} Permissions
@endif
@if(isset($stats['members']))

Total Members

{{ number_format($stats['members']['total_members']) }}

{{ number_format($stats['members']['active_members']) }} Active

@endif @if(isset($stats['events']))

Upcoming Events

{{ number_format($stats['events']['upcoming_events']) }}

{{ number_format($stats['events']['this_month']) }} This Month

@endif @if(isset($stats['payments']))

This Month

₵{{ number_format($stats['payments']['this_month_amount'], 2) }}

{{ number_format($stats['payments']['total_payments']) }} Payments

@endif @if(isset($stats['attendance']))

Attendance

{{ number_format($stats['attendance']['this_month']) }}

This Month

@endif @if(isset($stats['ministries']))

Ministries

{{ number_format($stats['ministries']['total_ministries']) }}

{{ number_format($stats['ministries']['total_members']) }} Members

@endif @if(isset($stats['messages']))

SMS Messages

{{ number_format($stats['messages']['total_sent']) }}

{{ number_format($stats['messages']['pending']) }} Pending

@endif
@if(count($quickActions) > 0)

Quick Actions

{{ count($quickActions) }} available
@foreach($quickActions as $action)

{{ $action['title'] }}

{{ $action['description'] }}

@endforeach
@endif @if(count($recentActivities) > 0)
@if(isset($recentActivities['members']) && $recentActivities['members']->count() > 0)

Recent Members

View All
@foreach($recentActivities['members'] as $member)
{{ substr($member->first_name, 0, 1) }}

{{ $member->full_name }}

{{ $member->family->family_name ?? 'No Family' }}

{{ $member->created_at->diffForHumans() }}
@endforeach
@endif @if(isset($recentActivities['events']) && $recentActivities['events']->count() > 0)

Upcoming Events

View All
@foreach($recentActivities['events'] as $event)

{{ $event->title }}

{{ $event->start_datetime->format('M d, Y g:i A') }}

@endforeach
@endif
@endif @if(count($stats) == 0)

No Permissions Assigned

Your account doesn't have any permissions assigned yet. Please contact your administrator to grant you access to church management features.

Edit Profile
@endif
@endsection