{{-- Reports tab: PACS formats & oral reports · approval ladder · sign / upload signed copy · submit to court · record outcome · transmit (hostel) --}} @php $allTypes = config('probation.report_types') + config('probation.report_types_supervision', []); $repTypes = $isSI ? config('probation.report_types', []) : $allTypes; $outcomeOptions = \App\Http\Controllers\CaseReportController::outcomeOptions($case->case_type); $canTransmit = in_array($case->case_type, ['probation_hostel', 'halfway_house'], true); @endphp
Reports & Approval Ladder
@forelse($case->reports as $r)
{{ $allTypes[$r->report_type] ?? ucwords(str_replace('_',' ',$r->report_type)) }} — {{ $r->title }} @if($r->form_key) {{ in_array($r->status, ['Draft', 'Returned']) ? 'fill in' : 'open' }} print @else view @endif @if($r->file_path) signed copy@endif
{{ $r->status }}
{{ $r->body }}
@foreach($r->approvals->sortBy('level') as $ap) {{ ucfirst($ap->level) }}: {{ $ap->decision }}@if($ap->feedback) “{{ $ap->feedback }}”@endif  @endforeach @if($r->transmitted_at) · Transmitted to {{ optional(\App\Models\Branch::find($r->transmitted_to_branch_id))->branch_name }} {{ $r->transmitted_at->format('d M Y') }}{{ $r->received_at ? ' (received)' : '' }}@endif
@if(!$r->is_signed)
@csrf
@endif
@csrf
@if(in_array($r->status, ['Submitted', 'Under Review']))
@csrf
@endif @if($r->status === 'Approved')
@csrf
@endif @if($canTransmit)
@csrf
@endif
@if(in_array($r->status, ['Submitted to Court', 'Approved']))
@csrf
Record court / advisory outcome
@endif
@empty

No reports drafted.

@endforelse @if($case->courtOutcomes->count())
Outcomes recorded: @foreach($case->courtOutcomes->sortByDesc('outcome_date') as $o) {{ $outcomeOptions[$o->outcome] ?? ucwords(str_replace('_', ' ', $o->outcome)) }} · {{ optional($o->outcome_date)->format('d M Y') }} @endforeach
@endif
@csrf