krgm.so-manager-dev.com/resources/views/admin/opes/list.blade.php
你的名字 e1254515ff
All checks were successful
Deploy preview (main_ou) / deploy (push) Successful in 11s
初回コミット&一部不要なソース削除
2025-08-29 10:52:05 +09:00

132 lines
6.7 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

@extends('layouts.app')
@section('title', '[東京都|〇〇駐輪場] オペレータマスタ')
@section('content')
<div class="content-header">
<div class="container-fluid">
<div class="row mb-2">
<div class="col-lg-6">
<h1 class="m-0 text-dark">{{__('オペレータマスタ')}}</h1>
</div>
<div class="col-lg-6">
<ol class="breadcrumb float-sm-right text-sm">
<li class="breadcrumb-item"><a href="{{route('home')}}">XX様info(ホーム)</a></li>
<li class="breadcrumb-item"><a href="javascript: void(0);">[東京都|〇〇駐輪場]</a></li>
<li class="breadcrumb-item active">{{__('オペレータマスタ')}}</li>
</ol>
</div>
</div>
</div>
</div>
<section class="content">
<div class="container-fluid">
<div class="container-fluid mb20">
<button type="button" class="btn btn-sm btn-primary mr10"
onclick="location.href='{{ route('ope_add') }}'">新規</button>
<button type="submit" class="btn btn-sm btn-danger mr10" form="form_delete" name="delete" id="delete"
onclick="return confirm('選択した項目を削除しますか?');">削除</button>
<form action="{{ route('opes_import') }}" method="post" enctype="multipart/form-data" style="display:inline;" id="import_form">
@csrf
<input type="file" name="import_file" id="import_file" style="display:none;" required>
<button type="button" class="btn btn-sm btn-info mr10" onclick="document.getElementById('import_file').click();">インポート</button>
</form>
<form id="csv_export_form" action="{{ route('opes_export') }}" method="post" style="display:inline;">
@csrf
<button type="submit" class="btn btn-sm btn-success mr10">CSV出力</button>
</form>
</div>
<div style="width:100%; text-align: right;">
{{ $list->appends(['sort' => $sort, 'sort_type' => $sort_type])->links('pagination') }}
</div>
<div class="form col-lg-12">
@if(Session::has('success'))
<div class="alert alert-success alert-dismissible" role="alert">
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
{{ Session::get('success') }}
</div>
@elseif(Session::has('error'))
<div class="alert alert-danger alert-dismissible">
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
<h4><i class="icon fa fa-ban"></i> {{__('誤差')}}:</h4>
{!! Session::get('error') !!}
</div>
@elseif(isset($errorMsg))
<div class="alert alert-danger alert-dismissible">
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
<h4><i class="icon fa fa-ban"></i> {{__('誤差')}}:</h4>
{!! $errorMsg !!}
</div>
@endif
</div>
<form action="{{route('opes_delete')}}" method="post" id="form_delete">
@csrf
<div class="table-responsive text-nowrap">
<table class="table table-bordered table-hover" style="min-width:1800px;">
<thead class="thead-light">
<tr>
<th style="width:160px;">
<input type="checkbox" id="checkbox_all" >
</th>
<th>オペレータID</th>
<th>オペレータ名</th>
<th>オペレータ種別</th>
<th>メールアドレス</th>
<th>電話番号</th>
@for($i=1;$i<=13;$i++)
<th>キュー{{$i}}アラート送信</th>
@endfor
<th>管理者権限付与</th>
<th>エリアマネージャー権限付与</th>
<th>エリアオペレーター権限付与</th>
<th>オペレーター権限付与</th>
<th>退職フラグ</th>
<th>退職日</th>
</tr>
</thead>
<tbody>
@foreach($list as $item)
<tr>
<td style="background:#faebd7;">
<input type="checkbox" name="pk[]" value="{{$item->ope_id}}">
<a href="{{route('ope_info', ['id' => $item->ope_id])}}"
class="btn btn-sm btn-outline-primary ml-2">{{__('編集')}}</a>
</td>
<td>{{ $item->ope_id }}</td>
<td>{{ $item->ope_name }}</td>
<td>{{ \App\Models\Ope::OPE_TYPE[$item->ope_type] ?? $item->ope_type }}</td>
<td>{{ $item->ope_mail }}</td>
<td>{{ $item->ope_phone }}</td>
@for($i=1;$i<=13;$i++)
@php $field = "ope_sendalart_que{$i}"; @endphp
<td>{{ $item->$field ? 'はい' : 'いいえ' }}</td>
@endfor
<td>{{ $item->ope_auth1 ? '○' : '' }}</td>
<td>{{ $item->ope_auth2 ? '○' : '' }}</td>
<td>{{ $item->ope_auth3 ? '○' : '' }}</td>
<td>{{ $item->ope_auth4 ? '○' : '' }}</td>
<td>{{ $item->ope_quit_flag ? "退職" : "在職" }}</td>
<td>{{ $item->ope_quitday }}</td>
</tr>
@endforeach
</tbody>
</table>
</div>
<div class="mt-3" style="text-align:right;">
{{ $list->appends(['sort' => $sort, 'sort_type' => $sort_type])->links('pagination') }}
</div>
</form>
</div>
</section>
<script>
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
document.querySelectorAll('input[name="pk[]"]').forEach(function(el){
el.checked = e.target.checked;
});
});
</script>
@endsection