@php $start_month = 1; $end_month = 1; if (Carbon::parse($start_time)->diffInMonths(Carbon::parse($current_month)) > 0 || (Carbon::parse($start_time)->diffInMonths(Carbon::parse($current_month)) == 0 && intval(Carbon::parse($current_month)->format('m')) - intval(Carbon::parse($start_time)->format('m')) == 1)){ $start_month = 0; } if (Carbon::parse($end_time)->diffInMonths(Carbon::parse($current_month)) != 0){ $end_month = 0; } $start_day = 1; $end_day = intval(Carbon::parse($current_month.'-01')->endOfMonth()->format('d')); if($start_month == 1 && $end_month == 1){ $start_day = intval(Carbon::parse($start_time)->format('d')); $end_day = intval(Carbon::parse($end_time)->format('d')); } else if($start_month == 1 && $end_month != 1){ $start_day = intval(Carbon::parse($start_time)->format('d')); } else if($start_month != 1 && $end_month == 1){ $end_day = intval(Carbon::parse($end_time)->format('d')); } $period = Carbon\CarbonPeriod::create(Carbon::now()->subDays(3)->format('Y-m-d'), Carbon::now()->addDays(3)->format('Y-m-d')); @endphp {{-- --}} @foreach ($period as $item) @endforeach @foreach ($period as $item) @endforeach @foreach ($period as $item) @endforeach @if ($vehicles->count() > 0) @foreach ($vehicles as $vehicle) {{-- --}} @foreach ($period as $item) @php $status = $vehicle->getforwardingStatus($item->format('Y-m-d')); $is_forwarding = $vehicle->isForwarding($item->format('Y-m-d')); $wrecker_status = $vehicle->getwreckerStatus($item->format('Y-m-d')); $is_wrecking = $vehicle->isWrecking($item->format('Y-m-d')); @endphp @if ($is_forwarding || $is_wrecking) @else @endif @endforeach @endforeach @else @endif
管理担当者種別 ドアナンバー 型式 登録番号 {{-- @if (!$start_month)--}} {{--

前月

--}} {{-- @endif--}}

{{ Carbon::parse($current_month)->format('Y').'年'.sprintf('%2d', Carbon::parse($current_month)->format('m')).'月' }}

{{-- Carbon::parse($end_time)->diffInMonths(Carbon::parse($current_month)) --}} {{-- @if (!$end_month)--}} {{--

翌月

--}} {{-- @endif--}}
{{ $item->day }}
{{ config('const.jp_week.'.$item->dayOfWeek) }}
午前 午後
{{ is_object($vehicle->charge_user) ? $vehicle->charge_user->name_kanji : "" }}{{ config('const.own_vehicle_type.'.$vehicle->own_vehicle_type) }} {{ $vehicle->door_number }} {{ $vehicle->vehicleModel() }} {{ $vehicle->register_no }} @if ($is_forwarding) @foreach ($status as $key=>$time) @if ($time['working_status'] == config('const.forwarding_work_time_status_code.departure') || $time['working_status'] == config('const.forwarding_work_time_status_code.resume')) $time['forwarding_id']]) }}">

{{ Carbon::parse($time['operation_time'])->format('H:i') }}~{{ isset($status[$loop->index + 1]['operation_time']) ? Carbon::parse($status[$loop->index + 1]['operation_time'])->format('H:i') : (Carbon::now()->format('Y-m-d') == $item->format('Y-m-d') ? Carbon::now()->format('H:i') : '12:00') }}

@endif @if ($key == 0 && ($time['working_status'] == config('const.forwarding_work_time_status_code.arrival') || $time['working_status'] == config('const.forwarding_work_time_status_code.break'))) $time['forwarding_id']]) }}"> @if(Carbon::parse($time['operation_time'])->hour >= 12)

09:00~12:00

@elseif(Carbon::parse($time['operation_time'])->hour < 12 && Carbon::parse($time['operation_time'])->hour >= 9)

09:00~{{ Carbon::parse($time['operation_time'])->format('H:i') }}

@endif
@endif @endforeach @else @foreach ($wrecker_status as $time) $time['wrecker_request_id']]) }}"> @if(Carbon::parse($time['start_time'])->diffInDays($item) == 0 && Carbon::parse($time['start_time'])->hour < 12)

{{ Carbon::parse($time['start_time'])->hour > 9 ? Carbon::parse($time['start_time'])->format('H:i') : '09:00' }}~{{ Carbon::parse($time['end_time'])->hour < 12 ? Carbon::parse($time['end_time'])->format('H:i') : '12:00' }}

@else

09:00~12:00

@endif
@endforeach @endif
@if ($is_forwarding) @foreach ($status as $key=>$time) @if ($time['working_status'] == config('const.forwarding_work_time_status_code.departure') || $time['working_status'] == config('const.forwarding_work_time_status_code.resume')) $time['forwarding_id']]) }}">

{{ Carbon::parse($time['operation_time'])->format('H:i') }}~{{ isset($status[$loop->index + 1]['operation_time']) ? Carbon::parse($status[$loop->index + 1]['operation_time'])->format('H:i') : (Carbon::now()->format('Y-m-d') == $item->format('Y-m-d') ? Carbon::now()->format('H:i') : '12:00') }}

@endif @if ($key == 0 && ($time['working_status'] == config('const.forwarding_work_time_status_code.arrival') || $time['working_status'] == config('const.forwarding_work_time_status_code.break'))) $time['forwarding_id']]) }}"> @if(Carbon::parse($time['operation_time'])->hour >= 15)

12:00~15:00

@elseif(Carbon::parse($time['operation_time'])->hour < 15 && Carbon::parse($time['operation_time'])->hour >= 12)

12:00~{{ Carbon::parse($time['operation_time'])->format('H:i') }}

@endif
@endif @endforeach @else @foreach ($wrecker_status as $time) $time['wrecker_request_id']]) }}"> @if(Carbon::parse($time['start_time'])->diffInDays($item) == 0 && Carbon::parse($time['start_time'])->hour < 15)

{{ Carbon::parse($time['start_time'])->hour > 12 ? Carbon::parse($time['start_time'])->format('H:i') : '12:00' }}~{{ Carbon::parse($time['end_time'])->hour < 15 ? Carbon::parse($time['end_time'])->format('H:i') : '15:00' }}

@else

12:00~15:00

@endif
@endforeach @endif
@if ($is_forwarding) @foreach ($status as $key=>$time) @if ($time['working_status'] == config('const.forwarding_work_time_status_code.departure') || $time['working_status'] == config('const.forwarding_work_time_status_code.resume')) $time['forwarding_id']]) }}">

{{ Carbon::parse($time['operation_time'])->format('H:i') }}~{{ isset($status[$loop->index + 1]['operation_time']) ? Carbon::parse($status[$loop->index + 1]['operation_time'])->format('H:i') : (Carbon::now()->format('Y-m-d') == $item->format('Y-m-d') ? Carbon::now()->format('H:i') : '12:00') }}

@endif @if ($key == 0 && ($time['working_status'] == config('const.forwarding_work_time_status_code.arrival') || $time['working_status'] == config('const.forwarding_work_time_status_code.break'))) $time['forwarding_id']]) }}"> @if(Carbon::parse($time['operation_time'])->hour >= 18)

15:00~18:00

@elseif(Carbon::parse($time['operation_time'])->hour < 18 && Carbon::parse($time['operation_time'])->hour >= 15)

15:00~{{ Carbon::parse($time['operation_time'])->format('H:i') }}

@endif
@endif @endforeach @else @foreach ($wrecker_status as $time) $time['wrecker_request_id']]) }}"> @if(Carbon::parse($time['start_time'])->diffInDays($item) == 0 && Carbon::parse($time['start_time'])->hour < 18)

{{ Carbon::parse($time['start_time'])->hour > 15 ? Carbon::parse($time['start_time'])->format('H:i') : '15:00' }}~{{ Carbon::parse($time['end_time'])->hour < 18 ? Carbon::parse($time['end_time'])->format('H:i') : '18:00' }}

@else

15:00~18:00

@endif
@endforeach @endif
データが存在しません。