{{-- Flash Messages --}} @if(session('success'))
{{ session('success') }}
@endif {{-- Period Header --}}

{{ $period->name }}

{{ $period->status }}

{{ \Carbon\Carbon::parse($period->starts_at)->format('M d, Y') }} — {{ \Carbon\Carbon::parse($period->ends_at)->format('M d, Y') }}

@if($period->status === 'processing')
@csrf
@endif @if($period->status === 'approved')
@csrf
@endif
{{-- Summary KPIs --}} {{-- Teacher Calculations Table --}}

{{ __('Teacher Calculations') }}

{{ $calculations->count() }} {{ __('Records') }}
@forelse($calculations as $calc) {{-- Payment Modal per calculation --}}
@csrf
{{ __('Paying') }} {{ $calc->teacher->name ?? '' }} an amount of GHS {{ number_format($calc->net_amount, 2) }}
@empty @endforelse
{{ __('Teacher') }} {{ __('Sessions') }} {{ __('Gross') }} {{ __('Admin Fee') }} {{ __('Net') }} {{ __('Status') }} {{ __('Actions') }}
{{ $calc->teacher->name ?? 'Unknown' }} {{ $calc->session_count ?? 0 }} GHS {{ number_format($calc->gross_amount, 2) }} -GHS {{ number_format($calc->admin_fee_amount, 2) }} GHS {{ number_format($calc->net_amount, 2) }} {{ $calc->calculation_status }} @if($calc->calculation_status === 'locked') @endif
{{ __('No calculations found for this period.') }}