{{-- ソート用フォーム --}}
{{ $list->appends(['sort'=>$sort,'sort_type'=>$sort_type])->links('pagination') }}
{{-- フラッシュ --}}
@if(Session::has('success'))
@elseif(isset($errorMsg))
@endif
{{ Session::get('success') }}
@elseif(Session::has('error'))
{{ __('誤差') }}:
{!! Session::get('error') !!}{{ __('誤差') }}:
{!! $errorMsg !!}
{{-- 左:チェック列+編集ボタン --}}
{{-- 右:本体 --}}
@php
$TYPE = [1=>'サーバー',2=>'プリンタ',3=>'その他'];
$WORK = ['1'=>'稼働','0'=>'停止',1=>'稼働',0=>'停止'];
@endphp
| {{ __('デバイスID') }} | {{-- 2 駐輪場ID --}}{{ __('駐輪場ID') }} | {{-- 3 デバイス種別--}}{{ __('デバイス種別') }} | {{-- 4 デバイス名 --}}{{ __('デバイス名') }} | {{-- 5 識別子 --}}{{ __('識別子') }} | {{-- 6 稼働/停止 --}}{{ __('稼働/停止') }} | {{-- 7 稼働開始日--}}{{ __('稼働開始日') }} | {{-- 8 リプレース予約日 --}}{{ __('リプレース予約日') }} | {{-- 9 備考 --}}{{ __('備考') }} |
|---|---|---|---|---|---|---|---|---|
| {{ mb_substr($item->device_id, 0, 10) }} | {{-- 2 駐輪場ID:駐輪場名 --}}{{ mb_substr($item->park_id, 0, 10) }} @if($item->relationLoaded('park') && $item->park) : {{ mb_substr($item->park->park_name ?? '', 0, 10) }} @endif | {{-- 3 デバイス種別 --}}{{ mb_substr($TYPE[$item->device_type] ?? (string)$item->device_type, 0, 10) }} | {{-- 4 デバイス名 --}}{{ mb_substr($item->device_subject, 0, 10) }} | {{-- 5 識別子--}}{{ mb_substr($item->device_identifier, 0, 10) }} | {{-- 6 稼働/停止--}}{{ $WORK[$item->device_work] ?? $item->device_work }} | {{-- 7 稼働開始日 --}}@php $ws = $item->device_workstart instanceof \Carbon\Carbon ? $item->device_workstart->format('Y/m/d') : ($item->device_workstart ? \Carbon\Carbon::parse($item->device_workstart)->format('Y/m/d') : ''); @endphp {{ $ws }} | {{-- 8 リプレース予約日) --}}@php $rp = $item->device_replace instanceof \Carbon\Carbon ? $item->device_replace->format('Y/m/d') : ($item->device_replace ? \Carbon\Carbon::parse($item->device_replace)->format('Y/m/d') : ''); @endphp {{ $rp }} | {{-- 9 備考 --}}{{ mb_substr($item->device_remarks, 0, 10) }} |