@extends('layouts.app') @section('title', 'Fix PC') @push('styles') @endpush @section('contents') @php $searchHidden = [ 'adp' => $adp, 'uid' => $uid, 'name' => $name, 'project_id' => $project_id, 'pc_id' => $pc_id, ]; @endphp
ADP # matches scheme ADP only — not project id, not digits inside a PC UID.
Hop From/To come from saved SDPMS forwards. Edit them, then use Apply hop changes. Undo history is collapsed under each PC.
@forelse ($results as $card)

ADP {{ $card['adp'] !== '' && $card['adp'] !== '—' ? $card['adp'] : '—' }} · {{ $card['scheme_code'] }}

{{ $card['scheme_name'] }} · project #{{ $card['project_id'] }}

Listing {{ $card['active_version_id'] ? '#'.$card['active_version_id'] : 'none' }} Actor {{ $card['current_actor'] }} Best #{{ $card['best_version_id'] }} PC-I {{ !empty($card['active_pc_i_id']) ? '#'.$card['active_pc_i_id'] : 'none' }} Revised {{ !empty($card['active_revised_pc_i_id']) ? '#'.$card['active_revised_pc_i_id'] : 'none' }} Issue {{ $card['listing_issue'] }}
@foreach ($card['versions'] as $v)
PC version
#{{ $v['id'] }}
@if ($v['is_revised']) Revised @endif @if ($v['is_best']) Best @endif @if ($v['is_listing']) Listing @endif {{ $v['created_on'] }}
{{ $v['pc_uid'] }}
{{ $v['state'] }} · {{ $v['active'] ? 'Active' : 'Inactive' }} · {{ $v['hops'] }} hops
stage: {{ $v['stage'] ?? '—' }}
{{ $v['issue'] }}
Created by
@if (($v['created_by_email'] ?? '—') !== '—')
{{ $v['created_by_name'] }}
@else
Missing creator
@endif
@csrf @foreach ($searchHidden as $hk => $hv) @endforeach
Current actor
{{ $v['actor_name'] }}
@if (!empty($v['actor_note'])) @else @endif
@csrf @foreach ($searchHidden as $hk => $hv) @endforeach
@csrf @foreach ($searchHidden as $hk => $hv) @endforeach
@if (empty($v['is_revised_flag']) && !empty($card['scheme_approved']))
@csrf @foreach ($searchHidden as $hk => $hv) @endforeach
@elseif (!empty($v['is_revised_flag'])) Already Revised @endif
Hop steps · {{ $v['created_on'] }}
@csrf @foreach ($searchHidden as $hk => $hv) @endforeach @if (!empty($v['hop_steps']))
@foreach ($v['hop_steps'] as $idx => $step) @endforeach
# When Action Stage From To Remarks Rollback
{{ $step['step'] }} {{ $step['created_at'] !== '' ? $step['created_at'] : '—' }} {{ $step['action'] }} {{ $step['stage'] }}
{{ \Illuminate\Support\Str::limit($step['remarks'], 100) }} @if (!empty($step['can_rollback'])) @csrf @foreach ($searchHidden as $hk => $hv) @endforeach @else @endif
Last hop To syncs as current actor. Per-row Rollback restores that hop’s prior From/To after an Apply.
@else No hop records in SDPMS yet. @endif
@endforeach
PC fix history
@if (!empty($card['fix_history']))
@foreach ($card['fix_history'] as $h) @endforeach
Batch When Action PC Summary Status Rollback
#{{ $h['id'] }} {{ $h['created_at'] !== '' ? $h['created_at'] : '—' }} {{ str_replace('_', ' ', $h['action']) }} #{{ implode(', #', $h['pc_form_ids'] ?? []) }} {{ $h['summary'] }} @if (!empty($h['rolled_back'])) Rolled back {{ $h['rolled_back_at'] }} @else Active @endif @if (!empty($h['can_rollback']))
@csrf @foreach ($searchHidden as $hk => $hv) @endforeach
@else @endif
@else

No Fix PC batches for this scheme yet.

@endif
@empty @if ($adp !== '' || $uid !== '' || $name !== '' || $project_id !== '' || $pc_id !== '' || $q !== '')

No schemes found for this search.

@endif @endforelse
@endsection @push('scripts') @endpush