@extends('layout') @if(session('message')) @endif @section('body')
@if($driver===null)

We cannot find this driver. Please contact to admin

@else
Drivers Information:
Full Name:
{{ $driver->userData->firstname }} {{ $driver->userData->lastname }}
Cell phone:
{{ $driver->userData->cellphone?$driver->userData->cellphone:'---' }}
Home phone:
{{ $driver->userData->homephone?$driver->userData->homephone:'---' }}
Status:
{!! $driver->status === 'loaded' ? 'loaded' : 'waiting' !!}
@if(in_array($usr->role,['safety','admin']))
DL Expiration date:
{{ date('j F Y', strtotime($driver->dl_expired)) }}
Med. Expiration date:
{{ date('j F Y', strtotime($driver->medical_expired)) }}
MVR. Expiration date:
{{ date('j F Y', strtotime($driver->medical_expired)) }}
@endif
Truck Information:
Truck:
{{ $driver->truckData->number }} {{ $driver->truckData->make }} {{ $driver->truckData->model }}
@if(in_array($usr->role,['safety','admin']))
Annual Inspection:
{{ date('j F Y', strtotime($driver->truckData->annual_expired)) }}
Plate Expired:
{{ date('j F Y', strtotime($driver->truckData->plate_expired)) }}
Truck Insurance:
{{ date('j F Y', strtotime($driver->truckData->insurance_expired)) }}
@endif
Trailer:
{{ $driver->trailerData->number }} {{ $driver->trailerData->make }} {{ $driver->trailerData->model }}
@if(in_array($usr->role,['safety','admin']))
Plate Expired:
{{ date('j F Y', strtotime($driver->trailerData->plate_expired)) }}
Trailer Insurance:
{{ date('j F Y', strtotime($driver->trailerData->insurance_expired)) }}
@endif
Current/Last Load:
@if($load)
Date:
{{ $load->pickup_date }}
Distance:
{{ $load->distance }}
Price:
${{ $load->price }}
{{ $load->pickup_city}}, {{ $load->pickup_state }} -> {{ $load->delivery_city }}, {{ $load->delivery_state }}
@else

Driver have not any load

@endif
@if(in_array($usr->role,['accounting','admin'])) @if($driver->userData->companyData) @foreach($driver->userData->companyData as $company)
Company:
Company:
Address:
{{ $company->address1 }} {{ $company->address2 }} {{ $company->city }}, {{ $company->state }} {{ $company->zipcode }}
EIN:
{{ $company->ein }}
Routing number:
{{ $company->routing }}
Account number:
{{ $company->accounting }}
@endforeach @endif @endif
Last location:
@foreach($locations as $loc) @endforeach
Date Location
{{ date('H:i, j F Y', strtotime($loc->created_at)) }} {{ $loc->nearby }} open in google maps
{{ $locations->links('vendor/pagination') }}

The history of the driver's location is deleted every 2 days.

@endif
@endsection @section('script') @if(in_array($usr->role, ['admin','safety'])) @endif @endsection