@extends('layouts.master') @section('css') @include('trucks._call_style') @endsection @section('title') السائقين @stop @section('page-header') @endsection @section('content') @if (count($errors) > 0)
@endif @if (session('trip_ok'))
{{ session('trip_ok') }}
@endif
@forelse ($drivers as $k => $d) @php $trip = $onTrip[$d->id] ?? null; $tel = $d->phone ? 'tel:' . preg_replace('/[^\d+]/', '', $d->phone) : null; $wa = $d->phone ? 'https://wa.me/' . \App\Models\waybill_driver::intlPhone($d->phone) : null; @endphp
{{ mb_substr(trim($d->name), 0, 1) }}
{{ $d->name }}
{{ $d->nationality ?: 'سائق' }}
{{ $trip ? 'في رحلة' : 'متاح' }}
@if ($d->phone) {{ $d->phone }} @else مفيش رقم جوال - دوس تعديل وضيفه @endif
الهوية: {{ $d->id_number ?: '—' }} الرخصة: {{ $d->license_number ?: '—' }}
@if ($trip)
{{ optional($trip->truck)->plate_number }} : {{ $trip->from_region }} ← {{ $trip->to_region }}
@endif
@empty

مفيش سائقين لسه. دوس «إضافة سائق».
@endforelse
@include('trucks._driver_modal') @endsection