@extends('layouts.app') @section('content')
{{-- Main Info --}}

تفاصيل المخالفة

الموظف {{ $disciplinary->employee->first_name ?? '' }} {{ $disciplinary->employee->last_name ?? '' }}
نوع الإجراء {{ $disciplinary->type_label }}
الخطورة @php $sevClass = match($disciplinary->severity) { 'low' => 'status-active', 'medium' => 'status-pending', 'high' => 'status-expired', 'critical' => 'status-danger', default => 'status-draft', }; @endphp {{ $disciplinary->severity_label }}
الحالة @php $statusClass = match($disciplinary->status) { 'draft' => 'status-draft', 'active' => 'status-danger', 'acknowledged' => 'status-pending', 'appealed' => 'status-expired', 'resolved' => 'status-active', 'expired' => 'status-draft', default => 'status-draft', }; @endphp {{ $disciplinary->status_label }}
تاريخ الحادثة {{ $disciplinary->incident_date->format('Y-m-d') }}
تاريخ الإجراء {{ $disciplinary->action_date->format('Y-m-d') }}
@if ($disciplinary->expiry_date)
تاريخ الانتهاء {{ $disciplinary->expiry_date->format('Y-m-d') }}
@endif
صدر بواسطة {{ $disciplinary->issuer->name ?? '—' }}
إنذارات سابقة {{ $disciplinary->previous_warnings_count }}
وصف المخالفة {{ $disciplinary->description }}
@if ($disciplinary->corrective_action)
الإجراء التصحيحي {{ $disciplinary->corrective_action }}
@endif @if ($disciplinary->employee_response)
رد الموظف {{ $disciplinary->employee_response }}
@endif @if ($disciplinary->follow_up_notes)
ملاحظات المتابعة {{ $disciplinary->follow_up_notes }}
@endif
{{-- Actions --}} @if (in_array($disciplinary->status, ['active', 'acknowledged', 'appealed']))

الإجراءات المتاحة

@if ($disciplinary->status === 'active')
@csrf
@endif @if (in_array($disciplinary->status, ['active', 'acknowledged'])) @endif
{{-- Resolve Form --}} {{-- Appeal Form --}}
@endif
{{-- Sidebar --}}
{{-- Escalation --}}

مستوى التصعيد

{{ $escalation['active_count'] }}
إنذارات نشطة
الإجراء القادم: {{ $escalation['label'] }}
{{-- History --}}

السجل التأديبي

@if ($history->isEmpty())

لا يوجد سجل سابق

@else @foreach ($history as $h)
{{ $h->type_label }} @php $hClass = match($h->status) { 'active' => 'status-danger', 'resolved' => 'status-active', default => 'status-draft', }; @endphp {{ $h->status_label }}
{{ $h->subject }} — {{ $h->incident_date->format('Y-m-d') }}
@endforeach @endif
@endsection