@php $maxHeight = isset($maxHeight) && $maxHeight ? $maxHeight : "500px" @endphp @php $minHeight = isset($minHeight) && $minHeight ? $minHeight : "200px" @endphp @php $airlineModule = isset($airlineModule) ? $airlineModule : airlineModule() @endphp
@foreach($serviceData["services"] as $airlineService) @php $serviceType = $airlineService->serviceType @endphp @if ($airlineService->service_timings == 1) @if ($airlineService->service[$serviceType] != 1) @continue @endif @php $obj = $airlineService->service @endphp @else @if ($airlineService[$serviceType] != 1) @continue @endif @php $obj = $airlineService @endphp @endif @if ($serviceType == ARRIVAL_SERVICE) @php $req = "arr_staff_req" @endphp @php $min = "arr_staff_min" @endphp @php $arr = getFlightArrivalInitialDatePTA($flight); @endphp @php $plannedReport = date("Y-m-d H:i:s", strtotime($arr) - (60 * $obj->arr_report_time)) @endphp @php $plannedRelease = date("Y-m-d H:i:s", strtotime($arr) + (60 * $obj->arr_release_time)) @endphp @php $duration = date("H:i", strtotime($plannedRelease) - strtotime($plannedReport)) @endphp @php $slaClass = "label-success" @endphp @elseif ($serviceType == DEPARTURE_SERVICE) @php $req = "dep_staff_req" @endphp @php $min = "dep_staff_min" @endphp @php $dep = getFlightDepartureInitialDatePTD($flight) @endphp @php $plannedReport = date("Y-m-d H:i", strtotime($dep) - (60 * $obj->dep_report_time)) @endphp @php $plannedRelease = date("Y-m-d H:i", strtotime($dep) - (60 * $obj->dep_release_time)) @endphp @php $duration = date("H:i", strtotime($plannedRelease) - strtotime($plannedReport)) @endphp @php $slaClass = "label-primary" @endphp @elseif($serviceType == TURNAROUND_SERVICE) @php $req = "turn_staff_req" @endphp @php $min = "turn_staff_min" @endphp @php $arr = getFlightArrivalInitialDatePTA(getParentFlight($flight)) @endphp @php $dep = getFlightDepartureInitialDatePTD($flight) @endphp @php $plannedReport = date("Y-m-d H:i", strtotime($arr) - (60 * $obj->turn_report_time)) @endphp @php $plannedRelease = date("Y-m-d H:i", strtotime($dep) - (60 * $obj->turn_release_time)) @endphp @php $duration = date("H:i", strtotime($plannedRelease) - strtotime($plannedReport)) @endphp @php $slaClass = "label-warning" @endphp @endif @php $sla = $obj->service ? $obj->service->abbr : $obj->abbr @endphp @if (isset($flight->staffList[$sla])) @foreach($flight->staffList[$sla] as $i => $each) @php $plannedDuration = date("H:i", strtotime($each->planned_release_time) - strtotime($each->planned_report_time)); @endphp @endforeach @endif @endforeach
SLA Staff Start Time Release Time Duration
{{ $sla }} Required: {{ $obj->{$req} }} {{ baseDateFormat($plannedReport, true) }} SLA {{ baseDateFormat($plannedRelease, true) }} SLA {{ $duration }} SLA
{{ $i + 1 }} {{ getUserLocationAirport($each->user) }} - {{ getUserName($each->user) }} {{ baseDateFormat($each->planned_report_time, true) }} PLN @if ($each->report_time)
{{ baseDateFormat($each->report_time, true) }} ACT @endif
{{ baseDateFormat($each->planned_release_time, true) }} PLN @if ($each->release_time)
{{ baseDateFormat($each->release_time, true) }} ACT @endif
{{ $plannedDuration }} PLN @if ($each->report_time && $each->release_time) @php $duration = date("H:i", strtotime($each->release_time) - strtotime($each->report_time)); @endphp
{{ $duration }} ACT @endif