@extends('layouts.app') @section('title', $workOrder->work_order_no . ' - PMMS') @section('content')
{{ __('app.work_order.show.inspection.not_scheduled') }}
@else {{-- Permintaan tambahan pengguna - dipaparkan sebagai table (sama corak dengan kad Attachments, partials.attachment-table) supaya lebih tersusun. --}}| {{ __('app.work_order.show.inspection.table.date_time') }} | {{ __('app.work_order.show.inspection.table.staff') }} | {{ __('app.work_order.show.inspection.table.result') }} | {{ __('app.work_order.show.inspection.table.notes') }} | {{ __('app.work_order.show.inspection.table.responsibility') }} | {{ __('app.work_order.show.inspection.table.attachments') }} | {{ __('app.work_order.show.inspection.table.actions') }} |
|---|---|---|---|---|---|---|
| {{ $inspection->inspection_date->format('d/m/Y') }} @if ($inspection->inspection_time) {{ $inspection->inspection_time }} @endif | {{ $inspection->assignedStaff?->name ?? '-' }} | {{ $inspection->result ?? __('app.work_order.show.inspection.result_pending') }} | {{ $inspection->notes ?? '-' }} | {{ $inspection->responsibility_type ?? '-' }} | @if ($inspection->attachments->isNotEmpty()) @include('partials.attachment-gallery', ['attachments' => $inspection->attachments, 'downloadRoute' => 'inspection-attachments.download']) @else - @endif | @can('recordInspection', $workOrder) @if (! $inspection->result) {{ __('app.work_order.show.inspection.record_result') }} @else - @endif @else - @endcan |
{{ __('app.work_order.show.contractor_approval.none') }}
@else @foreach ($workOrder->approvalRequests as $approvalRequest){{ __('app.work_order.show.assignment.none') }}
@else{{ __('app.work_order.show.engagement.not_entered') }}
@else{!! __('app.work_order.show.timeline.before_photo_required') !!}
@endif @endcan @can('addInternalNote', $workOrder) @endcan @if ($timeline->isEmpty()){{ __('app.work_order.show.timeline.empty') }}
@else {{-- Permintaan tambahan pengguna - dipaparkan sebagai table (sama corak dengan kad Attachments/Inspection) supaya lebih tersusun. Jenis entri berbeza-beza (STATUS/RESPONSIBILITY/PROGRESS/Nota) - lajur "Butiran" sengaja fleksibel (bukan beberapa lajur kosong mengikut jenis) kerana setiap jenis bawa medan berlainan. --}}| {{ __('app.work_order.show.timeline.table.date_time') }} | {{ __('app.work_order.show.timeline.table.by') }} | {{ __('app.work_order.show.timeline.table.type') }} | {{ __('app.work_order.show.timeline.table.details') }} |
|---|---|---|---|
| {{ $item->created_at->format('d/m/Y H:i') }} | {{ $item->creator?->name ?? '-' }} | @if ($item->type === 'STATUS') {{ __('app.work_order.show.timeline.status_badge') }} @elseif ($item->type === 'RESPONSIBILITY') {{ __('app.work_order.show.timeline.responsibility_badge') }} @elseif ($item->type === 'PROGRESS') {{ __('app.work_order.show.timeline.progress_badge') }} @else {{ $item->visibility }} @endif |
@if ($item->type === 'STATUS')
{{ $item->old_status ?? __('app.work_order.show.timeline.new') }} → {{ $item->new_status }}
@if ($item->reason)
{{ __('app.work_order.show.timeline.reason_label', ['reason' => $item->reason]) }}
@endif
@elseif ($item->type === 'RESPONSIBILITY')
{{ $item->old_responsibility ?? __('app.work_order.show.timeline.responsibility_pending') }} → {{ $item->new_responsibility }}
@if ($item->reason)
{{ __('app.work_order.show.timeline.reason_label', ['reason' => $item->reason]) }}
@endif
@elseif ($item->type === 'PROGRESS')
{{ __('app.work_order.show.timeline.status_label', ['status' => $item->status]) }}
@if ($item->notes)
{{ $item->notes }}
@endif
@else
{{ $item->note }}
@endif
|
{{ __('app.work_order.show.completion.not_needed_tenant') }}
@elseif (! in_array($workOrder->status, ['IN_PROGRESS', 'PENDING_CONTRACTOR', 'PENDING_JMB'], true)){{ __('app.work_order.show.completion.not_completed') }}
@else @can('complete', $workOrder) @php // Fasa 2 Langkah 32: wajib jika belum ada lampiran fasa AFTER // khusus (bukan sekadar "mana-mana lampiran sedia ada"). $hasAfterEvidence = $workOrder->attachments->contains(fn ($a) => $a->phase === 'AFTER'); @endphp @else{{ __('app.work_order.show.completion.not_completed') }}
@endcan @endif{{ __('app.work_order.show.verification.not_needed_tenant') }}
@elseif ($workOrder->verifications->isEmpty()){{ __('app.work_order.show.verification.empty') }}
@endif @if ($workOrder->verifications->isNotEmpty())