@extends('admin.admin_dashboard') @section('admin')
Requisitions {{ $requisition->reference }} @can('update', $requisition) Edit @endcan @can('submit', $requisition)
@csrf
@endcan @can('delete', $requisition)
@csrf @method('DELETE')
@endcan
@if($errors->any())
Please fix the following:
    @foreach($errors->all() as $error)
  • {{ $error }}
  • @endforeach
@endif @if($requisition->isApprovedForDisbursement())
Ready for disbursement
All approvals are complete. Finance can record payment of UGX {{ number_format($remainingDisbursement, 2) }}.
@endif @if($requisition->isAccountabilityRequired())
Accountability / M&E report
Status: {{ $requisition->accountability_status?->label() ?? 'Pending submission' }} @if($requisition->accountability_due_at) · Due {{ $requisition->accountability_due_at->format('d M Y') }} @endif @if($requisition->accountability_reminders_sent) · {{ $requisition->accountability_reminders_sent }} reminder(s) sent @endif
@if($meReport)
Report #{{ $meReport->id }} — {{ $meReport->status->label() }} @if($meReport->submitted_at) · submitted {{ $meReport->submitted_at->format('d M Y') }} @endif
@endif
@can('submitAccountability', $requisition) {{ $meReport ? 'Continue M&E report' : 'Submit accountability report' }} @endcan @if($meReport) View report @endif
@endif

{{ $requisition->justification ?: '—' }}

Requested by {{ $requisition->requester->name ?? '—' }} · {{ $requisition->requisition_date?->format('d M Y') }}
Budget item Activity Qty Requested (UGX) Quotation @foreach($requisition->lines as $line) {{ $line->budgetItem->item_name ?? '—' }} {{ $line->budgetItem->activity->name ?? '—' }} {{ number_format($line->quantity_requested, 2) }} {{ number_format($line->amount_requested, 2) }} @if($line->attachmentUrl()) {{ $line->attachmentBasename() }} @else @endif @endforeach Total {{ number_format($requisition->total_requested, 2) }} @if($requisition->attachments->isNotEmpty())

These were uploaded before per-line quotations were introduced.

@endif @if($requisition->disbursements->isNotEmpty()) @foreach($requisition->disbursements as $d)
{{ number_format($d->amount_disbursed, 2) }} · {{ $d->disbursed_at?->format('d M Y H:i') }} · {{ $d->disburser->name ?? '' }} @if($d->payment_reference)
Ref: {{ $d->payment_reference }}
@endif
@endforeach
@endif
@foreach($approvalTimeline as $step)
{{ $step['stage_name'] }} @if(!empty($step['stage_subtitle']))
{{ $step['stage_subtitle'] }}
@endif @if(!empty($step['assignee']) && empty($step['actor']))
{{ $step['assignee']->name }} · awaiting action
@endif
{{ $step['action'] }}
@if($step['actor'])
{{ $step['actor']->name }} · {{ $step['acted_at']?->format('d M Y H:i') }}
@endif @if($step['comments'])
{{ $step['comments'] }}
@endif
@endforeach
@if($canApprove)
@csrf
@csrf
@csrf
@endif @can('disburse', $requisition) @if($remainingDisbursement > 0)

Record payment after all approval stages are complete.

@csrf
@else

Fully disbursed.

@endif @elseif($requisition->canReceiveDisbursement() && $remainingDisbursement > 0)

Awaiting finance officer with disbursement permission.

@endcan @if($meReport && auth()->user()->can('approve', $meReport))

Approve the M&E report to close accountability and stop reminder emails.

@csrf
@endif
@endsection