Merge pull request 'main_kin' (#18) from main_kin into main
All checks were successful
Deploy main / deploy (push) Successful in 21s
All checks were successful
Deploy main / deploy (push) Successful in 21s
Reviewed-on: #18
This commit is contained in:
commit
7e7d478860
151
app/Http/Controllers/Admin/InvSettingController.php
Normal file
151
app/Http/Controllers/Admin/InvSettingController.php
Normal file
@ -0,0 +1,151 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Http\Controllers\Admin;
|
||||||
|
|
||||||
|
use App\Http\Controllers\Controller;
|
||||||
|
use App\Models\InvSetting;
|
||||||
|
use Illuminate\Http\Request;
|
||||||
|
use Illuminate\Support\Facades\Storage;
|
||||||
|
|
||||||
|
class InvSettingController extends Controller
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 登録フォーム表示
|
||||||
|
*/
|
||||||
|
public function form(Request $request)
|
||||||
|
{
|
||||||
|
$row = InvSetting::first();
|
||||||
|
|
||||||
|
$zip1 = $zip2 = $tel1 = $tel2 = $tel3 = $fax1 = $fax2 = $fax3 = '';
|
||||||
|
|
||||||
|
if ($row) {
|
||||||
|
// 郵便番号(そのままハイフン分割)
|
||||||
|
if (!empty($row->zipcode) && str_contains($row->zipcode, '-')) {
|
||||||
|
[$zip1, $zip2] = explode('-', $row->zipcode);
|
||||||
|
}
|
||||||
|
|
||||||
|
// 電話番号:数字以外を除去 → 2桁+4桁+4桁 に分割
|
||||||
|
if (!empty($row->tel_num)) {
|
||||||
|
$tel = preg_replace('/\D/', '', $row->tel_num); // 数字以外を除去
|
||||||
|
$tel1 = substr($tel, 0, 2);
|
||||||
|
$tel2 = substr($tel, 2, 4);
|
||||||
|
$tel3 = substr($tel, 6, 4);
|
||||||
|
}
|
||||||
|
|
||||||
|
// FAX番号:同じく 2桁+4桁+4桁
|
||||||
|
if (!empty($row->fax_num)) {
|
||||||
|
$fax = preg_replace('/\D/', '', $row->fax_num);
|
||||||
|
$fax1 = substr($fax, 0, 2);
|
||||||
|
$fax2 = substr($fax, 2, 4);
|
||||||
|
$fax3 = substr($fax, 6, 4);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return view('admin.invsettings._form', compact(
|
||||||
|
'row', 'zip1', 'zip2', 'tel1', 'tel2', 'tel3', 'fax1', 'fax2', 'fax3'
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 登録・更新処理
|
||||||
|
*/
|
||||||
|
public function save(Request $request)
|
||||||
|
{
|
||||||
|
// バリデーションルール
|
||||||
|
$rules = [
|
||||||
|
't_number' => 'required|string|max:20',
|
||||||
|
't_name' => 'required|string|max:50',
|
||||||
|
'zip1' => 'required|digits:3',
|
||||||
|
'zip2' => 'required|digits:4',
|
||||||
|
'adrs' => 'required|string|max:100',
|
||||||
|
'bldg' => 'nullable|string|max:80',
|
||||||
|
'tel1' => 'nullable|digits_between:2,4',
|
||||||
|
'tel2' => 'nullable|digits_between:2,4',
|
||||||
|
'tel3' => 'nullable|digits_between:3,4',
|
||||||
|
'fax1' => 'nullable|digits_between:2,4',
|
||||||
|
'fax2' => 'nullable|digits_between:2,4',
|
||||||
|
'fax3' => 'nullable|digits_between:3,4',
|
||||||
|
'company_image' => 'nullable|image|mimes:png,jpg,jpeg|max:2048',
|
||||||
|
];
|
||||||
|
|
||||||
|
// カスタム日本語メッセージ
|
||||||
|
$messages = [
|
||||||
|
't_number.required' => '適格請求書発行事業者番号を入力してください。',
|
||||||
|
't_number.max' => '適格請求書発行事業者番号は20文字以内で入力してください。',
|
||||||
|
|
||||||
|
't_name.required' => '適格事業者名を入力してください。',
|
||||||
|
't_name.max' => '適格事業者名は50文字以内で入力してください。',
|
||||||
|
|
||||||
|
'zip1.required' => '郵便番号(前半)を入力してください。',
|
||||||
|
'zip1.digits' => '郵便番号(前半)は3桁で入力してください。',
|
||||||
|
'zip2.required' => '郵便番号(後半)を入力してください。',
|
||||||
|
'zip2.digits' => '郵便番号(後半)は4桁で入力してください。',
|
||||||
|
|
||||||
|
'adrs.required' => '表示住所を入力してください。',
|
||||||
|
'adrs.max' => '表示住所は100文字以内で入力してください。',
|
||||||
|
|
||||||
|
'bldg.max' => '建物名は80文字以内で入力してください。',
|
||||||
|
|
||||||
|
'tel1.digits_between' => '電話番号1は2桁から4桁で入力してください。',
|
||||||
|
'tel2.digits_between' => '電話番号2は2桁から4桁で入力してください。',
|
||||||
|
'tel3.digits_between' => '電話番号3は3桁から4桁で入力してください。',
|
||||||
|
|
||||||
|
'fax1.digits_between' => 'FAX番号1は2桁から4桁で入力してください。',
|
||||||
|
'fax2.digits_between' => 'FAX番号2は2桁から4桁で入力してください。',
|
||||||
|
'fax3.digits_between' => 'FAX番号3は3桁から4桁で入力してください。',
|
||||||
|
|
||||||
|
'company_image.image' => '社判画像は画像ファイルを選択してください。',
|
||||||
|
'company_image.mimes' => '社判画像はpng, jpg, jpeg形式でアップロードしてください。',
|
||||||
|
'company_image.max' => '社判画像は2MB以下にしてください。',
|
||||||
|
];
|
||||||
|
|
||||||
|
// バリデーション実行(カスタムメッセージ適用)
|
||||||
|
$request->validate($rules, $messages);
|
||||||
|
|
||||||
|
// データ整形
|
||||||
|
$zipcode = $request->zip1 . '-' . $request->zip2;
|
||||||
|
$tel = implode('-', array_filter([$request->tel1, $request->tel2, $request->tel3]));
|
||||||
|
$fax = implode('-', array_filter([$request->fax1, $request->fax2, $request->fax3]));
|
||||||
|
|
||||||
|
// 既存レコードを取得(1レコード運用)
|
||||||
|
$row = InvSetting::first();
|
||||||
|
|
||||||
|
// 画像処理
|
||||||
|
$imagePath = $row?->company_image_path;
|
||||||
|
if ($request->hasFile('company_image')) {
|
||||||
|
if ($imagePath && Storage::disk('public')->exists($imagePath)) {
|
||||||
|
Storage::disk('public')->delete($imagePath);
|
||||||
|
}
|
||||||
|
$imagePath = $request->file('company_image')->store('inv', 'public');
|
||||||
|
}
|
||||||
|
|
||||||
|
// レコードを新規作成 or 更新
|
||||||
|
if ($row) {
|
||||||
|
$row->update([
|
||||||
|
't_number' => $request->t_number,
|
||||||
|
't_name' => $request->t_name,
|
||||||
|
'zipcode' => $zipcode,
|
||||||
|
'adrs' => $request->adrs,
|
||||||
|
'bldg' => $request->bldg,
|
||||||
|
'tel_num' => $tel,
|
||||||
|
'fax_num' => $fax,
|
||||||
|
'company_image_path' => $imagePath,
|
||||||
|
]);
|
||||||
|
} else {
|
||||||
|
InvSetting::create([
|
||||||
|
't_number' => $request->t_number,
|
||||||
|
't_name' => $request->t_name,
|
||||||
|
'zipcode' => $zipcode,
|
||||||
|
'adrs' => $request->adrs,
|
||||||
|
'bldg' => $request->bldg,
|
||||||
|
'tel_num' => $tel,
|
||||||
|
'fax_num' => $fax,
|
||||||
|
'company_image_path' => $imagePath,
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
|
||||||
|
return back()->with('success', 'インボイス設定を登録しました。');
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -12,10 +12,15 @@ use Illuminate\Support\Facades\DB;
|
|||||||
class JurisdictionParkingController extends Controller
|
class JurisdictionParkingController extends Controller
|
||||||
{
|
{
|
||||||
public function list(Request $request)
|
public function list(Request $request)
|
||||||
{
|
{
|
||||||
$list = JurisdictionParking::query()->paginate(20);
|
|
||||||
return view('admin.jurisdiction_parkings.list', compact('list'));
|
$sort = $request->input('sort', 'jurisdiction_parking_id');
|
||||||
}
|
$sort_type = $request->input('sort_type', 'asc');
|
||||||
|
|
||||||
|
$list = JurisdictionParking::orderBy($sort, $sort_type)->paginate(20);
|
||||||
|
|
||||||
|
return view('admin.jurisdiction_parkings.list', compact('list', 'sort', 'sort_type'));
|
||||||
|
}
|
||||||
|
|
||||||
public function add(Request $request)
|
public function add(Request $request)
|
||||||
{
|
{
|
||||||
@ -37,9 +42,9 @@ class JurisdictionParkingController extends Controller
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public function edit(Request $request, $jurisdiction_parking_id)
|
public function edit(Request $request, $id)
|
||||||
{
|
{
|
||||||
$record = JurisdictionParking::findOrFail($jurisdiction_parking_id);
|
$record = JurisdictionParking::findOrFail($id);
|
||||||
|
|
||||||
if ($request->isMethod('post')) {
|
if ($request->isMethod('post')) {
|
||||||
$validated = $request->validate([
|
$validated = $request->validate([
|
||||||
@ -59,6 +64,7 @@ class JurisdictionParkingController extends Controller
|
|||||||
return view('admin.jurisdiction_parkings.edit', compact('record', 'parks', 'opes'));
|
return view('admin.jurisdiction_parkings.edit', compact('record', 'parks', 'opes'));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public function delete(Request $request)
|
public function delete(Request $request)
|
||||||
{
|
{
|
||||||
if ($request->has('pk')) {
|
if ($request->has('pk')) {
|
||||||
|
|||||||
124
app/Http/Controllers/Admin/MailTemplateController.php
Normal file
124
app/Http/Controllers/Admin/MailTemplateController.php
Normal file
@ -0,0 +1,124 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Http\Controllers\Admin;
|
||||||
|
|
||||||
|
use App\Http\Controllers\Controller;
|
||||||
|
use Illuminate\Http\Request;
|
||||||
|
use App\Models\MailTemplate;
|
||||||
|
|
||||||
|
class MailTemplateController extends Controller
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 一覧表示
|
||||||
|
*/
|
||||||
|
public function list(Request $request)
|
||||||
|
{
|
||||||
|
if ($request->input('action') === 'reset') {
|
||||||
|
return redirect()->route('mail_templates');
|
||||||
|
}
|
||||||
|
|
||||||
|
$sort = $request->input('sort', 'mail_template_id');
|
||||||
|
$sort_type = $request->input('sort_type', 'desc');
|
||||||
|
|
||||||
|
$query = MailTemplate::query();
|
||||||
|
|
||||||
|
// 絞り込み
|
||||||
|
if ($request->filled('mail_template_id')) {
|
||||||
|
$query->where('mail_template_id', $request->mail_template_id);
|
||||||
|
}
|
||||||
|
if ($request->filled('pg_id')) {
|
||||||
|
$query->where('pg_id', $request->pg_id);
|
||||||
|
}
|
||||||
|
if ($request->has('mgr_cc_flag') && $request->mgr_cc_flag !== '') {
|
||||||
|
$query->where('mgr_cc_flag', $request->mgr_cc_flag);
|
||||||
|
}
|
||||||
|
if ($request->has('use_flag') && $request->use_flag !== '') {
|
||||||
|
$query->where('use_flag', $request->use_flag);
|
||||||
|
}
|
||||||
|
if ($request->filled('subject')) {
|
||||||
|
$query->where('subject', 'LIKE', "%{$request->subject}%");
|
||||||
|
}
|
||||||
|
|
||||||
|
$templates = $query->orderBy($sort, $sort_type)->paginate(20);
|
||||||
|
|
||||||
|
return view('admin.mail_templates.list', compact(
|
||||||
|
'templates', 'sort', 'sort_type'
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新規登録
|
||||||
|
*/
|
||||||
|
public function add(Request $request)
|
||||||
|
{
|
||||||
|
if ($request->isMethod('post')) {
|
||||||
|
$data = $this->validateTemplate($request);
|
||||||
|
MailTemplate::create($data);
|
||||||
|
|
||||||
|
return redirect()->route('mail_templates')
|
||||||
|
->with('success', 'テンプレートを登録しました');
|
||||||
|
}
|
||||||
|
|
||||||
|
$mailTemplate = new MailTemplate();
|
||||||
|
return view('admin.mail_templates.add', compact('mailTemplate'));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 編集
|
||||||
|
*/
|
||||||
|
public function edit($id, Request $request)
|
||||||
|
{
|
||||||
|
$mailTemplate = MailTemplate::findOrFail($id);
|
||||||
|
|
||||||
|
if ($request->isMethod('post')) {
|
||||||
|
$data = $this->validateTemplate($request);
|
||||||
|
$mailTemplate->update($data);
|
||||||
|
|
||||||
|
return redirect()->route('mail_templates')
|
||||||
|
->with('success', 'テンプレートを更新しました');
|
||||||
|
}
|
||||||
|
|
||||||
|
return view('admin.mail_templates.edit', compact('mailTemplate'));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 詳細表示
|
||||||
|
*/
|
||||||
|
public function info($id)
|
||||||
|
{
|
||||||
|
$mailTemplate = MailTemplate::findOrFail($id);
|
||||||
|
|
||||||
|
return view('admin.mail_templates.info', compact('mailTemplate'));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 削除
|
||||||
|
*/
|
||||||
|
public function delete(Request $request)
|
||||||
|
{
|
||||||
|
$id = $request->input('id');
|
||||||
|
if ($id) {
|
||||||
|
MailTemplate::destroy($id);
|
||||||
|
return redirect()->route('mail_templates')->with('success', 'テンプレートを削除しました');
|
||||||
|
}
|
||||||
|
return redirect()->route('mail_templates')->with('error', '削除対象が指定されていません');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* バリデーション共通化
|
||||||
|
*/
|
||||||
|
private function validateTemplate(Request $request)
|
||||||
|
{
|
||||||
|
return $request->validate([
|
||||||
|
'pg_id' => 'nullable|integer',
|
||||||
|
'internal_id' => 'nullable|integer',
|
||||||
|
'mgr_cc_flag' => 'nullable|boolean',
|
||||||
|
'bcc_adrs' => 'nullable|string|max:255',
|
||||||
|
'use_flag' => 'nullable|boolean',
|
||||||
|
'memo' => 'nullable|string|max:255',
|
||||||
|
'subject' => 'required|string|max:255',
|
||||||
|
'text' => 'required|string',
|
||||||
|
'operator_id' => 'nullable|integer',
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -1,119 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
namespace App\Http\Controllers\Admin;
|
|
||||||
|
|
||||||
use App\Http\Controllers\Controller;
|
|
||||||
use Illuminate\Http\Request;
|
|
||||||
use App\Models\NeighborStation;
|
|
||||||
|
|
||||||
class NeighborStationController extends Controller
|
|
||||||
{
|
|
||||||
// 一覧表示
|
|
||||||
public function list(Request $request)
|
|
||||||
{
|
|
||||||
$sort = $request->input('sort', 'station_id');
|
|
||||||
$sort_type = $request->input('sort_type', 'asc');
|
|
||||||
|
|
||||||
$allowedSorts = ['station_id', 'park_id', 'station_neighbor_station', 'station_name_ruby', 'station_route_name'];
|
|
||||||
if (!in_array($sort, $allowedSorts)) {
|
|
||||||
$sort = 'station_id';
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!in_array($sort_type, ['asc', 'desc'])) {
|
|
||||||
$sort_type = 'asc';
|
|
||||||
}
|
|
||||||
|
|
||||||
$stations = NeighborStation::select([
|
|
||||||
'station_id',
|
|
||||||
'station_neighbor_station',
|
|
||||||
'station_name_ruby',
|
|
||||||
'station_route_name',
|
|
||||||
// 'station_latitude',
|
|
||||||
// 'station_longitude',
|
|
||||||
'park_id'
|
|
||||||
])->orderBy($sort, $sort_type)->paginate(20);
|
|
||||||
|
|
||||||
return view('admin.neighbor_stations.list', compact('stations', 'sort', 'sort_type'));
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// 新規登録画面と登録処理
|
|
||||||
public function add(Request $request)
|
|
||||||
{
|
|
||||||
if ($request->isMethod('post')) {
|
|
||||||
$validated = $request->validate([
|
|
||||||
'station_neighbor_station' => 'required|string|max:255',
|
|
||||||
'station_name_ruby' => 'nullable|string|max:255',
|
|
||||||
'station_route_name' => 'nullable|string|max:255',
|
|
||||||
'park_id' => 'nullable|integer',
|
|
||||||
'operator_id' => 'nullable|integer',
|
|
||||||
]);
|
|
||||||
|
|
||||||
NeighborStation::create($validated);
|
|
||||||
return redirect()->route('neighbor_stations')->with('success', '近傍駅が登録されました');
|
|
||||||
}
|
|
||||||
|
|
||||||
return view('admin.neighbor_stations.add');
|
|
||||||
}
|
|
||||||
|
|
||||||
// 編集画面・更新処理
|
|
||||||
public function edit(Request $request, $id)
|
|
||||||
{
|
|
||||||
$station = NeighborStation::findOrFail($id);
|
|
||||||
|
|
||||||
if ($request->isMethod('post')) {
|
|
||||||
$validated = $request->validate([
|
|
||||||
'station_neighbor_station' => 'required|string|max:255',
|
|
||||||
'station_name_ruby' => 'nullable|string|max:255',
|
|
||||||
'station_route_name' => 'nullable|string|max:255',
|
|
||||||
'park_id' => 'nullable|integer',
|
|
||||||
'operator_id' => 'nullable|integer',
|
|
||||||
]);
|
|
||||||
|
|
||||||
$station->update($validated);
|
|
||||||
return redirect()->route('neighbor_stations')->with('success', '更新しました');
|
|
||||||
}
|
|
||||||
|
|
||||||
return view('admin.neighbor_stations.edit', compact('station'));
|
|
||||||
}
|
|
||||||
|
|
||||||
// 詳細表示
|
|
||||||
public function info($id)
|
|
||||||
{
|
|
||||||
$station = NeighborStation::findOrFail($id);
|
|
||||||
return view('admin.neighbor_stations.info', compact('station'));
|
|
||||||
}
|
|
||||||
|
|
||||||
// 削除処理
|
|
||||||
public function delete(Request $request)
|
|
||||||
{
|
|
||||||
$ids = $request->input('pk'); // ← 接收复数 checkbox 名称 pk[]
|
|
||||||
|
|
||||||
if (!empty($ids)) {
|
|
||||||
NeighborStation::destroy($ids); // 一次性删除多个
|
|
||||||
return redirect()->route('neighbor_stations')->with('success', '削除しました');
|
|
||||||
}
|
|
||||||
|
|
||||||
return redirect()->route('neighbor_stations')->with('error', '削除対象が見つかりません');
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// CSVインポート(仮)
|
|
||||||
public function import(Request $request)
|
|
||||||
{
|
|
||||||
// TODO: 実装
|
|
||||||
return redirect()->route('neighbor_stations')->with('info', 'CSVインポートは未実装です');
|
|
||||||
}
|
|
||||||
|
|
||||||
// CSVエクスポート(仮)
|
|
||||||
public function export()
|
|
||||||
{
|
|
||||||
// TODO: 実装
|
|
||||||
return response()->streamDownload(function () {
|
|
||||||
echo "id,station_neighbor_station,station_name_ruby,station_route_name,park_id,operator_id\n";
|
|
||||||
foreach (NeighborStation::all() as $station) {
|
|
||||||
echo "{$station->id},{$station->station_neighbor_station},{$station->station_name_ruby},{$station->station_route_name},{$station->park_id},{$station->operator_id}\n";
|
|
||||||
}
|
|
||||||
}, 'neighbor_stations.csv');
|
|
||||||
}
|
|
||||||
}
|
|
||||||
140
app/Http/Controllers/Admin/StationController.php
Normal file
140
app/Http/Controllers/Admin/StationController.php
Normal file
@ -0,0 +1,140 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Http\Controllers\Admin;
|
||||||
|
|
||||||
|
use App\Http\Controllers\Controller;
|
||||||
|
use Illuminate\Http\Request;
|
||||||
|
use App\Models\Station;
|
||||||
|
|
||||||
|
class StationController extends Controller
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 一覧表示
|
||||||
|
*/
|
||||||
|
public function list(Request $request)
|
||||||
|
{
|
||||||
|
$sort = $request->input('sort', 'station_id');
|
||||||
|
$sort_type = $request->input('sort_type', 'asc');
|
||||||
|
|
||||||
|
// 許可されたソート項目のみ
|
||||||
|
$allowedSorts = [
|
||||||
|
'station_id',
|
||||||
|
'park_id',
|
||||||
|
'station_neighbor_station',
|
||||||
|
'station_name_ruby',
|
||||||
|
'station_route_name'
|
||||||
|
];
|
||||||
|
if (!in_array($sort, $allowedSorts)) {
|
||||||
|
$sort = 'station_id';
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!in_array($sort_type, ['asc', 'desc'])) {
|
||||||
|
$sort_type = 'asc';
|
||||||
|
}
|
||||||
|
|
||||||
|
// 必要カラムのみ取得
|
||||||
|
$stations = Station::select([
|
||||||
|
'station_id',
|
||||||
|
'station_neighbor_station',
|
||||||
|
'station_name_ruby',
|
||||||
|
'station_route_name',
|
||||||
|
'park_id',
|
||||||
|
'operator_id'
|
||||||
|
])->orderBy($sort, $sort_type)->paginate(20);
|
||||||
|
|
||||||
|
return view('admin.stations.list', compact('stations', 'sort', 'sort_type'));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新規登録
|
||||||
|
*/
|
||||||
|
public function add(Request $request)
|
||||||
|
{
|
||||||
|
if ($request->isMethod('post')) {
|
||||||
|
$validated = $request->validate([
|
||||||
|
'station_neighbor_station' => 'required|string|max:255',
|
||||||
|
'station_name_ruby' => 'nullable|string|max:255',
|
||||||
|
'station_route_name' => 'nullable|string|max:255',
|
||||||
|
'park_id' => 'nullable|integer',
|
||||||
|
'operator_id' => 'nullable|integer',
|
||||||
|
]);
|
||||||
|
|
||||||
|
Station::create($validated);
|
||||||
|
return redirect()->route('stations')->with('success', '近傍駅が登録されました');
|
||||||
|
}
|
||||||
|
|
||||||
|
return view('admin.stations.add');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 編集
|
||||||
|
*/
|
||||||
|
public function edit(Request $request, $id)
|
||||||
|
{
|
||||||
|
$station = Station::findOrFail($id);
|
||||||
|
|
||||||
|
if ($request->isMethod('post')) {
|
||||||
|
$validated = $request->validate([
|
||||||
|
'station_neighbor_station' => 'required|string|max:255',
|
||||||
|
'station_name_ruby' => 'nullable|string|max:255',
|
||||||
|
'station_route_name' => 'nullable|string|max:255',
|
||||||
|
'park_id' => 'nullable|integer',
|
||||||
|
'operator_id' => 'nullable|integer',
|
||||||
|
]);
|
||||||
|
|
||||||
|
$station->update($validated);
|
||||||
|
return redirect()->route('stations')->with('success', '更新しました');
|
||||||
|
}
|
||||||
|
|
||||||
|
return view('admin.stations.edit', compact('station'));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 詳細
|
||||||
|
*/
|
||||||
|
public function info($id)
|
||||||
|
{
|
||||||
|
$station = Station::findOrFail($id);
|
||||||
|
return view('admin.stations.info', compact('station'));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 削除
|
||||||
|
*/
|
||||||
|
public function delete(Request $request)
|
||||||
|
{
|
||||||
|
$ids = $request->input('pk'); // 複数ID対応
|
||||||
|
|
||||||
|
if (!empty($ids)) {
|
||||||
|
Station::destroy($ids);
|
||||||
|
return redirect()->route('stations')->with('success', '削除しました');
|
||||||
|
}
|
||||||
|
|
||||||
|
return redirect()->route('stations')->with('error', '削除対象が見つかりません');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* CSVインポート(仮)
|
||||||
|
*/
|
||||||
|
public function import(Request $request)
|
||||||
|
{
|
||||||
|
// TODO: 実装予定
|
||||||
|
return redirect()->route('stations')->with('info', 'CSVインポートは未実装です');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* CSVエクスポート
|
||||||
|
*/
|
||||||
|
public function export()
|
||||||
|
{
|
||||||
|
return response()->streamDownload(function () {
|
||||||
|
// Excel用のUTF-8 BOM
|
||||||
|
echo "\xEF\xBB\xBF";
|
||||||
|
echo "station_id,station_neighbor_station,station_name_ruby,station_route_name,park_id,operator_id\n";
|
||||||
|
|
||||||
|
foreach (Station::all() as $station) {
|
||||||
|
echo "{$station->station_id},{$station->station_neighbor_station},{$station->station_name_ruby},{$station->station_route_name},{$station->park_id},{$station->operator_id}\n";
|
||||||
|
}
|
||||||
|
}, 'stations.csv');
|
||||||
|
}
|
||||||
|
}
|
||||||
130
app/Http/Controllers/Admin/ZoneController.php
Normal file
130
app/Http/Controllers/Admin/ZoneController.php
Normal file
@ -0,0 +1,130 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Http\Controllers\Admin;
|
||||||
|
|
||||||
|
use App\Http\Controllers\Controller;
|
||||||
|
use Illuminate\Http\Request;
|
||||||
|
use App\Models\Zone;
|
||||||
|
|
||||||
|
class ZoneController extends Controller
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 一覧表示(絞り込み対応)
|
||||||
|
*/
|
||||||
|
public function list(Request $request)
|
||||||
|
{
|
||||||
|
if ($request->input('action') === 'reset') {
|
||||||
|
return redirect()->route('zones');
|
||||||
|
}
|
||||||
|
|
||||||
|
// ソート設定
|
||||||
|
$sort = $request->input('sort', 'zone_id');
|
||||||
|
$sort_type = $request->input('sort_type', 'desc');
|
||||||
|
|
||||||
|
// ベースクエリ
|
||||||
|
$query = Zone::query();
|
||||||
|
|
||||||
|
// === 絞り込み条件 ===
|
||||||
|
if ($request->filled('zone_id')) {
|
||||||
|
$query->where('zone_id', $request->zone_id);
|
||||||
|
}
|
||||||
|
if ($request->filled('zone_name')) {
|
||||||
|
$query->where('zone_name', 'LIKE', "%{$request->zone_name}%");
|
||||||
|
}
|
||||||
|
if ($request->filled('park_id')) {
|
||||||
|
$query->where('park_id', $request->park_id);
|
||||||
|
}
|
||||||
|
if ($request->filled('ptype_id')) {
|
||||||
|
$query->where('ptype_id', $request->ptype_id);
|
||||||
|
}
|
||||||
|
if ($request->filled('psection_id')) {
|
||||||
|
$query->where('psection_id', $request->psection_id);
|
||||||
|
}
|
||||||
|
if ($request->has('use_flag') && $request->use_flag !== '') {
|
||||||
|
$query->where('use_flag', $request->use_flag);
|
||||||
|
}
|
||||||
|
|
||||||
|
// ページネーション
|
||||||
|
$zones = $query->orderBy($sort, $sort_type)->paginate(20);
|
||||||
|
|
||||||
|
return view('admin.zones.list', compact(
|
||||||
|
'zones', 'sort', 'sort_type'
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新規登録
|
||||||
|
*/
|
||||||
|
public function add(Request $request)
|
||||||
|
{
|
||||||
|
if ($request->isMethod('post')) {
|
||||||
|
$data = $this->validateZone($request);
|
||||||
|
Zone::create($data);
|
||||||
|
|
||||||
|
return redirect()->route('zones')
|
||||||
|
->with('success', 'ゾーンを登録しました');
|
||||||
|
}
|
||||||
|
|
||||||
|
$zone = new Zone();
|
||||||
|
return view('admin.zones.add', compact('zone'));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 編集
|
||||||
|
*/
|
||||||
|
public function edit($id, Request $request)
|
||||||
|
{
|
||||||
|
$zone = Zone::findOrFail($id);
|
||||||
|
|
||||||
|
if ($request->isMethod('post')) {
|
||||||
|
$data = $this->validateZone($request);
|
||||||
|
$zone->update($data);
|
||||||
|
|
||||||
|
return redirect()->route('zones')
|
||||||
|
->with('success', 'ゾーンを更新しました');
|
||||||
|
}
|
||||||
|
|
||||||
|
return view('admin.zones.edit', compact('zone'));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 詳細表示
|
||||||
|
*/
|
||||||
|
public function info($id)
|
||||||
|
{
|
||||||
|
$zone = Zone::findOrFail($id);
|
||||||
|
|
||||||
|
return view('admin.zones.info', compact('zone'));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 削除
|
||||||
|
*/
|
||||||
|
public function delete(Request $request)
|
||||||
|
{
|
||||||
|
$id = $request->input('id');
|
||||||
|
if ($id) {
|
||||||
|
Zone::destroy($id);
|
||||||
|
return redirect()->route('zones')->with('success', 'ゾーンを削除しました');
|
||||||
|
}
|
||||||
|
return redirect()->route('zones')->with('error', '削除対象が指定されていません');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* バリデーション共通化
|
||||||
|
*/
|
||||||
|
private function validateZone(Request $request)
|
||||||
|
{
|
||||||
|
return $request->validate([
|
||||||
|
'zone_name' => 'required|string|max:50',
|
||||||
|
'park_id' => 'required|integer',
|
||||||
|
'ptype_id' => 'nullable|integer',
|
||||||
|
'psection_id' => 'nullable|integer',
|
||||||
|
'zone_number' => 'nullable|integer|min:0',
|
||||||
|
'zone_standard' => 'nullable|integer|min:0',
|
||||||
|
'zone_tolerance' => 'nullable|integer|min:0',
|
||||||
|
'use_flag' => 'nullable|boolean',
|
||||||
|
'memo' => 'nullable|string|max:255',
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
}
|
||||||
16
app/Models/InvSetting.php
Normal file
16
app/Models/InvSetting.php
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Models;
|
||||||
|
|
||||||
|
use Illuminate\Database\Eloquent\Model;
|
||||||
|
|
||||||
|
class InvSetting extends Model
|
||||||
|
{
|
||||||
|
protected $table = 'inv_setting';
|
||||||
|
protected $primaryKey = 'seq';
|
||||||
|
public $timestamps = true;
|
||||||
|
|
||||||
|
protected $fillable = [
|
||||||
|
't_number', 't_name', 'zipcode', 'adrs', 'bldg', 'tel_num', 'fax_num', 'company_image_path',
|
||||||
|
];
|
||||||
|
}
|
||||||
@ -4,15 +4,11 @@ namespace App\Models;
|
|||||||
|
|
||||||
use Illuminate\Database\Eloquent\Model;
|
use Illuminate\Database\Eloquent\Model;
|
||||||
|
|
||||||
class NeighborStation extends Model
|
class Station extends Model
|
||||||
{
|
{
|
||||||
// テーブル名を指定
|
|
||||||
protected $table = 'station';
|
protected $table = 'station';
|
||||||
|
|
||||||
// 主キーを指定
|
|
||||||
protected $primaryKey = 'station_id';
|
protected $primaryKey = 'station_id';
|
||||||
|
|
||||||
// ホワイトリスト
|
|
||||||
protected $fillable = [
|
protected $fillable = [
|
||||||
'park_id',
|
'park_id',
|
||||||
'station_neighbor_station',
|
'station_neighbor_station',
|
||||||
@ -20,6 +16,4 @@ class NeighborStation extends Model
|
|||||||
'station_route_name',
|
'station_route_name',
|
||||||
'operator_id',
|
'operator_id',
|
||||||
];
|
];
|
||||||
|
|
||||||
// タイムスタンプのカラム名がデフォルトと同じなので、特に設定不要
|
|
||||||
}
|
}
|
||||||
44
app/Models/Zone.php
Normal file
44
app/Models/Zone.php
Normal file
@ -0,0 +1,44 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace App\Models;
|
||||||
|
|
||||||
|
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||||
|
use Illuminate\Database\Eloquent\Model;
|
||||||
|
|
||||||
|
class Zone extends Model
|
||||||
|
{
|
||||||
|
use HasFactory;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* テーブル名
|
||||||
|
*/
|
||||||
|
protected $table = 'zone';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 主キー
|
||||||
|
*/
|
||||||
|
protected $primaryKey = 'zone_id';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* タイムスタンプを有効化
|
||||||
|
*/
|
||||||
|
public $timestamps = true;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 一括代入可能なカラム
|
||||||
|
*/
|
||||||
|
protected $fillable = [
|
||||||
|
'park_id',
|
||||||
|
'ptype_id',
|
||||||
|
'psection_id',
|
||||||
|
'zone_name',
|
||||||
|
'zone_number',
|
||||||
|
'zone_standard',
|
||||||
|
'zone_tolerance',
|
||||||
|
'zone_sort',
|
||||||
|
'delete_flag',
|
||||||
|
'ope_id',
|
||||||
|
'created_at',
|
||||||
|
'updated_at',
|
||||||
|
];
|
||||||
|
}
|
||||||
@ -21,7 +21,7 @@
|
|||||||
|
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<form method="post" action="{{ route('contract_allowable_cities_edit', ['contract_allowable_city_id' => $record->contract_allowable_city_id]) }}">
|
<form method="post" action="{{ route('contract_allowable_cities_edit', ['id' => $record->contract_allowable_city_id]) }}">
|
||||||
@csrf
|
@csrf
|
||||||
<div class="card p-4">
|
<div class="card p-4">
|
||||||
{{-- 契約許容市区マスタID --}}
|
{{-- 契約許容市区マスタID --}}
|
||||||
|
|||||||
@ -2,6 +2,7 @@
|
|||||||
@section('title', '[東京都|〇〇駐輪場] 契約許容市区マスタ')
|
@section('title', '[東京都|〇〇駐輪場] 契約許容市区マスタ')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
|
<!-- Content Header -->
|
||||||
<div class="content-header">
|
<div class="content-header">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row mb-2">
|
<div class="row mb-2">
|
||||||
@ -10,8 +11,8 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<ol class="breadcrumb float-sm-right text-sm">
|
||||||
<li class="breadcrumb-item"><a href="{{route('home')}}">ホーム</a></li>
|
<li class="breadcrumb-item"><a href="{{ route('home') }}">ホーム</a></li>
|
||||||
<li class="breadcrumb-item"><a href="#">[東京都|〇〇駐輪場]</a></li>
|
<li class="breadcrumb-item"><a href="javascript:void(0);">[東京都|〇〇駐輪場]</a></li>
|
||||||
<li class="breadcrumb-item active">契約許容市区マスタ</li>
|
<li class="breadcrumb-item active">契約許容市区マスタ</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
@ -19,10 +20,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Main Content -->
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row">
|
<!-- ▼ 検索条件(ここはそのまま保持) -->
|
||||||
<!-- 検索条件 -->
|
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<div class="card-header"><h3 class="card-title">絞り込み</h3></div>
|
<div class="card-header"><h3 class="card-title">絞り込み</h3></div>
|
||||||
@ -71,80 +72,62 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- ▲ 検索条件ここまで -->
|
||||||
|
|
||||||
<!-- ボタン・ページネーション -->
|
<!-- ▼ ボタン + ページネーション -->
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20">
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('contract_allowable_cities_add') }}'">新規</button>
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('contract_allowable_cities_add') }}'">新規</button>
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" id="export_csv"
|
<button type="button" class="btn btn-sm btn-default mr10" id="export_csv"
|
||||||
action="{{ route('contract_allowable_cities_export') }}">CSV出力</button>
|
action="{{ route('contract_allowable_cities_export') }}">CSV出力</button>
|
||||||
{{ $list->appends(['sort' => $sort,'sort_type'=>$sort_type])->links('pagination') }}
|
<div class="d-flex justify-content-end">
|
||||||
|
{{ $list->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- 一覧テーブル -->
|
<!-- ▼ 単一テーブル構成 -->
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<div class="col-lg-12 mb20">
|
||||||
<!-- チェックボックス側 -->
|
<div class="table-responsive">
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 table_left">
|
|
||||||
<form method="post" action="{{ route('contract_allowable_cities_delete') }}" id="form_delete">
|
<form method="post" action="{{ route('contract_allowable_cities_delete') }}" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th><input type="checkbox" class="minimal m-0" id="checkbox_all"></th>
|
<th style="width:120px;" class="text-left">
|
||||||
</tr>
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($list as $item)
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
<div class="d-flex align-items-center">
|
|
||||||
<input type="checkbox" class="minimal m-0 checkbox"
|
|
||||||
value="{{ $item->contract_allowable_city_id }}" name="id[]">
|
|
||||||
<div class="btn_action ml-2">
|
|
||||||
<a href="{{ route('contract_allowable_cities_edit', ['contract_allowable_city_id' => $item->contract_allowable_city_id]) }}"
|
|
||||||
class="btn btn-sm btn-default">編集</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- テーブル本体 -->
|
|
||||||
<div class="col-xl-10 col-lg-10 col-md-10 col-sm-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th class="sorting @if($sort=="contract_allowable_city_id"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif" sort="contract_allowable_city_id">
|
|
||||||
<span>契約許容市区ID</span>
|
|
||||||
</th>
|
</th>
|
||||||
<th><span>市区ID</span></th>
|
<th class="sorting {{ ($sort=='contract_allowable_city_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="contract_allowable_city_id"><span>契約許容市区ID</span></th>
|
||||||
<th><span>許容市区名</span></th>
|
<th class="sorting {{ ($sort=='city_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="city_id"><span>市区ID</span></th>
|
||||||
<th><span>駐輪場ID</span></th>
|
<th class="sorting {{ ($sort=='contract_allowable_city_name') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="contract_allowable_city_name"><span>許容市区名</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='park_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="park_id"><span>駐輪場ID</span></th>
|
||||||
<th><span>隣接区フラグ</span></th>
|
<th><span>隣接区フラグ</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@foreach($list as $item)
|
@foreach($list as $item)
|
||||||
<tr>
|
<tr>
|
||||||
<td class="sm-item text-left"><span>{{ $item->contract_allowable_city_id }}</span></td>
|
<td class="table-warning align-middle">
|
||||||
<td class="sm-item text-left"><span>{{ $item->city_id }}</span></td>
|
<div class="d-flex align-items-center">
|
||||||
<td class="sm-item text-left"><span>{{ $item->contract_allowable_city_name }}</span></td>
|
<input type="checkbox" class="minimal m-0 checkbox"
|
||||||
<td class="sm-item text-left"><span>{{ $item->park_id }}</span></td>
|
value="{{ $item->contract_allowable_city_id }}" name="id[]">
|
||||||
<td class="sm-item text-left"><span>{{ $item->same_district_flag == 0 ? '隣接市' : 'その他' }}</span></td>
|
<a href="{{ route('contract_allowable_cities_edit', ['id' => $item->contract_allowable_city_id]) }}"
|
||||||
|
class="btn btn-sm btn-default ml-2">{{ __('編集') }}</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->contract_allowable_city_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->city_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->contract_allowable_city_name }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->park_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->same_district_flag == 0 ? '隣接市' : 'その他' }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- ▲ 単一テーブル構成ここまで -->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
|||||||
@ -27,12 +27,16 @@
|
|||||||
<input type="hidden" name="sort_type" id="sort_type" value="{{ $sort_type }}">
|
<input type="hidden" name="sort_type" id="sort_type" value="{{ $sort_type }}">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<div class="container-fluid mb20">
|
<!-- ツールバー -->
|
||||||
|
<div class="container-fluid mb20 d-flex justify-content-between align-items-center">
|
||||||
|
<div>
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('devices_add') }}'">{{ __('新規') }}</button>
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('devices_add') }}'">{{ __('新規') }}</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" form="form_delete">{{ __('削除') }}</button>
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">{{ __('削除') }}</button>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
{{ $list->appends(['sort'=>$sort,'sort_type'=>$sort_type])->links('pagination') }}
|
{{ $list->appends(['sort'=>$sort,'sort_type'=>$sort_type])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
{{-- フラッシュ --}}
|
{{-- フラッシュ --}}
|
||||||
<div class="form col-lg-12">
|
<div class="form col-lg-12">
|
||||||
@ -56,140 +60,66 @@
|
|||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
{{-- 単一テーブル --}}
|
||||||
{{-- 左:チェック列+編集ボタン --}}
|
<div class="col-lg-12 mb20">
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<div class="table-responsive">
|
||||||
<form action="{{ route('devices_delete') }}" method="post" id="form_delete">
|
<form action="{{ route('devices_delete') }}" method="post" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
@php
|
||||||
|
$TYPE = [1=>'サーバー', 2=>'プリンタ', 3=>'その他'];
|
||||||
|
$WORK = ['1'=>'稼働', '0'=>'停止', 1=>'稼働', 0=>'停止'];
|
||||||
|
@endphp
|
||||||
|
|
||||||
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
<thead>
|
||||||
<tr><th><input type="checkbox" class="minimal m-0" id="checkbox_all"></th></tr>
|
<tr>
|
||||||
|
<th style="width:120px;" class="text-left">
|
||||||
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
|
</th>
|
||||||
|
<th class="sorting @if($sort=='device_id'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-right"
|
||||||
|
sort="device_id"><span>{{ __('デバイスID') }}</span></th>
|
||||||
|
<th class="sorting @if($sort=='park_id'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-left"
|
||||||
|
sort="park_id"><span>{{ __('駐輪場ID') }}</span></th>
|
||||||
|
<th class="sorting @if($sort=='device_type'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-left"
|
||||||
|
sort="device_type"><span>{{ __('デバイス種別') }}</span></th>
|
||||||
|
<th class="text-left"><span>{{ __('デバイス名') }}</span></th>
|
||||||
|
<th class="text-left"><span>{{ __('識別子') }}</span></th>
|
||||||
|
<th class="text-left"><span>{{ __('稼働/停止') }}</span></th>
|
||||||
|
<th class="sorting @if($sort=='device_workstart'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-right"
|
||||||
|
sort="device_workstart"><span>{{ __('稼働開始日') }}</span></th>
|
||||||
|
<th class="sorting @if($sort=='device_replace'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-right"
|
||||||
|
sort="device_replace"><span>{{ __('リプレース予約日') }}</span></th>
|
||||||
|
<th class="text-left"><span>{{ __('備考') }}</span></th>
|
||||||
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@foreach($list as $item)
|
@foreach($list as $item)
|
||||||
<tr role="row">
|
<tr>
|
||||||
<td>
|
<td class="table-warning align-middle">
|
||||||
|
<div class="d-flex align-items-center">
|
||||||
<input type="checkbox" class="minimal m-0 checkbox" name="ids[]" value="{{ $item->device_id }}">
|
<input type="checkbox" class="minimal m-0 checkbox" name="ids[]" value="{{ $item->device_id }}">
|
||||||
<div class="btn_action">
|
<a href="{{ route('devices_edit',['id'=>$item->device_id]) }}" class="btn btn-sm btn-default ml-2">{{ __('編集') }}</a>
|
||||||
<a href="{{ route('devices_edit',['id'=>$item->device_id]) }}" class="btn btn-sm btn-default ml10">{{ __('編集') }}</a>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
<td class="sm-item text-right">{{ $item->device_id }}</td>
|
||||||
|
<td class="sm-item text-left">
|
||||||
|
{{ $item->park_id }}
|
||||||
|
@if($item->relationLoaded('park') && $item->park)
|
||||||
|
: {{ $item->park->park_name ?? '' }}
|
||||||
|
@endif
|
||||||
|
</td>
|
||||||
|
<td class="sm-item text-left">{{ $TYPE[$item->device_type] ?? $item->device_type }}</td>
|
||||||
|
<td class="sm-item text-left">{{ $item->device_subject }}</td>
|
||||||
|
<td class="sm-item text-left">{{ $item->device_identifier }}</td>
|
||||||
|
<td class="sm-item text-left">{{ $WORK[$item->device_work] ?? $item->device_work }}</td>
|
||||||
|
<td class="sm-item text-right">{{ optional($item->device_workstart)->format('Y/m/d') }}</td>
|
||||||
|
<td class="sm-item text-right">{{ optional($item->device_replace)->format('Y/m/d') }}</td>
|
||||||
|
<td class="sm-item text-left">{{ $item->device_remarks }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<form id="form_import_export" method="post" enctype="multipart/form-data">@csrf</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
{{-- 右:本体 --}}
|
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
@php
|
|
||||||
$TYPE = [1=>'サーバー',2=>'プリンタ',3=>'その他'];
|
|
||||||
$WORK = ['1'=>'稼働','0'=>'停止',1=>'稼働',0=>'停止'];
|
|
||||||
@endphp
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
{{-- 1 デバイスID--}}
|
|
||||||
<th class="sorting @if($sort=='device_id'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-right"
|
|
||||||
sort="device_id"><span>{{ __('デバイスID') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 2 駐輪場ID --}}
|
|
||||||
<th class="sorting @if($sort=='park_id'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-left"
|
|
||||||
sort="park_id"><span>{{ __('駐輪場ID') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 3 デバイス種別--}}
|
|
||||||
<th class="sorting @if($sort=='device_type'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-left"
|
|
||||||
sort="device_type"><span>{{ __('デバイス種別') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 4 デバイス名 --}}
|
|
||||||
<th class="text-left"><span>{{ __('デバイス名') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 5 識別子 --}}
|
|
||||||
<th class="text-left"><span>{{ __('識別子') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 6 稼働/停止 --}}
|
|
||||||
<th class="text-left"><span>{{ __('稼働/停止') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 7 稼働開始日--}}
|
|
||||||
<th class="sorting @if($sort=='device_workstart'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-right"
|
|
||||||
sort="device_workstart"><span>{{ __('稼働開始日') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 8 リプレース予約日 --}}
|
|
||||||
<th class="sorting @if($sort=='device_replace'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-right"
|
|
||||||
sort="device_replace"><span>{{ __('リプレース予約日') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 9 備考 --}}
|
|
||||||
<th class="text-left"><span>{{ __('備考') }}</span></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
|
|
||||||
<tbody>
|
|
||||||
@foreach($list as $item)
|
|
||||||
<tr>
|
|
||||||
{{-- 1 デバイスID) --}}
|
|
||||||
<td class="sm-item text-right">
|
|
||||||
<span>{{ mb_substr($item->device_id, 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
{{-- 2 駐輪場ID:駐輪場名 --}}
|
|
||||||
<td class="sm-item text-left">
|
|
||||||
<span>
|
|
||||||
{{ mb_substr($item->park_id, 0, 10) }}
|
|
||||||
@if($item->relationLoaded('park') && $item->park)
|
|
||||||
: {{ mb_substr($item->park->park_name ?? '', 0, 10) }}
|
|
||||||
@endif
|
|
||||||
</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
{{-- 3 デバイス種別 --}}
|
|
||||||
<td class="sm-item text-left">
|
|
||||||
<span>{{ mb_substr($TYPE[$item->device_type] ?? (string)$item->device_type, 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
{{-- 4 デバイス名 --}}
|
|
||||||
<td class="sm-item text-left">
|
|
||||||
<span>{{ mb_substr($item->device_subject, 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
{{-- 5 識別子--}}
|
|
||||||
<td class="sm-item text-left">
|
|
||||||
<span>{{ mb_substr($item->device_identifier, 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
{{-- 6 稼働/停止--}}
|
|
||||||
<td class="sm-item text-left">
|
|
||||||
<span>{{ $WORK[$item->device_work] ?? $item->device_work }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
{{-- 7 稼働開始日 --}}
|
|
||||||
<td class="sm-item text-right">
|
|
||||||
@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
|
|
||||||
<span>{{ $ws }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
{{-- 8 リプレース予約日) --}}
|
|
||||||
<td class="sm-item text-right">
|
|
||||||
@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
|
|
||||||
<span>{{ $rp }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
{{-- 9 備考 --}}
|
|
||||||
<td class="sm-item text-left">
|
|
||||||
<span>{{ mb_substr($item->device_remarks, 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -198,21 +128,39 @@
|
|||||||
|
|
||||||
@push('scripts')
|
@push('scripts')
|
||||||
<script>
|
<script>
|
||||||
document.querySelectorAll('th.sorting[sort]').forEach(function(th){
|
// ソート
|
||||||
th.style.cursor = 'pointer';
|
document.querySelectorAll('th.sorting').forEach(th => {
|
||||||
th.addEventListener('click', function(){
|
th.addEventListener('click', function() {
|
||||||
var field = this.getAttribute('sort');
|
const form = document.getElementById('list-form');
|
||||||
var cur = document.getElementById('sort').value;
|
const current = "{{ $sort ?? '' }}";
|
||||||
var type = document.getElementById('sort_type').value || 'asc';
|
const currentType = "{{ $sort_type ?? '' }}";
|
||||||
var next = (cur === field && type === 'asc') ? 'desc' : 'asc';
|
const nextCol = this.getAttribute('sort');
|
||||||
document.getElementById('sort').value = field;
|
let nextType = 'asc';
|
||||||
document.getElementById('sort_type').value = next;
|
if (current === nextCol) {
|
||||||
document.getElementById('list-form').submit();
|
nextType = (currentType === 'asc') ? 'desc' : 'asc';
|
||||||
|
}
|
||||||
|
form.querySelector('[name=sort]').value = nextCol;
|
||||||
|
form.querySelector('[name=sort_type]').value = nextType;
|
||||||
|
form.submit();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
|
// 全選択
|
||||||
|
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
|
||||||
|
document.querySelectorAll('.checkbox').forEach(cb => cb.checked = e.target.checked);
|
||||||
|
});
|
||||||
|
|
||||||
|
// 削除確認
|
||||||
|
document.getElementById('delete')?.addEventListener('click', function(){
|
||||||
|
const anyChecked = Array.from(document.querySelectorAll('.checkbox')).some(cb => cb.checked);
|
||||||
|
if (!anyChecked) {
|
||||||
|
alert('削除対象が選択されていません。');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (confirm('削除してよろしいですか?')) {
|
||||||
|
document.getElementById('form_delete').submit();
|
||||||
|
}
|
||||||
});
|
});
|
||||||
});
|
|
||||||
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
|
|
||||||
document.querySelectorAll('.checkbox').forEach(function(cb){ cb.checked = e.target.checked; });
|
|
||||||
});
|
|
||||||
</script>
|
</script>
|
||||||
@endpush
|
@endpush
|
||||||
@endsection
|
@endsection
|
||||||
|
|||||||
124
resources/views/admin/invsettings/_form.blade.php
Normal file
124
resources/views/admin/invsettings/_form.blade.php
Normal file
@ -0,0 +1,124 @@
|
|||||||
|
@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>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<section class="content">
|
||||||
|
<div class="container-fluid">
|
||||||
|
@if(session('success'))
|
||||||
|
<div class="alert alert-success">{{ session('success') }}</div>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
@if ($errors->any())
|
||||||
|
<div class="alert alert-danger">
|
||||||
|
<ul>
|
||||||
|
@foreach ($errors->all() as $e)<li>{{ $e }}</li>@endforeach
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
<form method="post" action="{{ route('inv_settings_save') }}" enctype="multipart/form-data">
|
||||||
|
@csrf
|
||||||
|
|
||||||
|
{{-- 適格請求書発行事業者番号 --}}
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-sm-3 col-form-label">適格請求書発行事業者番号<span class="text-danger">*</span></label>
|
||||||
|
<div class="form-group col-4">
|
||||||
|
<input type="text" name="t_number" class="form-control"
|
||||||
|
value="{{ old('t_number', $row->t_number ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- 適格事業者名 --}}
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-sm-3 col-form-label">適格事業者名<span class="text-danger">*</span></label>
|
||||||
|
<div class="form-group col-4">
|
||||||
|
<input type="text" name="t_name" class="form-control"
|
||||||
|
value="{{ old('t_name', $row->t_name ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- 郵便番号 --}}
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-sm-3 col-form-label">郵便番号</label>
|
||||||
|
<div class="col-sm-9 d-flex">
|
||||||
|
<input type="text" name="zip1" class="form-control" style="max-width:120px;"
|
||||||
|
value="{{ old('zip1', $zip1) }}">
|
||||||
|
<span class="mx-2">-</span>
|
||||||
|
<input type="text" name="zip2" class="form-control" style="max-width:140px;"
|
||||||
|
value="{{ old('zip2', $zip2) }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- 表示住所 --}}
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-sm-3 col-form-label">表示住所<span class="text-danger">*</span></label>
|
||||||
|
<div class="form-group col-4">
|
||||||
|
<input type="text" name="adrs" class="form-control"
|
||||||
|
value="{{ old('adrs', $row->adrs ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- 建物名 --}}
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-sm-3 col-form-label">建物名</label>
|
||||||
|
<div class="form-group col-4">
|
||||||
|
<input type="text" name="bldg" class="form-control"
|
||||||
|
value="{{ old('bldg', $row->bldg ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- 表示電話番号 --}}
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-sm-3 col-form-label">表示電話番号</label>
|
||||||
|
<div class="col-sm-9 d-flex">
|
||||||
|
<input name="tel1" class="form-control" style="max-width:100px;" value="{{ old('tel1', $tel1) }}">
|
||||||
|
<span class="mx-2">-</span>
|
||||||
|
<input name="tel2" class="form-control" style="max-width:100px;" value="{{ old('tel2', $tel2) }}">
|
||||||
|
<span class="mx-2">-</span>
|
||||||
|
<input name="tel3" class="form-control" style="max-width:100px;" value="{{ old('tel3', $tel3) }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- 表示FAX番号 --}}
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-sm-3 col-form-label">表示FAX番号</label>
|
||||||
|
<div class="col-sm-9 d-flex">
|
||||||
|
<input name="fax1" class="form-control" style="max-width:100px;" value="{{ old('fax1', $fax1) }}">
|
||||||
|
<span class="mx-2">-</span>
|
||||||
|
<input name="fax2" class="form-control" style="max-width:100px;" value="{{ old('fax2', $fax2) }}">
|
||||||
|
<span class="mx-2">-</span>
|
||||||
|
<input name="fax3" class="form-control" style="max-width:100px;" value="{{ old('fax3', $fax3) }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- 社判画像 --}}
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-sm-3 col-form-label">社判画像</label>
|
||||||
|
<div class="col-sm-9">
|
||||||
|
<input type="file" name="company_image" class="form-control-file">
|
||||||
|
@if(!empty($row->company_image_path))
|
||||||
|
<div class="mt-2">
|
||||||
|
<a href="{{ asset('storage/'.$row->company_image_path) }}" target="_blank">現在の画像を表示</a>
|
||||||
|
</div>
|
||||||
|
@endif
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- 登録ボタン --}}
|
||||||
|
<div class="form-group row">
|
||||||
|
<div class="col-sm-3">
|
||||||
|
<button type="submit" class="btn btn-success px-3">登録</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
@endsection
|
||||||
@ -21,7 +21,7 @@
|
|||||||
|
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<form method="post" action="{{ route('jurisdiction_parkings_edit', ['jurisdiction_parking_id' => $record->jurisdiction_parking_id]) }}">
|
<form method="post" action="{{ route('jurisdiction_parkings_edit', ['id' => $record->jurisdiction_parking_id]) }}">
|
||||||
@csrf
|
@csrf
|
||||||
<div class="card p-4">
|
<div class="card p-4">
|
||||||
{{-- 管轄駐輪場ID(表示のみ) --}}
|
{{-- 管轄駐輪場ID(表示のみ) --}}
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
@extends('layouts.app')
|
@extends('layouts.app')
|
||||||
@section('title', '[東京都|○○駐車場] 管轄駐輪場')
|
@section('title', '[東京都|〇〇駐輪場] 管轄駐輪場マスタ')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<!-- Content Header -->
|
<!-- Content Header -->
|
||||||
@ -12,28 +12,36 @@
|
|||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<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="{{ route('home') }}">XX様info(ホーム)</a></li>
|
||||||
<li class="breadcrumb-item active">管轄駐輪場</li>
|
<li class="breadcrumb-item"><a href="javascript:void(0);">[東京都|〇〇駐輪場]</a></li>
|
||||||
|
<li class="breadcrumb-item active">管轄駐輪場マスタ</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Main Content -->
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
|
{{-- 並び替え用 hidden --}}
|
||||||
<form action="{{ route('jurisdiction_parkings') }}" method="POST" id="list-form">
|
<form action="{{ route('jurisdiction_parkings') }}" method="POST" id="list-form">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20 d-flex justify-content-between">
|
||||||
|
<div>
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('jurisdiction_parkings_add') }}'">新規</button>
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('jurisdiction_parkings_add') }}'">新規</button>
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">CSV出力</button>
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">{{ __('CSV出力') }}</button>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
{{ $list->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
{{ $list->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 成功 / 失敗 メッセージ -->
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
@if(session('success'))
|
@if(session('success'))
|
||||||
<div class="alert alert-success alert-dismissible">{{ session('success') }}</div>
|
<div class="alert alert-success alert-dismissible">{{ session('success') }}</div>
|
||||||
@ -42,41 +50,20 @@
|
|||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<!-- ▼ 単一テーブル構成 ----------------------------------------- -->
|
||||||
<!-- 左側チェックボックス -->
|
<div class="col-lg-12 mb20">
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<div class="table-responsive">
|
||||||
<form action="{{ route('jurisdiction_parkings_delete') }}" method="POST" id="form_delete">
|
<form action="{{ route('jurisdiction_parkings_delete') }}" method="POST" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th><input type="checkbox" class="minimal m-0" id="checkbox_all"></th>
|
{{-- ★ チェック + 編集 用の1列 --}}
|
||||||
</tr>
|
<th style="width:120px;" class="text-left">
|
||||||
</thead>
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
<tbody>
|
</th>
|
||||||
@foreach($list as $item)
|
<th class="sorting {{ ($sort=='jurisdiction_parking_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="jurisdiction_parking_id"><span>管轄駐輪場ID</span></th>
|
||||||
<tr>
|
<th class="sorting {{ ($sort=='jurisdiction_parking_name') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="jurisdiction_parking_name"><span>管轄名</span></th>
|
||||||
<td>
|
|
||||||
<input type="checkbox" class="minimal m-0 checkbox" value="{{ $item->jurisdiction_parking_id }}" name="pk[]">
|
|
||||||
<div class="btn_action">
|
|
||||||
<a href="{{ route('jurisdiction_parkings_edit', ['jurisdiction_parking_id' => $item->jurisdiction_parking_id]) }}" class="btn btn-sm btn-default ml10">編集</a>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- 右側データテーブル -->
|
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th><span>管轄駐輪場ID</span></th>
|
|
||||||
<th><span>管轄名</span></th>
|
|
||||||
<th><span>オペレーター(エリアマネージャ)</span></th>
|
<th><span>オペレーター(エリアマネージャ)</span></th>
|
||||||
<th><span>駐車場</span></th>
|
<th><span>駐車場</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
@ -84,17 +71,27 @@
|
|||||||
<tbody>
|
<tbody>
|
||||||
@foreach($list as $item)
|
@foreach($list as $item)
|
||||||
<tr>
|
<tr>
|
||||||
<td class="sm-item text-left">{{ $item->jurisdiction_parking_id }}</td>
|
{{-- ★ チェック + 編集ボタン --}}
|
||||||
<td class="sm-item text-left">{{ $item->jurisdiction_parking_name }}</td>
|
<td class="table-warning align-middle">
|
||||||
<td class="sm-item text-left">{{ $item->ope->ope_name ?? '' }}</td>
|
<div class="d-flex align-items-center">
|
||||||
<td class="sm-item text-left">{{ $item->park->park_name ?? '' }}</td>
|
<input type="checkbox" class="minimal m-0 checkbox" name="pk[]" value="{{ $item->jurisdiction_parking_id }}">
|
||||||
|
<a href="{{ route('jurisdiction_parkings_edit', ['id' => $item->jurisdiction_parking_id]) }}"
|
||||||
|
class="btn btn-sm btn-default ml-2">{{ __('編集') }}</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->jurisdiction_parking_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->jurisdiction_parking_name }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope->ope_name ?? '' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->park->park_name ?? '' }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<!-- ▲ 単一テーブル構成ここまで ----------------------------------------- -->
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
|
|||||||
144
resources/views/admin/mail_templates/_form.blade.php
Normal file
144
resources/views/admin/mail_templates/_form.blade.php
Normal file
@ -0,0 +1,144 @@
|
|||||||
|
@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>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
<div class="card-header">
|
||||||
|
@if($isInfo)
|
||||||
|
<a href="{{ route('mail_templates_add') }}" class="btn btn-lg btn-success">登録</a>
|
||||||
|
<a href="{{ route('mail_templates_edit', ['id' => $mailTemplate->mail_template_id]) }}" class="btn btn-lg btn-danger">編集</a>
|
||||||
|
@else
|
||||||
|
<button type="submit" class="btn btn-lg btn-danger register">保存</button>
|
||||||
|
@endif
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="card-body">
|
||||||
|
<div class="row">
|
||||||
|
{{-- 編集・詳細時のみテンプレートID表示 --}}
|
||||||
|
@if($isEdit || $isInfo)
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label>テンプレートID</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9">
|
||||||
|
<input type="text" value="{{ $mailTemplate->mail_template_id ?? '' }}" class="form-control form-control-lg" readonly />
|
||||||
|
</div>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
<!-- 使用プログラムID -->
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label class="required">使用プログラムID</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9">
|
||||||
|
<input type="number" name="pg_id" value="{{ old('pg_id', $mailTemplate->pg_id ?? '') }}"
|
||||||
|
class="form-control form-control-lg" @if($isInfo) readonly @endif required />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 内部ID -->
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label>内部ID</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9">
|
||||||
|
<input type="number" name="internal_id" value="{{ old('internal_id', $mailTemplate->internal_id ?? '') }}"
|
||||||
|
class="form-control form-control-lg" @if($isInfo) readonly @endif />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- エリアマネージャー同報 -->
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label>エリアマネージャー同報</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9 mt-2">
|
||||||
|
<div class="form-check form-check-inline">
|
||||||
|
<input class="form-check-input" type="radio" name="mgr_cc_flag" value="1"
|
||||||
|
@if(old('mgr_cc_flag', $mailTemplate->mgr_cc_flag ?? '') == 1) checked @endif
|
||||||
|
@if($isInfo) disabled @endif>
|
||||||
|
<label class="form-check-label">同報する</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-check form-check-inline">
|
||||||
|
<input class="form-check-input" type="radio" name="mgr_cc_flag" value="0"
|
||||||
|
@if(old('mgr_cc_flag', $mailTemplate->mgr_cc_flag ?? '') == 0) checked @endif
|
||||||
|
@if($isInfo) disabled @endif>
|
||||||
|
<label class="form-check-label">同報しない</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- BCCアドレス -->
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label>BCCアドレス</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9">
|
||||||
|
<input type="text" name="bcc_adrs" value="{{ old('bcc_adrs', $mailTemplate->bcc_adrs ?? '') }}"
|
||||||
|
class="form-control form-control-lg" @if($isInfo) readonly @endif />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 使用フラグ -->
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label>使用フラグ</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9 mt-2">
|
||||||
|
<div class="form-check form-check-inline">
|
||||||
|
<input class="form-check-input" type="radio" name="use_flag" value="1"
|
||||||
|
@if(old('use_flag', $mailTemplate->use_flag ?? '') == 1) checked @endif
|
||||||
|
@if($isInfo) disabled @endif>
|
||||||
|
<label class="form-check-label">使用する</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-check form-check-inline">
|
||||||
|
<input class="form-check-input" type="radio" name="use_flag" value="0"
|
||||||
|
@if(old('use_flag', $mailTemplate->use_flag ?? '') == 0) checked @endif
|
||||||
|
@if($isInfo) disabled @endif>
|
||||||
|
<label class="form-check-label">使用しない</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- メモ -->
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label>メモ</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9">
|
||||||
|
<input type="text" name="memo" value="{{ old('memo', $mailTemplate->memo ?? '') }}"
|
||||||
|
class="form-control form-control-lg" @if($isInfo) readonly @endif />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 件名 -->
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label class="required">件名</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9">
|
||||||
|
<input type="text" name="subject" value="{{ old('subject', $mailTemplate->subject ?? '') }}"
|
||||||
|
class="form-control form-control-lg" @if($isInfo) readonly @endif required />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 本文 -->
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label class="required">本文</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9">
|
||||||
|
<textarea name="text" class="form-control form-control-lg" rows="8"
|
||||||
|
@if($isInfo) readonly @endif required>{{ old('text', $mailTemplate->text ?? '') }}</textarea>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- オペレータID -->
|
||||||
|
<div class="form-group col-3">
|
||||||
|
<label>オペレータID</label>
|
||||||
|
</div>
|
||||||
|
<div class="form-group col-9">
|
||||||
|
<input type="number" name="operator_id" value="{{ old('operator_id', $mailTemplate->operator_id ?? '') }}"
|
||||||
|
class="form-control form-control-lg" @if($isInfo) readonly @endif />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- 下部ボタン --}}
|
||||||
|
@if($isInfo)
|
||||||
|
<a href="{{ route('mail_templates_add') }}" class="btn btn-lg btn-success">登録</a>
|
||||||
|
<a href="{{ route('mail_templates_edit', ['id' => $mailTemplate->mail_template_id]) }}" class="btn btn-lg btn-danger">編集</a>
|
||||||
|
@else
|
||||||
|
<button type="submit" class="btn btn-lg btn-danger register">保存</button>
|
||||||
|
@endif
|
||||||
|
</div>
|
||||||
46
resources/views/admin/mail_templates/add.blade.php
Normal file
46
resources/views/admin/mail_templates/add.blade.php
Normal file
@ -0,0 +1,46 @@
|
|||||||
|
@extends('layouts.app')
|
||||||
|
@section('title', '[東京都|〇〇駐輪場] メール送信テンプレート新規登録')
|
||||||
|
|
||||||
|
@section('content')
|
||||||
|
<!-- Content Header (Page header) -->
|
||||||
|
<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">メール送信テンプレート</li>
|
||||||
|
<li class="breadcrumb-item active">[東京都|〇〇駐輪場] メール送信テンプレート新規登録</li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- /.content-header -->
|
||||||
|
|
||||||
|
<!-- Main content -->
|
||||||
|
<section class="content">
|
||||||
|
<div class="container-fluid">
|
||||||
|
<!-- Card -->
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-lg-12">
|
||||||
|
<div class="card">
|
||||||
|
<form method="post" action="{{ route('mail_templates_add') }}" enctype="multipart/form-data">
|
||||||
|
@csrf
|
||||||
|
@include('admin.mail_templates._form', [
|
||||||
|
'isEdit' => false,
|
||||||
|
'isInfo' => false,
|
||||||
|
'mailTemplate' => $mailTemplate,
|
||||||
|
])
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
<!-- /.content -->
|
||||||
|
@endsection
|
||||||
20
resources/views/admin/mail_templates/edit.blade.php
Normal file
20
resources/views/admin/mail_templates/edit.blade.php
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
@extends('layouts.app')
|
||||||
|
@section('title', '[東京都|〇〇駐輪場] メール送信テンプレート')
|
||||||
|
|
||||||
|
@section('content')
|
||||||
|
<div class="content-header">
|
||||||
|
<div class="container-fluid">
|
||||||
|
<h1 class="m-0 text-dark">メール送信テンプレート編集</h1>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<section class="content">
|
||||||
|
<div class="container-fluid">
|
||||||
|
<div class="card">
|
||||||
|
<form method="post" action="{{ route('mail_templates_edit', ['id' => $mailTemplate->mail_template_id]) }}" enctype="multipart/form-data">
|
||||||
|
@csrf
|
||||||
|
@include('admin.mail_templates._form', ['isEdit' => 1, 'isInfo' => 0, 'mailTemplate' => $mailTemplate])
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
@endsection
|
||||||
21
resources/views/admin/mail_templates/info.blade.php
Normal file
21
resources/views/admin/mail_templates/info.blade.php
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
@extends('layouts.app')
|
||||||
|
@section('title', '[東京都|〇〇駐輪場] メール送信テンプレート')
|
||||||
|
|
||||||
|
@section('content')
|
||||||
|
<div class="content-header">
|
||||||
|
<div class="container-fluid">
|
||||||
|
<h1 class="m-0 text-dark">メール送信テンプレート詳細</h1>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<section class="content">
|
||||||
|
<div class="container-fluid">
|
||||||
|
<div class="card">
|
||||||
|
{{-- info 画面なので action は不要 --}}
|
||||||
|
<form method="post" enctype="multipart/form-data">
|
||||||
|
@csrf
|
||||||
|
@include('admin.mail_templates._form', ['isEdit' => 0, 'isInfo' => 1, 'mailTemplate' => $mailTemplate])
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
@endsection
|
||||||
201
resources/views/admin/mail_templates/list.blade.php
Normal file
201
resources/views/admin/mail_templates/list.blade.php
Normal file
@ -0,0 +1,201 @@
|
|||||||
|
@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 active">メール送信テンプレート</li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<section class="content">
|
||||||
|
<!-- ▼ 絞り込みフィルター -->
|
||||||
|
<div class="col-lg-12">
|
||||||
|
<div class="card">
|
||||||
|
|
||||||
|
{{-- タイトル区 --}}
|
||||||
|
<div class="card-header">
|
||||||
|
<h3 class="card-title">絞り込みフィルター</h3>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{-- フィルタフォーム主体 --}}
|
||||||
|
<div class="card-body">
|
||||||
|
<form action="{{ route('mail_templates') }}" method="POST" id="list-form" class="form-horizontal">
|
||||||
|
@csrf
|
||||||
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
|
|
||||||
|
<table class="table table-borderless mb-0" style="width: 100%;">
|
||||||
|
<tbody>
|
||||||
|
{{-- 行1 --}}
|
||||||
|
<tr>
|
||||||
|
<th style="width: 18%; text-align: left; vertical-align: middle;">メールテンプレートID</th>
|
||||||
|
<td style="width: 32%;">
|
||||||
|
<input type="text" name="mail_template_id"
|
||||||
|
value="{{ old('mail_template_id', $mail_template_id ?? '') }}"
|
||||||
|
class="form-control input-sm" placeholder="123456">
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<th style="width: 18%; text-align: left; vertical-align: middle;">使用プログラムID</th>
|
||||||
|
<td style="width: 32%;">
|
||||||
|
<input type="text" name="pg_id"
|
||||||
|
value="{{ old('pg_id', $pg_id ?? '') }}"
|
||||||
|
class="form-control input-sm" placeholder="123456">
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
{{-- 行2 --}}
|
||||||
|
<tr>
|
||||||
|
<th style="text-align: left; vertical-align: middle;">エリアマネージャー同報</th>
|
||||||
|
<td>
|
||||||
|
<select name="mgr_cc_flag" class="form-control input-sm">
|
||||||
|
<option value="">全て</option>
|
||||||
|
<option value="1" {{ old('mgr_cc_flag', $mgr_cc_flag ?? '') === '1' ? 'selected' : '' }}>同報する</option>
|
||||||
|
<option value="0" {{ old('mgr_cc_flag', $mgr_cc_flag ?? '') === '0' ? 'selected' : '' }}>同報市内</option>
|
||||||
|
</select>
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<th style="text-align: left; vertical-align: middle;">使用フラグ</th>
|
||||||
|
<td>
|
||||||
|
<select name="use_flag" class="form-control input-sm">
|
||||||
|
<option value="">全て</option>
|
||||||
|
<option value="1" {{ old('use_flag', $use_flag ?? '') === '1' ? 'selected' : '' }}>使用する</option>
|
||||||
|
<option value="0" {{ old('use_flag', $use_flag ?? '') === '0' ? 'selected' : '' }}>使用しない</option>
|
||||||
|
</select>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
{{-- 行3 --}}
|
||||||
|
<tr>
|
||||||
|
<th style="text-align: left; vertical-align: middle;">件名</th>
|
||||||
|
<td colspan="3">
|
||||||
|
<input type="text" name="subject"
|
||||||
|
value="{{ old('subject', $subject ?? '') }}"
|
||||||
|
class="form-control input-sm" placeholder="キーワード...">
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
{{-- ボタン --}}
|
||||||
|
<div class="form-group col-12 text-left">
|
||||||
|
<button type="submit" name="action" value="filter" class="btn btn-default">絞り込み</button>
|
||||||
|
<button type="submit" name="action" value="reset" class="btn btn-default">解除</button>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- ▲ 絞り込みフィルター -->
|
||||||
|
|
||||||
|
<!-- ▼ ツールバー -->
|
||||||
|
<div class="container-fluid mb20">
|
||||||
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('mail_templates_add') }}'">新規</button>
|
||||||
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
|
<div class="d-flex justify-content-end">
|
||||||
|
{{ $templates->appends(request()->all())->links('pagination') }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- ▲ ツールバー -->
|
||||||
|
|
||||||
|
<!-- ▼ テーブル -->
|
||||||
|
<div class="col-lg-12 mb20">
|
||||||
|
<div class="table-responsive">
|
||||||
|
<form action="{{ route('mail_templates_delete') }}" method="POST" id="form_delete">
|
||||||
|
@csrf
|
||||||
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<th style="width:120px;" class="text-left">
|
||||||
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
|
</th>
|
||||||
|
<th class="sorting {{ ($sort=='mail_template_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="mail_template_id"><span>メールテンプレートID</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='pg_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="pg_id"><span>使用プログラムID</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='internal_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="internal_id"><span>内部ID</span></th>
|
||||||
|
<th><span>エリアマネージャー同報</span></th>
|
||||||
|
<th><span>BCCアドレス</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='use_flag') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="use_flag"><span>使用フラグ</span></th>
|
||||||
|
<th><span>備考</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='subject') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="subject"><span>件名</span></th>
|
||||||
|
<th><span>本文</span></th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
@foreach($templates as $item)
|
||||||
|
<tr>
|
||||||
|
<td class="table-warning align-middle">
|
||||||
|
<div class="d-flex align-items-center">
|
||||||
|
<input type="checkbox" class="minimal m-0 checkbox" name="pk[]" value="{{ $item->mail_template_id }}">
|
||||||
|
<a href="{{ route('mail_templates_info', ['id' => $item->mail_template_id]) }}" class="btn btn-sm btn-default ml-2">編集</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->mail_template_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->pg_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->internal_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->mgr_cc_flag ? '同報する' : '同報しない' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->bcc_adrs }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->use_flag ? '使用する' : '使用しない' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->memo }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->subject }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ Str::limit($item->text, 30) }}</td>
|
||||||
|
</tr>
|
||||||
|
@endforeach
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- ▲ テーブル -->
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<form action="{{ route('mail_templates_export') }}" method="GET" id="form_export"></form>
|
||||||
|
|
||||||
|
@push('scripts')
|
||||||
|
<script>
|
||||||
|
// 全選択・全解除
|
||||||
|
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
|
||||||
|
document.querySelectorAll('.checkbox').forEach(cb => cb.checked = e.target.checked);
|
||||||
|
});
|
||||||
|
|
||||||
|
// 削除確認
|
||||||
|
document.getElementById('delete')?.addEventListener('click', function(){
|
||||||
|
const anyChecked = Array.from(document.querySelectorAll('.checkbox')).some(cb => cb.checked);
|
||||||
|
if (!anyChecked) {
|
||||||
|
alert('削除対象が選択されていません。');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (confirm('削除してよろしいですか?')) {
|
||||||
|
document.getElementById('form_delete').submit();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
// ソート
|
||||||
|
document.querySelectorAll('th.sorting').forEach(th => {
|
||||||
|
th.addEventListener('click', function(){
|
||||||
|
const form = document.getElementById('list-form');
|
||||||
|
const current = "{{ $sort ?? '' }}";
|
||||||
|
const currentType = "{{ $sort_type ?? '' }}";
|
||||||
|
const nextCol = this.getAttribute('sort');
|
||||||
|
let nextType = 'asc';
|
||||||
|
if (current === nextCol) {
|
||||||
|
nextType = (currentType === 'asc') ? 'desc' : 'asc';
|
||||||
|
}
|
||||||
|
form.querySelector('[name=sort]').value = nextCol;
|
||||||
|
form.querySelector('[name=sort_type]').value = nextType;
|
||||||
|
form.submit();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
@endpush
|
||||||
|
@endsection
|
||||||
@ -27,7 +27,7 @@
|
|||||||
<div class="d-flex justify-content-start align-items-center">
|
<div class="d-flex justify-content-start align-items-center">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('managers_add') }}" class="btn btn-lg btn-success mr-2">{{ __('登録') }}</a>
|
<a href="{{ route('managers_add') }}" class="btn btn-lg btn-success mr-2">{{ __('登録') }}</a>
|
||||||
<a href="{{ route('managers_edit', ['manager_id' => $manager_id]) }}" class="btn btn-lg btn-danger">{{ __('編集') }}</a>
|
<a href="{{ route('managers_edit', ['id' => $manager_id]) }}" class="btn btn-lg btn-danger">{{ __('編集') }}</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-success mr-2">
|
<button type="submit" class="btn btn-lg btn-success mr-2">
|
||||||
{{ $isAddPage ? __('登録') : __('保存') }}
|
{{ $isAddPage ? __('登録') : __('保存') }}
|
||||||
@ -44,7 +44,7 @@
|
|||||||
@if($isInfo || $isEdit)
|
@if($isInfo || $isEdit)
|
||||||
{{-- 駐車場管理者ID(表示のみ) --}}
|
{{-- 駐車場管理者ID(表示のみ) --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.manager_id') }}</label>
|
<label>{{ __('駐車場管理者ID') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -58,7 +58,7 @@
|
|||||||
|
|
||||||
{{-- 駐車場管理者名 --}}
|
{{-- 駐車場管理者名 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label @if(!$isInfo) class="required" @endif>{{ __('validation.attributes.manager_name') }}</label>
|
<label @if(!$isInfo) class="required" @endif>{{ __('駐車場管理者名') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -72,7 +72,7 @@
|
|||||||
|
|
||||||
{{-- 種別 --}}
|
{{-- 種別 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.manager_type') }}</label>
|
<label>{{ __('種別') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -86,7 +86,7 @@
|
|||||||
|
|
||||||
{{-- 所属駐輪場 --}}
|
{{-- 所属駐輪場 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label @if(!$isInfo) class="required" @endif>{{ __('validation.attributes.park_name') }}</label>
|
<label @if(!$isInfo) class="required" @endif>{{ __('駐輪場名') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<select class="form-control form-control-lg mb10"
|
<select class="form-control form-control-lg mb10"
|
||||||
@ -103,7 +103,7 @@
|
|||||||
|
|
||||||
{{-- 管理デバイス1 --}}
|
{{-- 管理デバイス1 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label @if(!$isInfo) class="required" @endif>{{ __('validation.attributes.manager_device1') }}</label>
|
<label @if(!$isInfo) class="required" @endif>{{ __('管理デバイス1') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<select class="form-control form-control-lg mb10"
|
<select class="form-control form-control-lg mb10"
|
||||||
@ -120,7 +120,7 @@
|
|||||||
|
|
||||||
{{-- 管理デバイス2 --}}
|
{{-- 管理デバイス2 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label @if(!$isInfo) class="required" @endif>{{ __('validation.attributes.manager_device2') }}</label>
|
<label @if(!$isInfo) class="required" @endif>{{ __('管理デバイス2') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<select class="form-control form-control-lg mb10"
|
<select class="form-control form-control-lg mb10"
|
||||||
@ -137,7 +137,7 @@
|
|||||||
|
|
||||||
{{-- メールアドレス --}}
|
{{-- メールアドレス --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.manager_mail') }}</label>
|
<label>{{ __('メールアドレス') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -150,7 +150,7 @@
|
|||||||
|
|
||||||
{{-- 電話番号 --}}
|
{{-- 電話番号 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.manager_tel') }}</label>
|
<label>{{ __('電話番号') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -163,7 +163,7 @@
|
|||||||
|
|
||||||
{{-- アラート1送信(checkbox + hidden 0) --}}
|
{{-- アラート1送信(checkbox + hidden 0) --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.manager_alert1') }}</label>
|
<label>{{ __('アラート1') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group align-items-center">
|
<div class="input-group align-items-center">
|
||||||
@ -177,7 +177,7 @@
|
|||||||
|
|
||||||
{{-- アラート2送信(checkbox + hidden 0) --}}
|
{{-- アラート2送信(checkbox + hidden 0) --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.manager_alert2') }}</label>
|
<label>{{ __('アラート2') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group align-items-center">
|
<div class="input-group align-items-center">
|
||||||
@ -191,7 +191,7 @@
|
|||||||
|
|
||||||
{{-- 退職フラグ --}}
|
{{-- 退職フラグ --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.manager_quit_flag') }}</label>
|
<label>{{ __('退職フラグ') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@ -214,7 +214,7 @@
|
|||||||
|
|
||||||
{{-- 退職日 --}}
|
{{-- 退職日 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.manager_quitday') }}</label>
|
<label>{{ __('退職日') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -232,7 +232,7 @@
|
|||||||
<div class="d-flex justify-content-start align-items-center">
|
<div class="d-flex justify-content-start align-items-center">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('managers_add') }}" class="btn btn-lg btn-success mr-2">{{ __('登録') }}</a>
|
<a href="{{ route('managers_add') }}" class="btn btn-lg btn-success mr-2">{{ __('登録') }}</a>
|
||||||
<a href="{{ route('managers_edit', ['manager_id' => $manager_id]) }}" class="btn btn-lg btn-danger">{{ __('編集') }}</a>
|
<a href="{{ route('managers_edit', ['id' => $manager_id]) }}" class="btn btn-lg btn-danger">{{ __('編集') }}</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-success mr-2">
|
<button type="submit" class="btn btn-lg btn-success mr-2">
|
||||||
{{ $isAddPage ? __('登録') : __('保存') }}
|
{{ $isAddPage ? __('登録') : __('保存') }}
|
||||||
|
|||||||
@ -43,7 +43,7 @@
|
|||||||
<div class="card p-3">
|
<div class="card p-3">
|
||||||
|
|
||||||
{{-- 更新用フォーム --}}
|
{{-- 更新用フォーム --}}
|
||||||
<form method="post" action="{{ route('managers_edit', ['manager_id' => $mid]) }}">
|
<form method="post" action="{{ route('managers_edit', ['id' => $mid]) }}">
|
||||||
@csrf
|
@csrf
|
||||||
@include('admin.managers._form', ['isEdit' => 1, 'isInfo' => 0])
|
@include('admin.managers._form', ['isEdit' => 1, 'isInfo' => 0])
|
||||||
|
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
@php
|
@php
|
||||||
// 兼容控制器传参:$record 或 $manager_id
|
|
||||||
$mid = $record->manager_id ?? ($manager_id ?? null);
|
$mid = $record->manager_id ?? ($manager_id ?? null);
|
||||||
@endphp
|
@endphp
|
||||||
|
|
||||||
|
|||||||
@ -2,47 +2,45 @@
|
|||||||
@section('title', '[東京都|〇〇駐輪場] 駐輪場管理者マスタ')
|
@section('title', '[東京都|〇〇駐輪場] 駐輪場管理者マスタ')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<div class="content-header">
|
<!-- Content Header -->
|
||||||
|
<div class="content-header">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row mb-2">
|
<div class="row mb-2">
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<h1 class="m-0 text-dark">{{ __('駐輪場管理者マスタ') }}</h1>
|
<h1 class="m-0 text-dark">駐輪場管理者マスタ</h1>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<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="{{ route('home') }}">XX様info(ホーム)</a></li>
|
||||||
<li class="breadcrumb-item"><a href="javascript: void(0);">[東京都|〇〇駐輪場]</a></li>
|
<li class="breadcrumb-item"><a href="javascript:void(0);">[東京都|〇〇駐輪場]</a></li>
|
||||||
<li class="breadcrumb-item active">{{ __('駐輪場管理者マスタ') }}</li>
|
<li class="breadcrumb-item active">駐輪場管理者マスタ</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<section class="content">
|
<!-- Main Content -->
|
||||||
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
|
{{-- 並び替え用 hidden --}}
|
||||||
<div class="row">
|
<form action="{{ route('managers') }}" method="POST" id="list-form">
|
||||||
{{-- 並び替え用 --}}
|
|
||||||
<form action="{{ route('managers') }}" method="post" id="list-form">
|
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" value="{{ $sort }}" name="sort" id="sort">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" value="{{ $sort_type }}" name="sort_type" id="sort_type">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
<!-- 操作ボタン -->
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20">
|
||||||
{{-- 新規 --}}
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('managers_add') }}'">新規</button>
|
||||||
<a href="{{ route('managers_add') }}" class="btn btn-sm btn-default mr10">
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_delete">削除</button>
|
||||||
{{ __('新規') }}
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">{{ __('CSV出力') }}</button>
|
||||||
</a>
|
<div class="d-flex justify-content-end">
|
||||||
{{-- 削除(左侧勾选后提交下方 form_delete) --}}
|
{{ $list->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" id="delete" form="form_delete">
|
</div>
|
||||||
{{ __('削除') }}
|
|
||||||
</button>
|
|
||||||
|
|
||||||
{{ $list->appends(['sort' => $sort, 'sort_type' => $sort_type])->links('pagination') }}
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- メッセージ表示 -->
|
||||||
<div class="form col-lg-12">
|
<div class="form col-lg-12">
|
||||||
@if(Session::has('success'))
|
@if(Session::has('success'))
|
||||||
<div class="alert alert-success alert-dismissible" role="alert">
|
<div class="alert alert-success alert-dismissible" role="alert">
|
||||||
@ -55,135 +53,61 @@
|
|||||||
<h4><i class="icon fa fa-ban"></i> {{ __('誤差') }}:</h4>
|
<h4><i class="icon fa fa-ban"></i> {{ __('誤差') }}:</h4>
|
||||||
{!! Session::get('error') !!}
|
{!! Session::get('error') !!}
|
||||||
</div>
|
</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
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<!-- ▼ 単一テーブル構成 -->
|
||||||
{{-- 左:チェック&操作 --}}
|
<div class="col-lg-12 mb20">
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<div class="table-responsive">
|
||||||
<form action="{{ route('managers_delete') }}" method="post" id="form_delete">
|
<form action="{{ route('managers_delete') }}" method="POST" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>
|
{{-- ★ チェック + 編集ボタン列 --}}
|
||||||
|
<th style="width:120px;" class="text-left">
|
||||||
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
</th>
|
</th>
|
||||||
|
<th class="sorting {{ ($sort=='manager_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="manager_id"><span>駐輪場管理者ID</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='manager_name') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="manager_name"><span>駐輪場管理者名</span></th>
|
||||||
|
<th><span>種別</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='manager_parkid') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="manager_parkid"><span>所属駐車場ID</span></th>
|
||||||
|
<th><span>管理デバイス1</span></th>
|
||||||
|
<th><span>管理デバイス2</span></th>
|
||||||
|
<th><span>メール</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='manager_tel') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="manager_tel"><span>電話</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='manager_alert1') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="manager_alert1"><span>アラート1</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='manager_alert2') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="manager_alert2"><span>アラート2</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='manager_quit_flag') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="manager_quit_flag"><span>退職フラグ</span></th>
|
||||||
|
<th><span>退職日</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@foreach($list as $item)
|
@foreach($list as $item)
|
||||||
<tr role="row">
|
<tr>
|
||||||
<td>
|
{{-- チェック+編集ボタン --}}
|
||||||
<input type="checkbox" class="minimal m-0 checkbox"
|
<td class="table-warning align-middle">
|
||||||
value="{{ $item->manager_id }}" name="pk[]">
|
<div class="d-flex align-items-center">
|
||||||
<div class="btn_action">
|
<input type="checkbox" class="minimal m-0 checkbox" name="pk[]" value="{{ $item->manager_id }}">
|
||||||
{{-- <a href="{{ route('managers_add') }}" class="btn btn-sm btn-default">詳細</a> --}}
|
<a href="{{ route('managers_info', ['id' => $item->manager_id]) }}"
|
||||||
<a href="{{ route('managers_info', ['manager_id' => $item->manager_id]) }}"
|
class="btn btn-sm btn-default ml-2">{{ __('編集') }}</a>
|
||||||
class="btn btn-sm btn-default ml10">{{ __('編集') }}</a>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
<td class="sm-item text-left align-middle">{{ $item->manager_id }}</td>
|
||||||
@endforeach
|
<td class="sm-item text-left align-middle">{{ $item->manager_name }}</td>
|
||||||
</tbody>
|
<td class="sm-item text-left align-middle">{{ $item->manager_type }}</td>
|
||||||
</table>
|
<td class="sm-item text-left align-middle">{{ !empty($item->getPark()) ? $item->getPark()->park_name : '' }}</td>
|
||||||
</form>
|
<td class="sm-item text-left align-middle">{{ !empty($item->getDevice1()) ? $item->getDevice1()->device_subject : '' }}</td>
|
||||||
</div>
|
<td class="sm-item text-left align-middle">{{ !empty($item->getDevice2()) ? $item->getDevice2()->device_subject : '' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->manager_mail }}</td>
|
||||||
{{-- 右:一覧テーブル --}}
|
<td class="sm-item text-left align-middle">{{ $item->manager_tel }}</td>
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
<td class="sm-item text-left align-middle">{{ $item->manager_alert1 }}</td>
|
||||||
<div class="scroll">
|
<td class="sm-item text-left align-middle">{{ $item->manager_alert2 }}</td>
|
||||||
<table class="table dataTable">
|
<td class="sm-item text-left align-middle">{{ $item->getManagerQuitFlagDisplay() }}</td>
|
||||||
<thead>
|
<td class="sm-item text-left align-middle">
|
||||||
<tr>
|
|
||||||
{{-- 駐車場管理者ID --}}
|
|
||||||
<th class="sorting @if($sort=='manager_id'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif"
|
|
||||||
sort="manager_id"><span>{{ __('validation.attributes.manager_id') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 駐車場管理者名 --}}
|
|
||||||
<th class="sorting @if($sort=='manager_name'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif"
|
|
||||||
sort="manager_name"><span>{{ __('validation.attributes.manager_name') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 種別 --}}
|
|
||||||
<th><span>{{ __('validation.attributes.manager_type') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 所属駐車場ID --}}
|
|
||||||
<th class="sorting @if($sort=='manager_parkid'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif"
|
|
||||||
sort="manager_parkid"><span>{{ __('validation.attributes.manager_parkid') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 管理デバイス1/2 --}}
|
|
||||||
<th><span>{{ __('validation.attributes.manager_device1') }}</span></th>
|
|
||||||
<th><span>{{ __('validation.attributes.manager_device2') }}</span></th>
|
|
||||||
|
|
||||||
{{-- メール --}}
|
|
||||||
<th><span>{{ __('validation.attributes.manager_mail') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 電話 --}}
|
|
||||||
<th class="sorting @if($sort=='manager_tel'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif"
|
|
||||||
sort="manager_tel"><span>{{ __('validation.attributes.manager_tel') }}</span></th>
|
|
||||||
|
|
||||||
{{-- アラート1(★sort 修正済) --}}
|
|
||||||
<th class="sorting @if($sort=='manager_alert1'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif"
|
|
||||||
sort="manager_alert1"><span>{{ __('validation.attributes.manager_alert1') }}</span></th>
|
|
||||||
|
|
||||||
{{-- アラート2 --}}
|
|
||||||
<th class="sorting @if($sort=='manager_alert2'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif"
|
|
||||||
sort="manager_alert2"><span>{{ __('validation.attributes.manager_alert2') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 退職フラグ --}}
|
|
||||||
<th class="sorting @if($sort=='manager_quit_flag'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif"
|
|
||||||
sort="manager_quit_flag"><span>{{ __('validation.attributes.manager_quit_flag') }}</span></th>
|
|
||||||
|
|
||||||
{{-- 退職日 --}}
|
|
||||||
<th><span>{{ __('validation.attributes.manager_quitday') }}</span></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
|
|
||||||
<tbody>
|
|
||||||
@foreach($list as $item)
|
|
||||||
<tr>
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{ mb_substr($item->manager_id, 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{ mb_substr($item->manager_name, 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{ mb_substr($item->manager_type, 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{ mb_substr(!empty($item->getPark()) ? $item->getPark()->park_name : "", 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{ mb_substr(!empty($item->getDevice1()) ? $item->getDevice1()->device_subject : "", 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{ mb_substr(!empty($item->getDevice2()) ? $item->getDevice2()->device_subject : "", 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{ mb_substr($item->manager_mail, 0, 20) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{ mb_substr($item->manager_tel, 0, 20) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{ mb_substr($item->manager_alert1, 0, 20) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{ mb_substr($item->manager_alert2, 0, 20) }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{ $item->getManagerQuitFlagDisplay() }}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
@if($item->manager_quitday)
|
@if($item->manager_quitday)
|
||||||
<span class="text-muted"><i class="fa fa-clock-o mr-1"></i>
|
<span class="text-muted">
|
||||||
|
<i class="fa fa-clock-o mr-1"></i>
|
||||||
{{ mb_substr($item->manager_quitday, 0, 10) }}
|
{{ mb_substr($item->manager_quitday, 0, 10) }}
|
||||||
</span>
|
</span>
|
||||||
@endif
|
@endif
|
||||||
@ -191,21 +115,21 @@
|
|||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
|
|
||||||
</table>
|
</table>
|
||||||
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- ▲ 単一テーブル構成ここまで -->
|
||||||
</div>
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
</div>
|
<form action="{{ route('managers_export') }}" method="GET" id="form_export"></form>
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
// 全選択
|
// 全選択
|
||||||
document.getElementById('checkbox_all')?.addEventListener('change', function () {
|
document.getElementById('checkbox_all')?.addEventListener('change', function () {
|
||||||
const checks = document.querySelectorAll('#form_delete .checkbox');
|
const checks = document.querySelectorAll('#form_delete .checkbox');
|
||||||
checks.forEach(ch => ch.checked = this.checked);
|
checks.forEach(ch => ch.checked = this.checked);
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
@endsection
|
@endsection
|
||||||
|
|||||||
@ -1,122 +0,0 @@
|
|||||||
@extends('layouts.app')
|
|
||||||
@section('title', '[東京都|〇〇駐輪場] 近傍駅マスタ')
|
|
||||||
|
|
||||||
@section('content')
|
|
||||||
<!-- Content Header -->
|
|
||||||
<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>
|
|
||||||
|
|
||||||
<!-- Main Content -->
|
|
||||||
<section class="content">
|
|
||||||
<div class="container-fluid">
|
|
||||||
<form action="{{ route('neighbor_stations') }}" method="POST" id="list-form">
|
|
||||||
@csrf
|
|
||||||
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
|
||||||
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
|
||||||
</form>
|
|
||||||
|
|
||||||
<div class="container-fluid mb20">
|
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('neighbor_station_add') }}'"> 新規</button>
|
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">{{ __('CSV出力') }}</button>
|
|
||||||
{{ $stations->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- メッセージ表示 -->
|
|
||||||
<div class="col-lg-12">
|
|
||||||
@if(session('success'))
|
|
||||||
<div class="alert alert-success alert-dismissible">{{ session('success') }}</div>
|
|
||||||
@elseif(session('error'))
|
|
||||||
<div class="alert alert-danger alert-dismissible">{{ session('error') }}</div>
|
|
||||||
@endif
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
|
||||||
<!-- 左側チェックボックス&編集ボタン -->
|
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
|
||||||
<form action="{{ route('neighbor_stations_delete') }}" method="POST" id="form_delete">
|
|
||||||
@csrf
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th><input type="checkbox" class="minimal m-0" id="checkbox_all"></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($stations as $station)
|
|
||||||
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
<input type="checkbox" class="minimal m-0 checkbox" value="{{ $station->station_id }}" name="pk[]">
|
|
||||||
<div class="btn_action">
|
|
||||||
<a href="{{ route('neighbor_station_edit', ['id' => $station->station_id]) }}" class="btn btn-sm btn-default ml10">{{ __('編集') }}</a>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- 右側データテーブル -->
|
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th class="sorting {{ ($sort=='station_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="station_id">
|
|
||||||
<span>近傍駅ID</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='park_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="park_id">
|
|
||||||
<span>駐車場ID</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='station_neighbor_station') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="station_neighbor_station">
|
|
||||||
<span>近傍駅</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='station_name_ruby') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="station_name_ruby">
|
|
||||||
<span>近傍駅ふりがな</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='station_route_name') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="station_route_name">
|
|
||||||
<span>路線名</span>
|
|
||||||
</th>
|
|
||||||
<th><span>近傍駅座標(緯度)</span></th>
|
|
||||||
<th><span>近傍駅座標(経度)</span></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($stations as $station)
|
|
||||||
<tr>
|
|
||||||
<td class="sm-item text-left">{{ $station->station_id }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $station->park_id }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $station->station_neighbor_station }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $station->station_name_ruby }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $station->station_route_name }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $station->station_latitude }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $station->station_longitude }}</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
<form action="{{ route('neighbor_stations_export') }}" method="GET" id="form_export"></form>
|
|
||||||
@endsection
|
|
||||||
@ -1,35 +1,33 @@
|
|||||||
@extends('layouts.app')
|
@extends('layouts.app')
|
||||||
@section('title', '[東京都|〇〇駐輪場] オペレータキュー')
|
@section('title', '[東京都|〇〇駐輪場] オペレータキュー')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<div class="content-header">
|
<div class="content-header">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row mb-2">
|
<div class="row mb-2">
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<h1 class="m-0 text-dark">{{__('オペレータキュー')}}</h1>
|
<h1 class="m-0 text-dark">オペレータキュー</h1>
|
||||||
</div><!-- /.col -->
|
</div>
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<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="{{ route('home') }}">XX様info(ホーム)</a></li>
|
||||||
<li class="breadcrumb-item"><a href="javascript: void(0);">[東京都|〇〇駐輪場]</a></li>
|
<li class="breadcrumb-item active">オペレータキュー</li>
|
||||||
<li class="breadcrumb-item active">{{__('オペレータキュー')}}</li>
|
|
||||||
</ol>
|
</ol>
|
||||||
</div><!-- /.col -->
|
|
||||||
</div><!-- /.row -->
|
|
||||||
</div><!-- /.container-fluid -->
|
|
||||||
</div>
|
</div>
|
||||||
<!-- /.content-header -->
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<!-- Main content -->
|
<section class="content">
|
||||||
<section class="content">
|
<!-- ▼ 絞り込みフィルター -->
|
||||||
<!-- キューステータス -->
|
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<div class="card-header"><h3 class="card-title">絞り込みフィルター</h3></div>
|
<div class="card-header"><h3 class="card-title">絞り込みフィルター</h3></div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<form action="{{ route('operator_ques') }}" method="POST" id="filter-form">
|
<form action="{{ route('operator_ques') }}" method="POST" id="list-form">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="sort" id="sort" value="{{ $sort ?? '' }}">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" name="sort_type" id="sort_type" value="{{ $sort_type ?? '' }}">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="form-group col-12">
|
<div class="form-group col-12">
|
||||||
@ -37,8 +35,7 @@
|
|||||||
<select name="que_status" class="form-control">
|
<select name="que_status" class="form-control">
|
||||||
<option value="">-- 選択してください --</option>
|
<option value="">-- 選択してください --</option>
|
||||||
@foreach(\App\Models\OperatorQue::QueStatus as $key => $label)
|
@foreach(\App\Models\OperatorQue::QueStatus as $key => $label)
|
||||||
<option value="{{ $key }}"
|
<option value="{{ $key }}" {{ old('que_status', $que_status ?? '') == $key ? 'selected' : '' }}>
|
||||||
@if(old('que_status', $que_status ?? '') == $key) selected @endif>
|
|
||||||
{{ $label }}
|
{{ $label }}
|
||||||
</option>
|
</option>
|
||||||
@endforeach
|
@endforeach
|
||||||
@ -46,7 +43,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-group col-12 text-left mt-2">
|
<div class="form-group col-12 text-left">
|
||||||
<button type="submit" name="action" value="filter" class="btn btn-default">絞り込み</button>
|
<button type="submit" name="action" value="filter" class="btn btn-default">絞り込み</button>
|
||||||
<button type="submit" name="action" value="reset" class="btn btn-default">解除</button>
|
<button type="submit" name="action" value="reset" class="btn btn-default">解除</button>
|
||||||
</div>
|
</div>
|
||||||
@ -54,32 +51,21 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- ▲ 絞り込みフィルター -->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<!-- SELECT2 EXAMPLE -->
|
<!-- ▼ ツールバー -->
|
||||||
|
|
||||||
|
|
||||||
<div class="row">
|
|
||||||
<form action="{{route('operator_ques')}}" method='post' id='list-form'>
|
|
||||||
<input type="hidden" name="_token" value="{{ csrf_token() }}">
|
|
||||||
<input type="hidden" value="{{$sort}}" name="sort" id="sort">
|
|
||||||
<input type="hidden" value="{{$sort_type}}" name="sort_type" id="sort_type">
|
|
||||||
</form>
|
|
||||||
|
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20">
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" name="delete"
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
id="delete">{{__('削除')}}</button>
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('operator_ques_import') }}'">インポート</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" name="import_csv" id="import_csv" action="{{route('operator_ques_import')}}">{{__('インポート')}}</button>
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">{{ __('CSV出力') }}</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" name="export_csv" id="export_csv" action="{{route('operator_ques_export')}}">{{__('CSV出力')}}</button>
|
<div class="d-flex justify-content-end">
|
||||||
{{ $list->appends(['sort' => $sort,'sort_type'=>$sort_type])->links('pagination') }}
|
{{ $list->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- ▲ ツールバー -->
|
||||||
|
|
||||||
|
<!-- ▼ メッセージ表示 -->
|
||||||
<div class="form col-lg-12">
|
<div class="form col-lg-12">
|
||||||
@if(Session::has('success'))
|
@if(Session::has('success'))
|
||||||
<div class="alert alert-success alert-dismissible" role="alert">
|
<div class="alert alert-success alert-dismissible" role="alert">
|
||||||
@ -89,150 +75,109 @@
|
|||||||
@elseif(Session::has('error'))
|
@elseif(Session::has('error'))
|
||||||
<div class="alert alert-danger alert-dismissible">
|
<div class="alert alert-danger alert-dismissible">
|
||||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||||
<h4><i class="icon fa fa-ban"></i> {{__('誤差')}}:</h4>
|
<h4><i class="icon fa fa-ban"></i> {{ __('誤差') }}:</h4>
|
||||||
{!! Session::get('error') !!}
|
{!! Session::get('error') !!}
|
||||||
</div>
|
</div>
|
||||||
@elseif(isset($errorMsg))
|
@elseif(isset($errorMsg))
|
||||||
<div class="alert alert-danger alert-dismissible">
|
<div class="alert alert-danger alert-dismissible">
|
||||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||||
<h4><i class="icon fa fa-ban"></i> {{__('誤差')}}:</h4>
|
<h4><i class="icon fa fa-ban"></i> {{ __('誤差') }}:</h4>
|
||||||
{!! $errorMsg !!}
|
{!! $errorMsg !!}
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<!-- ▲ メッセージ表示 -->
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
|
||||||
<form action="{{route('operator_ques_delete')}}" method="post" id="form_delete">
|
<!-- ▼ 単一テーブル構成 -->
|
||||||
<input type="hidden" name="_token" value="{{ csrf_token() }}">
|
<div class="col-lg-12 mb20">
|
||||||
<table class="table dataTable">
|
<div class="table-responsive">
|
||||||
|
<form action="{{ route('operator_ques_delete') }}" method="POST" id="form_delete">
|
||||||
|
@csrf
|
||||||
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>
|
<th style="width:120px;" class="text-left">
|
||||||
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
</th>
|
</th>
|
||||||
|
<th class="sorting {{ ($sort=='que_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="que_id"><span>キューID</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='user_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="user_id"><span>利用者名</span></th>
|
||||||
|
<th><span>携帯電話番号</span></th>
|
||||||
|
<th><span>自宅電話番号</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='park_name') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="park_name"><span>駐輪場</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='que_class') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="que_class"><span>キュー種別</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='que_comment') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="que_comment"><span>キューコメント</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='que_status') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="que_status"><span>キューステータス</span></th>
|
||||||
|
<th><span>キューステータスコメント</span></th>
|
||||||
|
<th><span>処理リンク</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@foreach($list as $item)
|
@foreach($list as $item)
|
||||||
<tr role="row">
|
<tr>
|
||||||
<td>
|
<td class="table-warning align-middle">
|
||||||
<input type="checkbox" class="minimal m-0 checkbox"
|
<div class="d-flex align-items-center">
|
||||||
value="{{ $item->que_id }}" name="pk[]">
|
<input type="checkbox" class="minimal m-0 checkbox" name="pk[]" value="{{ $item->que_id }}">
|
||||||
<div class="btn_action">
|
<a href="{{ route('operator_ques_info', ['id' => $item->que_id]) }}" class="btn btn-sm btn-default ml-2">編集</a>
|
||||||
{{-- 詳細 --}}
|
|
||||||
{{-- <a href="{{ route('operator_ques_add') }}" class="btn btn-sm btn-default">詳細</a> --}}
|
|
||||||
|
|
||||||
{{-- 編集 --}}
|
|
||||||
<a href="{{ route('operator_ques_info', ['id' => $item->que_id]) }}"
|
|
||||||
class="btn btn-sm btn-default ml10">{{ __('編集') }}</a>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->que_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ !empty($item->getUser()) ? $item->getUser()->user_name : '' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ !empty($item->getUser()) ? $item->getUser()->user_mobile : '' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ !empty($item->getUser()) ? $item->getUser()->user_homephone : '' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ !empty($item->getPark()) ? $item->getPark()->park_name : '' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->getQueClassLabel() }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->que_comment }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->getQueStatusLabel() }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->que_status_comment }}</td>
|
||||||
|
<td class="sm-item text-left align-middle"></td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<!--キューID-->
|
|
||||||
<th class="sorting @if($sort=="que_id"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="que_id"><span>{{__('validation.attributes.que_id')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- 利用者名 -->
|
|
||||||
<th class="sorting @if($sort=="user_id"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="user_id"><span>{{__('validation.attributes.user_name')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- 携帯電話番号 -->
|
|
||||||
<th><span>{{__('validation.attributes.user_mobile')}}</span></th>
|
|
||||||
|
|
||||||
<!-- 自宅電話番号 -->
|
|
||||||
<th><span>{{__('validation.attributes.user_homephone')}}</span></th>
|
|
||||||
<!-- 駐輪場 -->
|
|
||||||
<th class="sorting @if($sort=="park_name"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="park_name"><span>{{__('validation.attributes.park_name')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- キュー種別 -->
|
|
||||||
<th class="sorting @if($sort=="que_class"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="que_class"><span>{{__('validation.attributes.que_class')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- キューコメント -->
|
|
||||||
<th class="sorting @if($sort=="que_comment"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="que_comment"><span>{{__('validation.attributes.que_comment')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- キューステータス -->
|
|
||||||
<th class="sorting @if($sort=="que_status"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="que_status"><span>{{__('validation.attributes.que_status')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- キューステータスコメント -->
|
|
||||||
<th><span>{{__('validation.attributes.que_status_comment')}}</span></th>
|
|
||||||
|
|
||||||
<!-- 処理リンク -->
|
|
||||||
<th><span>{{__('validation.attributes.processing')}}</span>
|
|
||||||
</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($list as $item)
|
|
||||||
<tr>
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{mb_substr($item->que_id, 0, 10)}}</span></td>
|
|
||||||
<!-- 利用者名 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{mb_substr(!empty($item->getUser())?$item->getUser()->user_name:"", 0, 10)}}</span></td>
|
|
||||||
<!-- 携帯電話番号 -->
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{mb_substr(!empty($item->getUser())?$item->getUser()->user_mobile:"", 0, 15)}}</span></td>
|
|
||||||
|
|
||||||
<!-- 自宅電話番号 -->
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{mb_substr(!empty($item->getUser())?$item->getUser()->user_homephone:"", 0, 15)}}</span></td>
|
|
||||||
<!-- 駐輪場 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{mb_substr(!empty($item->getPark())?$item->getPark()->park_name:"", 0, 10)}}</span></td>
|
|
||||||
<!-- キュー種別 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{ mb_substr($item->getQueClassLabel(), 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
<!-- キューコメント -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{ mb_substr($item->que_comment, 0, 20) }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
<!-- キューステータス -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{ mb_substr($item->getQueStatusLabel(), 0, 10) }}</span>
|
|
||||||
</td>
|
|
||||||
|
|
||||||
<!-- キューステータスコメント -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{mb_substr($item->que_status_comment, 0, 20)}}</span></td>
|
|
||||||
|
|
||||||
<!-- //TODO 処理リンク -->
|
|
||||||
<td class='sm-item text-left'><span></span></td>
|
|
||||||
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
<!-- ▲ 単一テーブル構成 -->
|
||||||
</div>
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
</div>
|
<form action="{{ route('operator_ques_export') }}" method="GET" id="form_export"></form>
|
||||||
<!-- /.row -->
|
|
||||||
</div><!-- /.container-fluid -->
|
|
||||||
</section>
|
|
||||||
<!-- /.content -->
|
|
||||||
|
|
||||||
|
@push('scripts')
|
||||||
|
<script>
|
||||||
|
// 全選択・全解除
|
||||||
|
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
|
||||||
|
document.querySelectorAll('.checkbox').forEach(cb => cb.checked = e.target.checked);
|
||||||
|
});
|
||||||
|
|
||||||
|
// 削除確認
|
||||||
|
document.getElementById('delete')?.addEventListener('click', function(){
|
||||||
|
const anyChecked = Array.from(document.querySelectorAll('.checkbox')).some(cb => cb.checked);
|
||||||
|
if (!anyChecked) {
|
||||||
|
alert('削除対象が選択されていません。');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (confirm('削除してよろしいですか?')) {
|
||||||
|
document.getElementById('form_delete').submit();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
// ソート
|
||||||
|
document.querySelectorAll('th.sorting').forEach(th => {
|
||||||
|
th.addEventListener('click', function(){
|
||||||
|
const form = document.getElementById('list-form');
|
||||||
|
const current = "{{ $sort ?? '' }}";
|
||||||
|
const currentType = "{{ $sort_type ?? '' }}";
|
||||||
|
const nextCol = this.getAttribute('sort');
|
||||||
|
let nextType = 'asc';
|
||||||
|
if (current === nextCol) {
|
||||||
|
nextType = (currentType === 'asc') ? 'desc' : 'asc';
|
||||||
|
}
|
||||||
|
form.querySelector('[name=sort]').value = nextCol;
|
||||||
|
form.querySelector('[name=sort_type]').value = nextType;
|
||||||
|
form.submit();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
@endpush
|
||||||
@endsection
|
@endsection
|
||||||
@ -37,11 +37,6 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- <div class="container-fluid mb20">
|
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10">{{ __('削除') }}</button>
|
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10">{{ __('インポート') }}</button>
|
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10">{{ __('CSV出力') }}</button>
|
|
||||||
</div> -->
|
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
<!-- /.content -->
|
<!-- /.content -->
|
||||||
|
|||||||
@ -1,44 +1,45 @@
|
|||||||
@extends('layouts.app')
|
@extends('layouts.app')
|
||||||
@section('title', '[東京都|〇〇駐輪場] オペレータマスタ')
|
@section('title', '[東京都|〇〇駐輪場] オペレータマスタ')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<div class="content-header">
|
<div class="content-header">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row mb-2">
|
<div class="row mb-2">
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<h1 class="m-0 text-dark">{{__('オペレータマスタ')}}</h1>
|
<h1 class="m-0 text-dark">オペレータマスタ</h1>
|
||||||
</div><!-- /.col -->
|
</div>
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<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="{{ route('home') }}">XX様info(ホーム)</a></li>
|
||||||
<li class="breadcrumb-item"><a href="javascript:void(0);">[東京都|〇〇駐輪場]</a></li>
|
<li class="breadcrumb-item"><a href="javascript:void(0);">[東京都|〇〇駐輪場]</a></li>
|
||||||
<li class="breadcrumb-item active">{{__('オペレータマスタ')}}</li>
|
<li class="breadcrumb-item active">オペレータマスタ</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div><!-- /.col -->
|
|
||||||
</div><!-- /.row -->
|
|
||||||
</div><!-- /.container-fluid -->
|
|
||||||
</div>
|
</div>
|
||||||
<!-- /.content-header -->
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<!-- Main content -->
|
<section class="content">
|
||||||
<section class="content">
|
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row">
|
{{-- 並び替え用 hidden --}}
|
||||||
<form action="{{ route('opes') }}" method="post" id="list-form">
|
<form action="{{ route('opes') }}" method="POST" id="list-form">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" value="{{ $sort }}" name="sort" id="sort">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" value="{{ $sort_type }}" name="sort_type" id="sort_type">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
<!-- ツールバー -->
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20">
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('opes_add') }}'"> 新規</button>
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('opes_add') }}'">新規</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" form="form_delete">{{ __('削除') }}</button>
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" formaction="{{ route('opes_import') }}">{{ __('インポート') }}</button>
|
<button type="submit" class="btn btn-sm btn-default mr10" formaction="{{ route('opes_import') }}">インポート</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" formaction="{{ route('opes_export') }}">{{ __('CSV出力') }}</button>
|
<button type="submit" class="btn btn-sm btn-default mr10" formaction="{{ route('opes_export') }}">CSV出力</button>
|
||||||
|
<div class="d-flex justify-content-end">
|
||||||
{{ $list->appends(['sort' => $sort,'sort_type'=>$sort_type])->links('pagination') }}
|
{{ $list->appends(['sort' => $sort, 'sort_type' => $sort_type])->links('pagination') }}
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- メッセージ表示 -->
|
||||||
<div class="form col-lg-12">
|
<div class="form col-lg-12">
|
||||||
@if(Session::has('success'))
|
@if(Session::has('success'))
|
||||||
<div class="alert alert-success alert-dismissible" role="alert">
|
<div class="alert alert-success alert-dismissible" role="alert">
|
||||||
@ -48,273 +49,128 @@
|
|||||||
@elseif(Session::has('error'))
|
@elseif(Session::has('error'))
|
||||||
<div class="alert alert-danger alert-dismissible">
|
<div class="alert alert-danger alert-dismissible">
|
||||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||||
<h4><i class="icon fa fa-ban"></i> {{__('誤差')}}:</h4>
|
<h4><i class="icon fa fa-ban"></i> エラー:</h4>
|
||||||
{!! Session::get('error') !!}
|
{!! Session::get('error') !!}
|
||||||
</div>
|
</div>
|
||||||
@elseif(isset($errorMsg))
|
@elseif(isset($errorMsg))
|
||||||
<div class="alert alert-danger alert-dismissible">
|
<div class="alert alert-danger alert-dismissible">
|
||||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||||
<h4><i class="icon fa fa-ban"></i> {{__('誤差')}}:</h4>
|
<h4><i class="icon fa fa-ban"></i> エラー:</h4>
|
||||||
{!! $errorMsg !!}
|
{!! $errorMsg !!}
|
||||||
</div>
|
</div>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<!-- ▼ 単一テーブル構成 ----------------------------------------- -->
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<div class="col-lg-12 mb20">
|
||||||
<form action="{{ route('opes_delete') }}" method="post" id="form_delete">
|
<div class="table-responsive">
|
||||||
|
<form action="{{ route('opes_delete') }}" method="POST" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>
|
<th style="width:120px;" class="text-left">
|
||||||
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
</th>
|
</th>
|
||||||
|
<th class="sorting {{ ($sort=='ope_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="ope_id"><span>オペレータID</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='ope_name') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="ope_name"><span>オペレータ名</span></th>
|
||||||
|
<th><span>パスワード</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='ope_type') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="ope_type"><span>オペレータ種別</span></th>
|
||||||
|
<th><span>メールアドレス</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='ope_phone') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="ope_phone"><span>電話番号</span></th>
|
||||||
|
<th><span>キュー1~13アラート送信</span></th>
|
||||||
|
<th><span>管理者権限</span></th>
|
||||||
|
<th><span>エリアマネージャー</span></th>
|
||||||
|
<th><span>エリアオペレーター</span></th>
|
||||||
|
<th><span>オペレーター権限</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='ope_quit_flag') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="ope_quit_flag"><span>退職フラグ</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='ope_quitday') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="ope_quitday"><span>退職日</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@foreach($list as $item)
|
@foreach($list as $item)
|
||||||
<tr role="row">
|
<tr>
|
||||||
<td>
|
<td class="table-warning align-middle">
|
||||||
<input type="checkbox" class="minimal m-0 checkbox"
|
<div class="d-flex align-items-center">
|
||||||
value="{{ $item->ope_id }}" name="pk[]">
|
<input type="checkbox" class="minimal m-0 checkbox" name="pk[]" value="{{ $item->ope_id }}">
|
||||||
<div class="btn_action">
|
<a href="{{ route('opes_info', ['id' => $item->ope_id]) }}" class="btn btn-sm btn-default ml-2">編集</a>
|
||||||
<a href="{{ route('opes_info',['id'=>$item->ope_id]) }}"
|
|
||||||
class="btn btn-sm btn-default ml10">{{ __('編集') }}</a>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_name }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_pass }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ \App\Models\Ope::OPE_TYPE[$item->ope_type] }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_mail }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_phone }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">
|
||||||
|
{{ $item->ope_sendalart_que1 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que2 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que3 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que4 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que5 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que6 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que7 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que8 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que9 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que10 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que11 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que12 ? 'はい' : 'いいえ' }} /
|
||||||
|
{{ $item->ope_sendalart_que13 ? 'はい' : 'いいえ' }}
|
||||||
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_auth1 }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_auth2 }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_auth3 }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_auth4 }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_quit_flag ? '退職' : '在籍中' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->ope_quitday }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
|
|
||||||
<!-- オペレータID -->
|
|
||||||
<th class="sorting @if($sort=="ope_id"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_id"><span>{{__('validation.attributes.ope_id')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- オペレータ名 -->
|
|
||||||
<th class="sorting @if($sort=="ope_name"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_name"><span>{{__('validation.attributes.ope_name')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- オペレータ名 -->
|
|
||||||
<th><span>{{__('validation.attributes.password')}}</span></th>
|
|
||||||
<!-- オペレータ種別 -->
|
|
||||||
<th class="sorting @if($sort=="ope_type"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_type"><span>{{__('validation.attributes.ope_type')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- メールアドレス -->
|
|
||||||
<th><span>{{__('validation.attributes.ope_mail')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- 電話番号 -->
|
|
||||||
<th class="sorting @if($sort=="ope_phone"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_phone"><span>{{__('validation.attributes.ope_phone')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- キュー1アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que1"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que1">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que1')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- キュー2アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que2"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que2">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que2')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- キュー3アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que3"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que3">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que3')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- キュー4アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que4"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que4">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que4')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- キュー5アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que5"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que5">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que5')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- キュー6アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que6"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que6">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que6')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- キュー7アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que7"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que7">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que7')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- キュー8アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que8"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que8">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que8')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- キュー9アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que9"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que9">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que9')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- キュー10アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que10"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que10">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que10')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- キュー11アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que11"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que11">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que11')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- キュー12アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que12"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que12">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que12')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- キュー13アラート送信 -->
|
|
||||||
<th class="sorting @if($sort=="ope_sendalart_que13"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_sendalart_que13">
|
|
||||||
<span>{{__('validation.attributes.ope_sendalart_que13')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- 管理者権限付与 -->
|
|
||||||
<th class="sorting @if($sort=="ope_auth1"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_auth1">
|
|
||||||
<span>{{__('validation.attributes.ope_auth1')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- エリアマネージャー権限付与 -->
|
|
||||||
<th class="sorting @if($sort=="ope_auth1"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_auth1">
|
|
||||||
<span>{{__('validation.attributes.ope_auth1')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- エリアオペレーター権限付与 -->
|
|
||||||
<th class="sorting @if($sort=="ope_auth1"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_auth1">
|
|
||||||
<span>{{__('validation.attributes.ope_auth1')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- オペレーター権限付与 -->
|
|
||||||
<th class="sorting @if($sort=="ope_auth1"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_auth1">
|
|
||||||
<span>{{__('validation.attributes.ope_auth1')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- 退職フラグ -->
|
|
||||||
<th class="sorting @if($sort=="ope_quit_flag"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_quit_flag"><span>{{__('validation.attributes.ope_quit_flag')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- 退職日 -->
|
|
||||||
<th class="sorting @if($sort=="ope_quitday"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="ope_quitday"><span>{{__('validation.attributes.ope_quitday')}}</span>
|
|
||||||
</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($list as $item)
|
|
||||||
<tr>
|
|
||||||
<!-- オペレータID -->
|
|
||||||
<td class='sm-item text-left'><span>{{mb_substr($item->ope_id, 0, 10)}}</span>
|
|
||||||
</td>
|
|
||||||
<!-- オペレータ名 -->
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr($item->ope_name, 0, 10)}}</span>
|
|
||||||
</td>
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr($item->ope_pass, 0, 10)}}</span>
|
|
||||||
</td>
|
|
||||||
<!-- オペレータ種別 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{ __( \App\Models\Ope::OPE_TYPE[$item->ope_type] ) }}</span>
|
|
||||||
</td>
|
|
||||||
<!-- メールアドレス -->
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr($item->ope_mail, 0, 10)}}</span>
|
|
||||||
</td>
|
|
||||||
<!-- 電話番号 -->
|
|
||||||
<td class='sm-item text-left'>
|
|
||||||
<span>{{mb_substr($item->ope_phone, 0, 15)}}</span></td>
|
|
||||||
<!-- キュー1アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que1?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー2アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que2?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー3アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que3?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー4アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que4?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー5アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que5?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー6アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que6?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー7アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que7?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
|
|
||||||
<!-- キュー8アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que8?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー9アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que9?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー10アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que10?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー11アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que11?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー12アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que12?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
<!-- キュー13アラート送信 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_sendalart_que13?__("はい"):__("いいえ")}}</span></td>
|
|
||||||
|
|
||||||
<!-- 管理者権限付与 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_auth1}}</span></td>
|
|
||||||
<!-- エリアマネージャー権限付与 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_auth2}}</span></td>
|
|
||||||
<!-- エリアオペレーター権限付与 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_auth3}}</span></td>
|
|
||||||
<!-- オペレーター権限付与 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
<span>{{$item->ope_auth4}}</span></td>
|
|
||||||
<!-- 退職フラグ -->
|
|
||||||
<td class='sm-item text-right'><span>{{$item->ope_quit_flag?__("退職"):__("退職しない")}}</span>
|
|
||||||
</td>
|
|
||||||
<!-- 退職日 -->
|
|
||||||
<td class='sm-item text-right'>
|
|
||||||
@if($item->ope_quitday)
|
|
||||||
<span class="text-muted"><i class="fa fa-clock-o mr-1"></i>
|
|
||||||
{{mb_substr($item->ope_quitday, 0, 10)}}
|
|
||||||
</span>
|
|
||||||
@endif
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
</div>
|
||||||
|
<!-- ▲ 単一テーブル構成ここまで ----------------------------------------- -->
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</section>
|
||||||
</div>
|
|
||||||
</div><!-- /.container-fluid -->
|
<form action="{{ route('opes_export') }}" method="GET" id="form_export"></form>
|
||||||
</section>
|
|
||||||
<!-- /.content -->
|
@push('scripts')
|
||||||
|
<script>
|
||||||
|
// 全選択
|
||||||
|
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
|
||||||
|
document.querySelectorAll('.checkbox').forEach(cb => cb.checked = e.target.checked);
|
||||||
|
});
|
||||||
|
|
||||||
|
// 削除確認
|
||||||
|
document.getElementById('delete')?.addEventListener('click', function(){
|
||||||
|
const anyChecked = Array.from(document.querySelectorAll('.checkbox')).some(cb => cb.checked);
|
||||||
|
if (!anyChecked) {
|
||||||
|
alert('削除対象が選択されていません。');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (confirm('削除してよろしいですか?')) {
|
||||||
|
document.getElementById('form_delete').submit();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
// ソート
|
||||||
|
document.querySelectorAll('th.sorting').forEach(th => {
|
||||||
|
th.addEventListener('click', function(){
|
||||||
|
const form = document.getElementById('list-form');
|
||||||
|
const current = "{{ $sort ?? '' }}";
|
||||||
|
const currentType = "{{ $sort_type ?? '' }}";
|
||||||
|
const nextCol = this.getAttribute('sort');
|
||||||
|
let nextType = 'asc';
|
||||||
|
if (current === nextCol) {
|
||||||
|
nextType = (currentType === 'asc') ? 'desc' : 'asc';
|
||||||
|
}
|
||||||
|
form.querySelector('[name=sort]').value = nextCol;
|
||||||
|
form.querySelector('[name=sort_type]').value = nextType;
|
||||||
|
form.submit();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
@endpush
|
||||||
@endsection
|
@endsection
|
||||||
@ -9,7 +9,7 @@
|
|||||||
{{-- 登録・削除 ボタン(上部) --}}
|
{{-- 登録・削除 ボタン(上部) --}}
|
||||||
<div class="text-left mt-2 mb-3">
|
<div class="text-left mt-2 mb-3">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('payments_edit', ['payment_id' => $payment->payment_id]) }}" class="btn btn-lg btn-success">編集</a>
|
<a href="{{ route('payments_edit', ['id' => $payment->payment_id]) }}" class="btn btn-lg btn-success">編集</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
||||||
@if($isEdit)
|
@if($isEdit)
|
||||||
@ -198,7 +198,7 @@
|
|||||||
{{-- 登録・削除 ボタン(下部重ね) --}}
|
{{-- 登録・削除 ボタン(下部重ね) --}}
|
||||||
<div class="text-left mt-2">
|
<div class="text-left mt-2">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('payments_edit', ['payment_id' => $payment->payment_id]) }}" class="btn btn-lg btn-success">編集</a>
|
<a href="{{ route('payments_edit', ['id' => $payment->payment_id]) }}" class="btn btn-lg btn-success">編集</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
||||||
@if($isEdit)
|
@if($isEdit)
|
||||||
|
|||||||
@ -21,7 +21,7 @@
|
|||||||
|
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<form action="{{ route('payments_edit', ['payment_id' => $payment->payment_id]) }}" method="POST">
|
<form action="{{ route('payments_edit', ['id' => $payment->payment_id]) }}" method="POST">
|
||||||
@csrf
|
@csrf
|
||||||
@include('admin.payments._form', [
|
@include('admin.payments._form', [
|
||||||
'payment' => $payment,
|
'payment' => $payment,
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
@extends('layouts.app')
|
@extends('layouts.app')
|
||||||
@section('title', '決済情報マスタ')
|
@section('title', '[東京都|〇〇駐輪場] 決済情報マスタ')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<!-- Content Header -->
|
<!-- Content Header -->
|
||||||
@ -24,60 +24,51 @@
|
|||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
|
|
||||||
{{-- 一覧のソート用(既存規約踏襲) --}}
|
{{-- 並び替え用 hidden --}}
|
||||||
<form action="{{ route('payments') }}" method="POST" id="list-form">
|
<form action="{{ route('payments') }}" method="POST" id="list-form">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
<!-- ツールバー -->
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20">
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('payments_add') }}'">新規</button>
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('payments_add') }}'">新規</button>
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">{{ __('CSV出力') }}</button>
|
||||||
|
<div class="d-flex justify-content-end">
|
||||||
{{ $payments->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
{{ $payments->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12">
|
<!-- メッセージ表示 -->
|
||||||
@if(session('success'))
|
<div class="form col-lg-12">
|
||||||
<div class="alert alert-success alert-dismissible">{{ session('success') }}</div>
|
@if(Session::has('success'))
|
||||||
@elseif(session('error'))
|
<div class="alert alert-success alert-dismissible" role="alert">
|
||||||
<div class="alert alert-danger alert-dismissible">{{ session('error') }}</div>
|
<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>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<!-- ▼ 単一テーブル構成 ----------------------------------------- -->
|
||||||
<!-- 左側チェックボックス&編集ボタン -->
|
<div class="col-lg-12 mb20">
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<div class="table-responsive">
|
||||||
<form action="{{ route('payments_delete') }}" method="POST" id="form_delete">
|
<form action="{{ route('payments_delete') }}" method="POST" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th><input type="checkbox" class="minimal m-0" id="checkbox_all"></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($payments as $payment)
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
<input type="checkbox" class="minimal m-0 checkbox" value="{{ $payment->payment_id }}" name="id[]">
|
|
||||||
<div class="btn_action">
|
|
||||||
<a href="{{ route('payments_edit', ['payment_id' => $payment->payment_id]) }}" class="btn btn-sm btn-default ml10">編集</a>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- 右側データテーブル -->
|
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
|
{{-- チェック + 編集 --}}
|
||||||
|
<th style="width:120px;" class="text-left">
|
||||||
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
|
</th>
|
||||||
<th class="sorting {{ ($sort=='payment_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="payment_id">
|
<th class="sorting {{ ($sort=='payment_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="payment_id">
|
||||||
<span>決済情報ID</span>
|
<span>決済情報ID</span>
|
||||||
</th>
|
</th>
|
||||||
@ -101,26 +92,34 @@
|
|||||||
<tbody>
|
<tbody>
|
||||||
@foreach($payments as $payment)
|
@foreach($payments as $payment)
|
||||||
<tr>
|
<tr>
|
||||||
<td class="sm-item text-left">{{ $payment->payment_id }}</td>
|
{{-- 同じセルに チェック + 編集ボタン --}}
|
||||||
<td class="sm-item text-left">{{ $payment->payment_companyname }}</td>
|
<td class="table-warning align-middle">
|
||||||
<td class="sm-item text-left">{{ $payment->payment_inquirytel }}</td>
|
<div class="d-flex align-items-center">
|
||||||
<td class="sm-item text-left">{{ $payment->payment_inquiryname }}</td>
|
<input type="checkbox" class="minimal m-0 checkbox" name="id[]" value="{{ $payment->payment_id }}">
|
||||||
<td class="sm-item text-left">{{ $payment->payment_time }}</td>
|
<a href="{{ route('payments_edit', ['id' => $payment->payment_id]) }}" class="btn btn-sm btn-default ml-2">編集</a>
|
||||||
<td class="sm-item text-left">{{ optional($payment->updated_at)->format('Y-m-d H:i') }}</td>
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $payment->payment_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $payment->payment_companyname }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $payment->payment_inquirytel }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $payment->payment_inquiryname }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $payment->payment_time }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ optional($payment->updated_at)->format('Y-m-d H:i') }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!-- ▲ 単一テーブル構成ここまで ----------------------------------------- -->
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<form action="{{ route('payments_export') }}" method="GET" id="form_export"></form>
|
<form action="{{ route('payments_export') }}" method="GET" id="form_export"></form>
|
||||||
|
|
||||||
{{-- 一括削除 & ソートのJS(既存規約に合わせ最小限) --}}
|
{{-- 一括削除 & ソートのJS --}}
|
||||||
@push('scripts')
|
@push('scripts')
|
||||||
<script>
|
<script>
|
||||||
// 全選択
|
// 全選択
|
||||||
@ -140,7 +139,7 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// ヘッダクリックでソート変更(既存 list と同様のカスタム属性 "sort" を使用)
|
// ヘッダクリックでソート
|
||||||
document.querySelectorAll('th.sorting').forEach(th => {
|
document.querySelectorAll('th.sorting').forEach(th => {
|
||||||
th.addEventListener('click', function(){
|
th.addEventListener('click', function(){
|
||||||
const form = document.getElementById('list-form');
|
const form = document.getElementById('list-form');
|
||||||
|
|||||||
@ -22,7 +22,7 @@
|
|||||||
|
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<form method="POST" action="{{ route('print_areas_edit', ['print_area_id' => $record->print_area_id]) }}">
|
<form method="POST" action="{{ route('print_areas_edit', ['id' => $record->print_area_id]) }}">
|
||||||
@csrf
|
@csrf
|
||||||
|
|
||||||
@include('admin.print_areas._form', [
|
@include('admin.print_areas._form', [
|
||||||
|
|||||||
@ -21,7 +21,7 @@
|
|||||||
|
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<form method="POST" action="{{ route('print_areas_info', ['print_area_id' => $record->print_area_id]) }}">
|
<form method="POST" action="{{ route('print_areas_info', ['id' => $record->print_area_id]) }}">
|
||||||
@csrf
|
@csrf
|
||||||
@include('admin.print_areas._form', ['isEdit' => 0, 'isInfo' => 1])
|
@include('admin.print_areas._form', ['isEdit' => 0, 'isInfo' => 1])
|
||||||
</form>
|
</form>
|
||||||
|
|||||||
@ -12,6 +12,7 @@
|
|||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<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="{{ route('home') }}">XX様info(ホーム)</a></li>
|
||||||
|
<li class="breadcrumb-item"><a href="javascript:void(0);">[東京都|〇〇駐輪場]</a></li>
|
||||||
<li class="breadcrumb-item active">シール印刷範囲マスタ</li>
|
<li class="breadcrumb-item active">シール印刷範囲マスタ</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
@ -19,21 +20,28 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- Main Content -->
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
|
|
||||||
|
{{-- 並び替え用 hidden --}}
|
||||||
<form action="{{ route('print_areas') }}" method="POST" id="list-form">
|
<form action="{{ route('print_areas') }}" method="POST" id="list-form">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
<!-- 操作ボタン + ページネーション -->
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20">
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('print_areas_add') }}'">新規</button>
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('print_areas_add') }}'">新規</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" form="form_delete" onclick="return confirm('選択された項目を削除しますか?');">削除</button>
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">CSV出力</button>
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">CSV出力</button>
|
||||||
|
<div class="d-flex justify-content-end">
|
||||||
{{ $list->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
{{ $list->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- メッセージ表示 -->
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
@if(session('success'))
|
@if(session('success'))
|
||||||
<div class="alert alert-success alert-dismissible">{{ session('success') }}</div>
|
<div class="alert alert-success alert-dismissible">{{ session('success') }}</div>
|
||||||
@ -42,57 +50,44 @@
|
|||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<!-- ▼ 単一テーブル構成 -->
|
||||||
<!-- 左側チェックボックス -->
|
<div class="col-lg-12 mb20">
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<div class="table-responsive">
|
||||||
<form action="{{ route('print_areas_delete') }}" method="POST" id="form_delete">
|
<form action="{{ route('print_areas_delete') }}" method="POST" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th><input type="checkbox" class="minimal m-0" id="checkbox_all"></th>
|
{{-- チェック + 編集ボタン --}}
|
||||||
</tr>
|
<th style="width:120px;" class="text-left">
|
||||||
</thead>
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
<tbody>
|
</th>
|
||||||
@foreach($list as $item)
|
<th class="sorting {{ ($sort=='print_area_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="print_area_id"><span>印刷範囲ID</span></th>
|
||||||
<tr>
|
<th class="sorting {{ ($sort=='print_area_name') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="print_area_name"><span>印刷範囲名</span></th>
|
||||||
<td>
|
|
||||||
<input type="checkbox" class="minimal m-0 checkbox" value="{{ $item->print_area_id }}" name="pk[]">
|
|
||||||
<div class="btn_action">
|
|
||||||
<a href="{{ route('print_areas_edit', ['print_area_id' => $item->print_area_id]) }}" class="btn btn-sm btn-default ml10">編集</a>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- 右側データテーブル -->
|
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th><span>印刷範囲ID</span></th>
|
|
||||||
<th><span>印刷範囲名</span></th>
|
|
||||||
<th><span>駐輪場名</span></th>
|
<th><span>駐輪場名</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@foreach($list as $item)
|
@foreach($list as $item)
|
||||||
<tr>
|
<tr>
|
||||||
<td class="sm-item text-left">{{ $item->print_area_id }}</td>
|
<td class="table-warning align-middle">
|
||||||
<td class="sm-item text-left">{{ $item->print_area_name }}</td>
|
<div class="d-flex align-items-center">
|
||||||
<td class="sm-item text-left">{{ optional($item->park)->park_name }}</td>
|
<input type="checkbox" class="minimal m-0 checkbox" name="pk[]" value="{{ $item->print_area_id }}">
|
||||||
|
<a href="{{ route('print_areas_edit', ['id' => $item->print_area_id]) }}"
|
||||||
|
class="btn btn-sm btn-default ml-2">{{ __('編集') }}</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->print_area_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->print_area_name }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ optional($item->park)->park_name ?? '-' }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<!-- ▲ 単一テーブル構成ここまで -->
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
|
|||||||
@ -18,8 +18,8 @@
|
|||||||
@endif
|
@endif
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{route('regular_type_add')}}" class="btn btn-lg btn-success">{{__('登録')}}</a>
|
<a href="{{route('regular_types_add')}}" class="btn btn-lg btn-success">{{__('登録')}}</a>
|
||||||
<a href="{{route('regular_type_edit',['id'=>$regular_type_id])}}" class="btn btn-lg btn-danger">{{__('編集')}}</a>
|
<a href="{{route('regular_types_edit',['id'=>$regular_type_id])}}" class="btn btn-lg btn-danger">{{__('編集')}}</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-danger register" >{{__('保存')}}</button>
|
<button type="submit" class="btn btn-lg btn-danger register" >{{__('保存')}}</button>
|
||||||
@endIf
|
@endIf
|
||||||
@ -171,8 +171,8 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{route('regular_type_add')}}" class="btn btn-lg btn-success">{{__('登録')}}</a>
|
<a href="{{route('regular_types_add')}}" class="btn btn-lg btn-success">{{__('登録')}}</a>
|
||||||
<a href="{{route('regular_type_edit',['id'=>$regular_type_id])}}" class="btn btn-lg btn-danger">{{__('編集')}}</a>
|
<a href="{{route('regular_types_edit',['id'=>$regular_type_id])}}" class="btn btn-lg btn-danger">{{__('編集')}}</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-danger register" >{{__('保存')}}</button>
|
<button type="submit" class="btn btn-lg btn-danger register" >{{__('保存')}}</button>
|
||||||
@endIf
|
@endIf
|
||||||
|
|||||||
@ -31,7 +31,7 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<form method="post" action="{{ route('regular_type_add')}}" enctype="multipart/form-data">
|
<form method="post" action="{{ route('regular_types_add')}}" enctype="multipart/form-data">
|
||||||
<!-- TOKEN FORM -->
|
<!-- TOKEN FORM -->
|
||||||
<input type="hidden" name="_token" value="{{ csrf_token() }}" >
|
<input type="hidden" name="_token" value="{{ csrf_token() }}" >
|
||||||
<!-- / .TOKEN FORM -->
|
<!-- / .TOKEN FORM -->
|
||||||
|
|||||||
@ -31,7 +31,7 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<form method="post" action="{{ route('regular_type_edit',['id'=>$regular_type_id])}}" enctype="multipart/form-data">
|
<form method="post" action="{{ route('regular_types_edit',['id'=>$regular_type_id])}}" enctype="multipart/form-data">
|
||||||
<!-- TOKEN FORM -->
|
<!-- TOKEN FORM -->
|
||||||
<input type="hidden" name="_token" value="{{ csrf_token() }}" >
|
<input type="hidden" name="_token" value="{{ csrf_token() }}" >
|
||||||
<!-- / .TOKEN FORM -->
|
<!-- / .TOKEN FORM -->
|
||||||
|
|||||||
@ -31,7 +31,7 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<form method="post" action="{{ route('regular_type_info',['id'=>$regular_type_id])}}" enctype="multipart/form-data">
|
<form method="post" action="{{ route('regular_types_info',['id'=>$regular_type_id])}}" enctype="multipart/form-data">
|
||||||
<!-- TOKEN FORM -->
|
<!-- TOKEN FORM -->
|
||||||
<input type="hidden" name="_token" value="{{ csrf_token() }}" >
|
<input type="hidden" name="_token" value="{{ csrf_token() }}" >
|
||||||
<!-- / .TOKEN FORM -->
|
<!-- / .TOKEN FORM -->
|
||||||
|
|||||||
@ -1,45 +1,47 @@
|
|||||||
|
|
||||||
@extends('layouts.app')
|
@extends('layouts.app')
|
||||||
@section('title', '[東京都|〇〇駐輪場] 定期種別マスタ')
|
@section('title', '[東京都|〇〇駐輪場] 定期種別マスタ')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<div class="content-header">
|
<!-- Content Header -->
|
||||||
|
<div class="content-header">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row mb-2">
|
<div class="row mb-2">
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<h1 class="m-0 text-dark">{{__('定期種別マスタ')}}</h1>
|
<h1 class="m-0 text-dark">定期種別マスタ</h1>
|
||||||
</div><!-- /.col -->
|
</div>
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<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="{{ route('home') }}">XX様info(ホーム)</a></li>
|
||||||
<li class="breadcrumb-item"><a href="javascript: void(0);">[東京都|〇〇駐輪場]</a></li>
|
<li class="breadcrumb-item"><a href="javascript:void(0);">[東京都|〇〇駐輪場]</a></li>
|
||||||
<li class="breadcrumb-item active">{{__('定期種別マスタ')}}</li>
|
<li class="breadcrumb-item active">定期種別マスタ</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div><!-- /.col -->
|
|
||||||
</div><!-- /.row -->
|
|
||||||
</div><!-- /.container-fluid -->
|
|
||||||
</div>
|
</div>
|
||||||
<!-- /.content-header -->
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<!-- Main content -->
|
<!-- Main Content -->
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<!-- SELECT2 EXAMPLE -->
|
|
||||||
|
|
||||||
|
{{-- 並び替え用 hidden --}}
|
||||||
<div class="row">
|
<form action="{{ route('regular_types') }}" method="POST" id="list-form">
|
||||||
<form action="{{route('regular_types')}}" method='post' id='list-form'>
|
@csrf
|
||||||
<input type="hidden" name="_token" value="{{ csrf_token() }}">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" value="{{$sort}}" name="sort" id="sort">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
<input type="hidden" value="{{$sort_type}}" name="sort_type" id="sort_type">
|
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20">
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" name="delete" id="delete">{{__('削除')}}</button>
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('regular_types_add') }}'">新規</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" name="import_csv" id="import_csv" action="{{route('regular_types_import')}}">{{__('インポート')}}</button>
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" name="export_csv" id="export_csv" action="{{route('regular_types_export')}}">{{__('CSV出力')}}</button>
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">{{ __('CSV出力') }}</button>
|
||||||
{{ $list->appends(['sort' => $sort,'sort_type'=>$sort_type])->links('pagination') }}
|
<div class="d-flex justify-content-end">
|
||||||
|
{{ $list->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
<div class="form col-lg-12">
|
</div>
|
||||||
|
|
||||||
|
<!-- メッセージ表示 -->
|
||||||
|
<div class="col-lg-12">
|
||||||
@if(Session::has('success'))
|
@if(Session::has('success'))
|
||||||
<div class="alert alert-success alert-dismissible" role="alert">
|
<div class="alert alert-success alert-dismissible" role="alert">
|
||||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||||
@ -48,118 +50,65 @@
|
|||||||
@elseif(Session::has('error'))
|
@elseif(Session::has('error'))
|
||||||
<div class="alert alert-danger alert-dismissible">
|
<div class="alert alert-danger alert-dismissible">
|
||||||
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||||
<h4><i class="icon fa fa-ban"></i> {{__('誤差')}}:</h4>
|
<h4><i class="icon fa fa-ban"></i> {{ __('誤差') }}:</h4>
|
||||||
{!! Session::get('error') !!}
|
{!! Session::get('error') !!}
|
||||||
</div>
|
</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
|
@endif
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<!-- ▼ 単一テーブル構成 -->
|
||||||
<form action="{{route('regular_types_delete')}}" method="post" id="form_delete">
|
<div class="col-lg-12 mb20">
|
||||||
<input type="hidden" name="_token" value="{{ csrf_token() }}">
|
<div class="table-responsive">
|
||||||
<table class="table dataTable">
|
<form action="{{ route('regular_types_delete') }}" method="POST" id="form_delete">
|
||||||
|
@csrf
|
||||||
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>
|
{{-- チェック + 編集ボタン --}}
|
||||||
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
<th style="width:140px;" class="text-left">
|
||||||
|
<input type="checkbox" onclick="$('input[name*=\'pk\']').prop('checked', this.checked);">
|
||||||
</th>
|
</th>
|
||||||
|
<th class="sorting {{ ($sort=='regular_type_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="regular_type_id"><span>定期種別ID</span></th>
|
||||||
|
<th><span>市区名</span></th>
|
||||||
|
<th><span>定期種別1</span></th>
|
||||||
|
<th><span>定期種別2</span></th>
|
||||||
|
<th><span>定期種別3</span></th>
|
||||||
|
<th><span>定期種別6</span></th>
|
||||||
|
<th><span>定期種別12</span></th>
|
||||||
|
<th><span>備考</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
|
@php
|
||||||
|
$rc = \App\Models\RegularType::RegularClass;
|
||||||
|
@endphp
|
||||||
@foreach($list as $item)
|
@foreach($list as $item)
|
||||||
<tr role="row">
|
<tr>
|
||||||
<td>
|
<td class="table-warning align-middle">
|
||||||
<input type="checkbox" class="minimal m-0 checkbox"
|
<div class="d-flex align-items-center">
|
||||||
value="{{$item->regular_type_id}}" name="pk[]">
|
<input type="checkbox" class="minimal m-0 checkbox" name="pk[]" value="{{ $item->regular_type_id }}">
|
||||||
<div class="btn_action">
|
<a href="{{ route('regular_types_info', ['id' => $item->regular_type_id]) }}"
|
||||||
{{--<a href="{{route('regular_type_add')}}" class="btn btn-sm btn-default">詳細</a>--}}
|
class="btn btn-sm btn-default ml-2">{{ __('編集') }}</a>
|
||||||
<a href="{{ route('regular_type_info', ['id' => $item->regular_type_id]) }}"
|
|
||||||
class="btn btn-sm btn-default ml10">{{ __('編集') }}</a>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->regular_type_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->getCity()?->city_name ?? '-' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ __($rc[$item->regular_class_1] ?? '-') }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ __($rc[$item->regular_class_2] ?? '-') }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ __($rc[$item->regular_class_3] ?? '-') }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ __($rc[$item->regular_class_6] ?? '-') }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ __($rc[$item->regular_class_12] ?? '-') }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->memo ?? '-' }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<!-- 定期種別ID -->
|
|
||||||
<th class="sorting @if($sort=="regular_type_id"){{$sort_type == 'asc'?'sorting_asc':'sorting_desc'}}@endif"
|
|
||||||
sort="regular_type_id"><span>{{__('validation.attributes.regular_type_id')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- 市区名 -->
|
|
||||||
<th><span>{{__('validation.attributes.city_name')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- 定期種別1 -->
|
|
||||||
<th><span>{{__('validation.attributes.regular_class_1')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- 定期種別2 -->
|
|
||||||
<th><span>{{__('validation.attributes.regular_class_2')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- 定期種別3 -->
|
|
||||||
<th><span>{{__('validation.attributes.regular_class_3')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- 定期種別6 -->
|
|
||||||
<th><span>{{__('validation.attributes.regular_class_6')}}</span>
|
|
||||||
</th>
|
|
||||||
|
|
||||||
<!-- 定期種別12 -->
|
|
||||||
<th><span>{{__('validation.attributes.regular_class_12')}}</span>
|
|
||||||
</th>
|
|
||||||
<!-- 備考 -->
|
|
||||||
<th><span>{{__('validation.attributes.memo')}}</span>
|
|
||||||
</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($list as $item)
|
|
||||||
<tr>
|
|
||||||
|
|
||||||
<!-- 定期種別ID -->
|
|
||||||
<td class='sm-item text-left'><span>{{mb_substr($item->regular_type_id, 0, 10)}}</span></td>
|
|
||||||
|
|
||||||
<!-- 市区名 -->
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr(!empty($item->getCity())?$item->getCity()->city_name:"", 0, 10)}}</span></td>
|
|
||||||
|
|
||||||
<!-- 定期種別1 -->
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr(__(\App\RegularType::RegularClass[$item->regular_class_1]), 0, 10)}}</span></td>
|
|
||||||
|
|
||||||
<!-- 定期種別2 -->
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr(__(\App\RegularType::RegularClass[$item->regular_class_2]), 0, 10)}}</span></td>
|
|
||||||
<!-- 定期種別3 -->
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr(__(\App\RegularType::RegularClass[$item->regular_class_3]), 0, 10)}}</span></td>
|
|
||||||
<!-- 定期種別6 -->
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr(__(\App\RegularType::RegularClass[$item->regular_class_6]), 0, 10)}}</span></td>
|
|
||||||
<!-- 定期種別12 -->
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr(__(\App\RegularType::RegularClass[$item->regular_class_12]), 0, 10)}}</span></td>
|
|
||||||
<!-- 備考 -->
|
|
||||||
<td class='sm-item text-right'><span>{{mb_substr($item->memo, 0, 10)}}</span></td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
<!-- ▲ 単一テーブル構成ここまで -->
|
||||||
</div>
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
</div>
|
<form action="{{ route('regular_types_export') }}" method="GET" id="form_export"></form>
|
||||||
<!-- /.row -->
|
|
||||||
</div><!-- /.container-fluid -->
|
|
||||||
</section>
|
|
||||||
<!-- /.content -->
|
|
||||||
|
|
||||||
@endsection
|
@endsection
|
||||||
@ -5,11 +5,12 @@
|
|||||||
<div class="content-header">
|
<div class="content-header">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row mb-2">
|
<div class="row mb-2">
|
||||||
<div class="col-lg-6"><h1 class="m-0 text-dark">{{ __('設定マスタ') }}</h1></div>
|
<div class="col-lg-6">
|
||||||
|
<h1 class="m-0 text-dark">{{ __('設定マスタ') }}</h1>
|
||||||
|
</div>
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<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="{{ route('home') }}">XX様info(ホーム)</a></li>
|
||||||
<li class="breadcrumb-item"><a href="javascript:void(0);">[東京都|〇〇駐輪場]</a></li>
|
|
||||||
<li class="breadcrumb-item active">{{ __('設定マスタ') }}</li>
|
<li class="breadcrumb-item active">{{ __('設定マスタ') }}</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
@ -27,14 +28,20 @@
|
|||||||
<input type="hidden" name="sort_type" id="sort_type" value="{{ $sort_type }}">
|
<input type="hidden" name="sort_type" id="sort_type" value="{{ $sort_type }}">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<div class="container-fluid mb20">
|
<!-- ツールバー -->
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('settings_add') }}'">{{ __('新規') }}</button>
|
<div class="container-fluid mb20 d-flex justify-content-between align-items-center">
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" form="form_delete">{{ __('削除') }}</button>
|
<div>
|
||||||
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('settings_add') }}'">
|
||||||
|
{{ __('新規') }}
|
||||||
|
</button>
|
||||||
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">{{ __('削除') }}</button>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
{{ $list->appends(['sort'=>$sort,'sort_type'=>$sort_type])->links('pagination') }}
|
{{ $list->appends(['sort'=>$sort,'sort_type'=>$sort_type])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
{{-- フラッシュ --}}
|
{{-- フラッシュメッセージ --}}
|
||||||
<div class="form col-lg-12">
|
<div class="form col-lg-12">
|
||||||
@if(Session::has('success'))
|
@if(Session::has('success'))
|
||||||
<div class="alert alert-success alert-dismissible" role="alert">
|
<div class="alert alert-success alert-dismissible" role="alert">
|
||||||
@ -56,57 +63,41 @@
|
|||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 sample03-wrapper no_padding_right mb20">
|
<!-- ▼ 単一テーブル構成 ----------------------------------------- -->
|
||||||
<form action="{{ route('settings_delete') }}" method="post" id="form_delete">
|
<div class="col-lg-12 mb20">
|
||||||
|
<div class="table-responsive">
|
||||||
|
<form action="{{ route('settings_delete') }}" method="POST" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<div class="scroll">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
{{-- 左:チェック+編集 --}}
|
<th style="width:140px;" class="text-left">
|
||||||
<th style="width:140px; background:#f9f9f9;">
|
<input type="checkbox" onclick="$('input[name*=\'pk\']').prop('checked', this.checked);">
|
||||||
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
|
||||||
</th>
|
</th>
|
||||||
|
<th sort="setting_id" class="sorting {{ ($sort=='setting_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}"><span>{{ __('設定ID') }}</span></th>
|
||||||
{{-- 右:本体 --}}
|
<th sort="edit_master" class="sorting {{ ($sort=='edit_master') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}"><span>{{ __('編集マスタ') }}</span></th>
|
||||||
<th sort="setting_id" class="sorting @if($sort=='setting_id'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-right">
|
<th sort="web_master" class="sorting {{ ($sort=='web_master') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}"><span>{{ __('ウェブ参照マスタ') }}</span></th>
|
||||||
{{ __('設定ID') }}
|
<th sort="auto_change_date" class="sorting {{ ($sort=='auto_change_date') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}"><span>{{ __('自動切替日時') }}</span></th>
|
||||||
</th>
|
<th><span>{{ __('自動切換え参照マスタ') }}</span></th>
|
||||||
<th sort="edit_master" class="sorting @if($sort=='edit_master'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-left">
|
<th sort="printable_alert_flag" class="sorting {{ ($sort=='printable_alert_flag') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}"><span>{{ __('印字残警告') }}</span></th>
|
||||||
{{ __('編集マスタ') }}
|
<th class="text-right"><span>{{ __('ロール紙印字可能数') }}</span></th>
|
||||||
</th>
|
<th class="text-right"><span>{{ __('ロール紙印字残警告数') }}</span></th>
|
||||||
<th sort="web_master" class="sorting @if($sort=='web_master'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-left">
|
<th class="text-right"><span>{{ __('キープアライブ(分)') }}</span></th>
|
||||||
{{ __('ウェブ参照マスタ') }}
|
|
||||||
</th>
|
|
||||||
<th sort="auto_change_date" class="sorting @if($sort=='auto_change_date'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-right">
|
|
||||||
{{ __('自動切替日時') }}
|
|
||||||
</th>
|
|
||||||
<th>{{ __('自動切換え参照マスタ') }}</th>
|
|
||||||
<th sort="printable_alert_flag" class="sorting @if($sort=='printable_alert_flag'){{ $sort_type=='asc'?'sorting_asc':'sorting_desc' }}@endif text-left">
|
|
||||||
{{ __('印字残警告') }}
|
|
||||||
</th>
|
|
||||||
<th class="text-right">{{ __('ロール紙印字可能数') }}</th>
|
|
||||||
<th class="text-right">{{ __('ロール紙印字残警告数') }}</th>
|
|
||||||
<th class="text-right">{{ __('キープアライブ(分)') }}</th>
|
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
|
|
||||||
<tbody>
|
<tbody>
|
||||||
@foreach($list as $row)
|
@foreach($list as $row)
|
||||||
<tr>
|
<tr>
|
||||||
{{-- 左:チェック+編集 --}}
|
<td class="table-warning align-middle">
|
||||||
<td class="sm-item text-left" style="background:#f9f9f9;">
|
<div class="d-flex align-items-center">
|
||||||
<input type="checkbox" class="minimal m-0 checkbox" name="id[]" value="{{ $row->setting_id }}">
|
<input type="checkbox" class="minimal m-0 checkbox" name="id[]" value="{{ $row->setting_id }}">
|
||||||
<div class="btn_action">
|
<a href="{{ route('settings_edit',['id'=>$row->setting_id]) }}" class="btn btn-sm btn-default ml-2">{{ __('編集') }}</a>
|
||||||
<a href="{{ route('settings_edit',['id'=>$row->setting_id]) }}" class="btn btn-sm btn-default ml10">{{ __('編集') }}</a>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
<td class="sm-item text-right align-middle">{{ $row->setting_id }}</td>
|
||||||
{{-- 右:本体 --}}
|
<td class="sm-item text-left align-middle">{{ $row->edit_master }}</td>
|
||||||
<td class="sm-item text-right">{{ $row->setting_id }}</td>
|
<td class="sm-item text-left align-middle">{{ $row->web_master }}</td>
|
||||||
<td class="sm-item text-left">{{ $row->edit_master }}</td>
|
<td class="sm-item text-right align-middle">
|
||||||
<td class="sm-item text-left">{{ $row->web_master }}</td>
|
|
||||||
<td class="sm-item text-right">
|
|
||||||
@php
|
@php
|
||||||
$dt = $row->auto_change_date instanceof \Carbon\Carbon
|
$dt = $row->auto_change_date instanceof \Carbon\Carbon
|
||||||
? $row->auto_change_date->format('Y/m/d H:i')
|
? $row->auto_change_date->format('Y/m/d H:i')
|
||||||
@ -114,41 +105,58 @@
|
|||||||
@endphp
|
@endphp
|
||||||
{{ $dt }}
|
{{ $dt }}
|
||||||
</td>
|
</td>
|
||||||
<td class="sm-item text-left">{{ $row->auto_chage_master }}</td>
|
<td class="sm-item text-left align-middle">{{ $row->auto_chage_master }}</td>
|
||||||
<td class="sm-item text-left">{{ $row->printable_alert_flag ? '○' : '' }}</td>
|
<td class="sm-item text-left align-middle">{{ $row->printable_alert_flag ? '○' : '' }}</td>
|
||||||
<td class="sm-item text-right">{{ $row->printable_number }}</td>
|
<td class="sm-item text-right align-middle">{{ $row->printable_number }}</td>
|
||||||
<td class="sm-item text-right">{{ $row->printable_alert_number }}</td>
|
<td class="sm-item text-right align-middle">{{ $row->printable_alert_number }}</td>
|
||||||
<td class="sm-item text-right">{{ $row->printer_keep_alive }}</td>
|
<td class="sm-item text-right align-middle">{{ $row->printer_keep_alive }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- ▲ 単一テーブル構成ここまで ----------------------------------------- -->
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
|
{{-- 一括削除 & ソート --}}
|
||||||
@push('scripts')
|
@push('scripts')
|
||||||
<script>
|
<script>
|
||||||
document.querySelectorAll('th.sorting[sort]').forEach(function(th){
|
// 全選択
|
||||||
th.style.cursor = 'pointer';
|
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
|
||||||
th.addEventListener('click', function(){
|
document.querySelectorAll('.checkbox').forEach(cb => cb.checked = e.target.checked);
|
||||||
var field = this.getAttribute('sort');
|
});
|
||||||
var cur = document.getElementById('sort').value;
|
|
||||||
var type = document.getElementById('sort_type').value || 'asc';
|
// 削除確認
|
||||||
var next = (cur === field && type === 'asc') ? 'desc' : 'asc';
|
document.getElementById('delete')?.addEventListener('click', function(){
|
||||||
document.getElementById('sort').value = field;
|
const anyChecked = Array.from(document.querySelectorAll('.checkbox')).some(cb => cb.checked);
|
||||||
document.getElementById('sort_type').value = next;
|
if (!anyChecked) {
|
||||||
document.getElementById('list-form').submit();
|
alert('削除対象が選択されていません。');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (confirm('削除してよろしいですか?')) {
|
||||||
|
document.getElementById('form_delete').submit();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
// ソート
|
||||||
|
document.querySelectorAll('th.sorting').forEach(th => {
|
||||||
|
th.addEventListener('click', function(){
|
||||||
|
const form = document.getElementById('list-form');
|
||||||
|
const current = "{{ $sort ?? '' }}";
|
||||||
|
const currentType = "{{ $sort_type ?? '' }}";
|
||||||
|
const nextCol = this.getAttribute('sort');
|
||||||
|
let nextType = 'asc';
|
||||||
|
if (current === nextCol) {
|
||||||
|
nextType = (currentType === 'asc') ? 'desc' : 'asc';
|
||||||
|
}
|
||||||
|
form.querySelector('[name=sort]').value = nextCol;
|
||||||
|
form.querySelector('[name=sort_type]').value = nextType;
|
||||||
|
form.submit();
|
||||||
|
});
|
||||||
});
|
});
|
||||||
});
|
|
||||||
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
|
|
||||||
document.querySelectorAll('.checkbox').forEach(function(cb){ cb.checked = e.target.checked; });
|
|
||||||
});
|
|
||||||
</script>
|
</script>
|
||||||
@endpush
|
@endpush
|
||||||
@endsection
|
@endsection
|
||||||
|
|||||||
@ -20,7 +20,7 @@
|
|||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('settlement_transactions_add') }}" class="btn btn-lg btn-success">{{ __('登録') }}</a>
|
<a href="{{ route('settlement_transactions_add') }}" class="btn btn-lg btn-success">{{ __('登録') }}</a>
|
||||||
<a href="{{ route('settlement_transactions_edit', ['settlement_transaction_id' => $transaction->settlement_transaction_id]) }}"
|
<a href="{{ route('settlement_transactions_edit', ['id' => $transaction->settlement_transaction_id]) }}"
|
||||||
class="btn btn-lg btn-danger">{{ __('編集') }}</a>
|
class="btn btn-lg btn-danger">{{ __('編集') }}</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-danger register">{{ __('保存') }}</button>
|
<button type="submit" class="btn btn-lg btn-danger register">{{ __('保存') }}</button>
|
||||||
@ -33,7 +33,7 @@
|
|||||||
{{-- 決済トランザクションID(編集/参照のみ) --}}
|
{{-- 決済トランザクションID(編集/参照のみ) --}}
|
||||||
@if($isInfo || $isEdit)
|
@if($isInfo || $isEdit)
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.settlement_transaction_id') }}</label>
|
<label>{{ __('決済トランザクションID') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -48,7 +48,7 @@
|
|||||||
|
|
||||||
{{-- 定期契約ID --}}
|
{{-- 定期契約ID --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label @if(!$isInfo) class="required" @endif>{{ __('validation.attributes.contract_id') }}</label>
|
<label @if(!$isInfo) class="required" @endif>{{ __('契約ID') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -62,7 +62,7 @@
|
|||||||
|
|
||||||
{{-- ステータス --}}
|
{{-- ステータス --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.status') }}</label>
|
<label>{{ __('ステータス') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -76,7 +76,7 @@
|
|||||||
|
|
||||||
{{-- 支払いコード --}}
|
{{-- 支払いコード --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.pay_code') }}</label>
|
<label>{{ __('支払いコード') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -90,7 +90,7 @@
|
|||||||
|
|
||||||
{{-- 受付番号 --}}
|
{{-- 受付番号 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.contract_payment_number') }}</label>
|
<label>{{ __('受付番号') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -104,7 +104,7 @@
|
|||||||
|
|
||||||
{{-- 企業コード --}}
|
{{-- 企業コード --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.corp_code') }}</label>
|
<label>{{ __('企業コード') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -118,7 +118,7 @@
|
|||||||
|
|
||||||
{{-- MMS予約照会日時 --}}
|
{{-- MMS予約照会日時 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.mms_date') }}</label>
|
<label>{{ __('MMS予約照会日時') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -132,7 +132,7 @@
|
|||||||
|
|
||||||
{{-- CVS本部コード --}}
|
{{-- CVS本部コード --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.cvs_code') }}</label>
|
<label>{{ __('CVS本部コード') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -146,7 +146,7 @@
|
|||||||
|
|
||||||
{{-- 店舗コード --}}
|
{{-- 店舗コード --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.shop_code') }}</label>
|
<label>{{ __('店舗コード') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -160,7 +160,7 @@
|
|||||||
|
|
||||||
{{-- 入金日時(DBはdatetime。画面はdateで日付入力を想定) --}}
|
{{-- 入金日時(DBはdatetime。画面はdateで日付入力を想定) --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.pay_date') }}</label>
|
<label>{{ __('入金日時') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -174,7 +174,7 @@
|
|||||||
|
|
||||||
{{-- 決済金額 --}}
|
{{-- 決済金額 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.settlement_amount') }}</label>
|
<label>{{ __('決済金額') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -188,7 +188,7 @@
|
|||||||
|
|
||||||
{{-- 印紙貼付フラグ --}}
|
{{-- 印紙貼付フラグ --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.stamp_flag') }}</label>
|
<label>{{ __('印紙貼付フラグ') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -202,7 +202,7 @@
|
|||||||
|
|
||||||
{{-- MD5ハッシュ値 --}}
|
{{-- MD5ハッシュ値 --}}
|
||||||
<div class="form-group col-3">
|
<div class="form-group col-3">
|
||||||
<label>{{ __('validation.attributes.md5_string') }}</label>
|
<label>{{ __('MD5ハッシュ値') }}</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group col-9">
|
<div class="form-group col-9">
|
||||||
<div class="input-group">
|
<div class="input-group">
|
||||||
@ -219,7 +219,7 @@
|
|||||||
{{-- 下部ボタン(上部と同じ) --}}
|
{{-- 下部ボタン(上部と同じ) --}}
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('settlement_transactions_add') }}" class="btn btn-lg btn-success">{{ __('登録') }}</a>
|
<a href="{{ route('settlement_transactions_add') }}" class="btn btn-lg btn-success">{{ __('登録') }}</a>
|
||||||
<a href="{{ route('settlement_transactions_edit', ['settlement_transaction_id' => $transaction->settlement_transaction_id]) }}"
|
<a href="{{ route('settlement_transactions_edit', ['id' => $transaction->settlement_transaction_id]) }}"
|
||||||
class="btn btn-lg btn-danger">{{ __('編集') }}</a>
|
class="btn btn-lg btn-danger">{{ __('編集') }}</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-danger register">{{ __('保存') }}</button>
|
<button type="submit" class="btn btn-lg btn-danger register">{{ __('保存') }}</button>
|
||||||
|
|||||||
@ -28,7 +28,7 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<form method="POST" action="{{ route('settlement_transactions_edit', ['settlement_transaction_id' => $transaction->settlement_transaction_id]) }}" enctype="multipart/form-data">
|
<form method="POST" action="{{ route('settlement_transactions_edit', ['id' => $transaction->settlement_transaction_id]) }}" enctype="multipart/form-data">
|
||||||
@csrf
|
@csrf
|
||||||
@include('admin.settlement_transactions._form', [
|
@include('admin.settlement_transactions._form', [
|
||||||
'transaction' => $transaction,
|
'transaction' => $transaction,
|
||||||
|
|||||||
@ -2,24 +2,23 @@
|
|||||||
@section('title', '[東京都|〇〇駐輪場] 決済トランザクション')
|
@section('title', '[東京都|〇〇駐輪場] 決済トランザクション')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<div class="content-header">
|
<div class="content-header">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row mb-2">
|
<div class="row mb-2">
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<h1 class="m-0 text-dark">{{ __('決済トランザクション') }}</h1>
|
<h1 class="m-0 text-dark">決済トランザクション</h1>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<ol class="breadcrumb float-sm-right text-sm">
|
||||||
<li class="breadcrumb-item"><a href="{{ route('home') }}">{{ __('ホーム') }}</a></li>
|
<li class="breadcrumb-item"><a href="{{ route('home') }}">XX様info(ホーム)</a></li>
|
||||||
<li class="breadcrumb-item active">{{ __('決済トランザクション') }}</li>
|
<li class="breadcrumb-item active">決済トランザクション</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- /.content-header -->
|
|
||||||
|
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<!-- 絞り込みフィルター -->
|
<!-- 絞り込みフィルター -->
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
@ -27,8 +26,8 @@
|
|||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<form action="{{ route('settlement_transactions') }}" method="POST" id="list-form">
|
<form action="{{ route('settlement_transactions') }}" method="POST" id="list-form">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="sort" id="sort" value="{{ $sort ?? '' }}">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" name="sort_type" id="sort_type" value="{{ $sort_type ?? '' }}">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="form-group col-12">
|
<div class="form-group col-12">
|
||||||
@ -46,20 +45,19 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
|
<!-- ツールバー -->
|
||||||
<div class="row">
|
|
||||||
{{-- ソート保持用 --}}
|
|
||||||
<form action="{{ route('settlement_transactions') }}" method="POST" id="list-form">
|
|
||||||
@csrf
|
|
||||||
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
|
||||||
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
|
||||||
</form>
|
|
||||||
|
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20">
|
||||||
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('settlement_transactions_add') }}'">新規</button>
|
||||||
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">{{ __('CSV出力') }}</button>
|
||||||
|
<div class="d-flex justify-content-end">
|
||||||
{{ $transactions->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
{{ $transactions->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- メッセージ表示 -->
|
||||||
<div class="form col-lg-12">
|
<div class="form col-lg-12">
|
||||||
@if(Session::has('success'))
|
@if(Session::has('success'))
|
||||||
<div class="alert alert-success alert-dismissible" role="alert">
|
<div class="alert alert-success alert-dismissible" role="alert">
|
||||||
@ -81,116 +79,84 @@
|
|||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<!-- ▼ 単一テーブル構成 ----------------------------------------- -->
|
||||||
{{-- 左:チェック&操作 --}}
|
<div class="col-lg-12 mb20">
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<div class="table-responsive">
|
||||||
<form action="{{ route('settlement_transactions_delete') }}" method="POST" id="form_delete">
|
<form action="{{ route('settlement_transactions_delete') }}" method="POST" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>
|
<th style="width:140px;" class="text-left">
|
||||||
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
<input type="checkbox" onclick="$('input[name*=\'pk\']').prop('checked', this.checked);">
|
||||||
</th>
|
</th>
|
||||||
|
|
||||||
|
<th class="sorting {{ ($sort=='settlement_transaction_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="settlement_transaction_id"><span>決済トランザクションID</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='contract_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="contract_id"><span>定期契約ID</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='status') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="status"><span>ステータス</span></th>
|
||||||
|
<th><span>決済コード</span></th>
|
||||||
|
<th><span>決済番号</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='corp_code') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="corp_code"><span>企業コード</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='mms_date') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="mms_date"><span>MMS日付</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='cvs_code') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="cvs_code"><span>CVSコード</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='shop_code') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="shop_code"><span>店舗コード</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='pay_date') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="pay_date"><span>支払日</span></th>
|
||||||
|
<th><span>決済金額</span></th>
|
||||||
|
<th><span>スタンプ</span></th>
|
||||||
|
<th><span>MD5文字列</span></th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@foreach($transactions as $item)
|
@foreach($transactions as $item)
|
||||||
<tr role="row">
|
<tr>
|
||||||
<td>
|
<td class="table-warning align-middle">
|
||||||
<input type="checkbox" class="minimal m-0 checkbox"
|
<div class="d-flex align-items-center">
|
||||||
value="{{ $item->settlement_transaction_id }}" name="ids[]">
|
<input type="checkbox" class="m-0 checkbox" name="pk[]" value="{{ $item->settlement_transaction_id }}">
|
||||||
<div class="btn_action">
|
<a href="{{ route('settlement_transactions_edit', ['id' => $item->settlement_transaction_id]) }}" class="btn btn-sm btn-default ml-2">編集</a>
|
||||||
<a href="{{ route('settlement_transactions_edit', ['settlement_transaction_id' => $item->settlement_transaction_id]) }}"
|
|
||||||
class="btn btn-sm btn-default ml10">{{ __('編集') }}</a>
|
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->settlement_transaction_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->contract_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->status }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->pay_code }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->contract_payment_number }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->corp_code }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->mms_date }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->cvs_code }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->shop_code }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ optional($item->pay_date)->format('Y-m-d H:i') }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->settlement_amount }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->stamp_flag }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $item->md5_string }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{-- 右:データ一覧 --}}
|
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th class="sorting {{ ($sort=='settlement_transaction_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="settlement_transaction_id">
|
|
||||||
<span>{{ __('validation.attributes.settlement_transaction_id') }}</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='contract_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="contract_id">
|
|
||||||
<span>{{ __('validation.attributes.contract_id') }}</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='status') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="status">
|
|
||||||
<span>{{ __('validation.attributes.status') }}</span>
|
|
||||||
</th>
|
|
||||||
<th><span>{{ __('validation.attributes.pay_code') }}</span></th>
|
|
||||||
<th><span>{{ __('validation.attributes.contract_payment_number') }}</span></th>
|
|
||||||
<th class="sorting {{ ($sort=='corp_code') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="corp_code">
|
|
||||||
<span>{{ __('validation.attributes.corp_code') }}</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='mms_date') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="mms_date">
|
|
||||||
<span>{{ __('validation.attributes.mms_date') }}</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='cvs_code') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="cvs_code">
|
|
||||||
<span>{{ __('validation.attributes.cvs_code') }}</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='shop_code') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="shop_code">
|
|
||||||
<span>{{ __('validation.attributes.shop_code') }}</span>
|
|
||||||
</th>
|
|
||||||
<th class="sorting {{ ($sort=='pay_date') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="pay_date">
|
|
||||||
<span>{{ __('validation.attributes.pay_date') }}</span>
|
|
||||||
</th>
|
|
||||||
<th><span>{{ __('validation.attributes.settlement_amount') }}</span></th>
|
|
||||||
<th><span>{{ __('validation.attributes.stamp_flag') }}</span></th>
|
|
||||||
<th><span>{{ __('validation.attributes.md5_string') }}</span></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($transactions as $item)
|
|
||||||
<tr>
|
|
||||||
<td class="sm-item text-left">{{ $item->settlement_transaction_id }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->contract_id }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->status }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->pay_code }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->contract_payment_number }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->corp_code }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->mms_date }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->cvs_code }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->shop_code }}</td>
|
|
||||||
<td class="sm-item text-left">{{ optional($item->pay_date)->format('Y-m-d H:i') }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->settlement_amount }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->stamp_flag }}</td>
|
|
||||||
<td class="sm-item text-left">{{ $item->md5_string }}</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
</div>
|
||||||
|
<!-- ▲ 単一テーブル構成ここまで ----------------------------------------- -->
|
||||||
</div>
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
</div>
|
<form action="{{ route('settlement_transactions_export') }}" method="GET" id="form_export"></form>
|
||||||
</div>
|
|
||||||
|
|
||||||
</div>
|
@push('scripts')
|
||||||
</section>
|
<script>
|
||||||
|
|
||||||
|
|
||||||
@push('scripts')
|
|
||||||
<script>
|
|
||||||
// 全選択
|
// 全選択
|
||||||
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
|
document.getElementById('checkbox_all')?.addEventListener('change', function(e){
|
||||||
document.querySelectorAll('.checkbox').forEach(cb => cb.checked = e.target.checked);
|
document.querySelectorAll('.checkbox').forEach(cb => cb.checked = e.target.checked);
|
||||||
});
|
});
|
||||||
|
|
||||||
// 削除
|
// 削除確認
|
||||||
document.getElementById('delete')?.addEventListener('click', function(){
|
document.getElementById('delete')?.addEventListener('click', function(){
|
||||||
const anyChecked = Array.from(document.querySelectorAll('.checkbox')).some(cb => cb.checked);
|
const anyChecked = Array.from(document.querySelectorAll('.checkbox')).some(cb => cb.checked);
|
||||||
if (!anyChecked) { alert('{{ __("削除対象が選択されていません。") }}'); return; }
|
if (!anyChecked) {
|
||||||
if (confirm('{{ __("削除してよろしいですか?") }}')) {
|
alert('削除対象が選択されていません。');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (confirm('削除してよろしいですか?')) {
|
||||||
document.getElementById('form_delete').submit();
|
document.getElementById('form_delete').submit();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -211,19 +177,6 @@
|
|||||||
form.submit();
|
form.submit();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
</script>
|
||||||
// インポート:ファイル選択→自動送信(必要ならUIを別途用意)
|
@endpush
|
||||||
const importBtn = document.querySelector('button[form="form_import"]');
|
|
||||||
const importInput = document.getElementById('import_file');
|
|
||||||
importBtn?.addEventListener('click', function(e){
|
|
||||||
e.preventDefault();
|
|
||||||
importInput.click();
|
|
||||||
});
|
|
||||||
importInput?.addEventListener('change', function(){
|
|
||||||
if (this.files.length > 0) {
|
|
||||||
document.getElementById('form_import').submit();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
</script>
|
|
||||||
@endpush
|
|
||||||
@endsection
|
@endsection
|
||||||
|
|||||||
@ -12,7 +12,7 @@
|
|||||||
@endif
|
@endif
|
||||||
|
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<a href="{{ route('neighbor_stations') }}" class="btn btn-secondary">戻る</a>
|
<a href="{{ route('stations') }}" class="btn btn-secondary">戻る</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
@ -11,7 +11,7 @@
|
|||||||
<div class="col-lg-6">
|
<div class="col-lg-6">
|
||||||
<ol class="breadcrumb float-sm-right text-sm">
|
<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="{{ route('home') }}">XX様info(ホーム)</a></li>
|
||||||
<li class="breadcrumb-item"><a href="{{ route('neighbor_stations') }}">[東京都|〇〇駐輪場]</a></li>
|
<li class="breadcrumb-item"><a href="{{ route('stations') }}">[東京都|〇〇駐輪場]</a></li>
|
||||||
<li class="breadcrumb-item active">[東京都|〇〇駐輪場] 近傍駅マスタ</li>
|
<li class="breadcrumb-item active">[東京都|〇〇駐輪場] 近傍駅マスタ</li>
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
@ -23,7 +23,7 @@
|
|||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<div class="row justify-content-center">
|
<div class="row justify-content-center">
|
||||||
<div class="col-md-8">
|
<div class="col-md-8">
|
||||||
<form method="POST" action="{{ route('neighbor_station_add') }}">
|
<form method="POST" action="{{ route('stations_add') }}">
|
||||||
@csrf
|
@csrf
|
||||||
|
|
||||||
<table class="table table-bordered">
|
<table class="table table-bordered">
|
||||||
@ -113,7 +113,7 @@
|
|||||||
<button type="button" class="btn btn-danger ml-3" onclick="confirmDelete()">削除</button>
|
<button type="button" class="btn btn-danger ml-3" onclick="confirmDelete()">削除</button>
|
||||||
|
|
||||||
<form id="delete-form" method="POST"
|
<form id="delete-form" method="POST"
|
||||||
action="{{ route('neighbor_stations_delete') }}"
|
action="{{ route('stations_delete') }}"
|
||||||
style="display:none;">
|
style="display:none;">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="pk[]" value="{{ old('station_id') ?? 0 }}">
|
<input type="hidden" name="pk[]" value="{{ old('station_id') ?? 0 }}">
|
||||||
@ -27,9 +27,9 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="card">
|
<div class="card">
|
||||||
<form method="post" action="{{ route('neighbor_station_edit', ['id' => $station->station_id]) }}" enctype="multipart/form-data">
|
<form method="post" action="{{ route('stations_edit', ['id' => $station->station_id]) }}" enctype="multipart/form-data">
|
||||||
@csrf
|
@csrf
|
||||||
@include('admin.neighbor_stations._form', ['isEdit' => 1, 'isInfo' => 0, 'station' => $station])
|
@include('admin.stations._form', ['isEdit' => 1, 'isInfo' => 0, 'station' => $station])
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -1,10 +1,9 @@
|
|||||||
{{-- resources/views/admin/neighbor_stations/import.blade.php --}}
|
|
||||||
@extends('layouts.admin')
|
@extends('layouts.admin')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<h1>近傍駅 インポート</h1>
|
<h1>近傍駅 インポート</h1>
|
||||||
|
|
||||||
<form method="POST" action="{{ route('neighbor_stations_import') }}" enctype="multipart/form-data">
|
<form method="POST" action="{{ route('stations_import') }}" enctype="multipart/form-data">
|
||||||
@csrf
|
@csrf
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="csv_file">CSVファイルを選択:</label>
|
<label for="csv_file">CSVファイルを選択:</label>
|
||||||
@ -13,5 +12,5 @@
|
|||||||
<button type="submit" class="btn btn-primary">アップロード</button>
|
<button type="submit" class="btn btn-primary">アップロード</button>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<a href="{{ route('neighbor_stations') }}" class="btn btn-secondary mt-3">戻る</a>
|
<a href="{{ route('stations') }}" class="btn btn-secondary mt-3">戻る</a>
|
||||||
@endsection
|
@endsection
|
||||||
@ -1,4 +1,3 @@
|
|||||||
{{-- resources/views/admin/neighbor_stations/info.blade.php --}}
|
|
||||||
@extends('layouts.admin')
|
@extends('layouts.admin')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
@ -21,5 +20,5 @@
|
|||||||
<p>{{ $station->operator_id }}</p>
|
<p>{{ $station->operator_id }}</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<a href="{{ route('neighbor_stations') }}" class="btn btn-secondary">戻る</a>
|
<a href="{{ route('stations') }}" class="btn btn-secondary">戻る</a>
|
||||||
@endsection
|
@endsection
|
||||||
117
resources/views/admin/stations/list.blade.php
Normal file
117
resources/views/admin/stations/list.blade.php
Normal file
@ -0,0 +1,117 @@
|
|||||||
|
@extends('layouts.app')
|
||||||
|
@section('title', '[東京都|〇〇駐輪場] 近傍駅マスタ')
|
||||||
|
|
||||||
|
@section('content')
|
||||||
|
<!-- Content Header -->
|
||||||
|
<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>
|
||||||
|
|
||||||
|
<!-- Main Content -->
|
||||||
|
<section class="content">
|
||||||
|
<div class="container-fluid">
|
||||||
|
{{-- 並び替え用 hidden --}}
|
||||||
|
<form action="{{ route('stations') }}" method="POST" id="list-form">
|
||||||
|
@csrf
|
||||||
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
|
</form>
|
||||||
|
|
||||||
|
<div class="container-fluid mb20">
|
||||||
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('stations_add') }}'">新規</button>
|
||||||
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">{{ __('CSV出力') }}</button>
|
||||||
|
<div class="d-flex justify-content-end">
|
||||||
|
{{ $stations->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
|
</div>
|
||||||
|
</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>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
<!-- メッセージ表示 -->
|
||||||
|
<div class="col-lg-12">
|
||||||
|
@if(session('success'))
|
||||||
|
<div class="alert alert-success alert-dismissible">{{ session('success') }}</div>
|
||||||
|
@elseif(session('error'))
|
||||||
|
<div class="alert alert-danger alert-dismissible">{{ session('error') }}</div>
|
||||||
|
@endif
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- ▼ ここから単一テーブル構成 ----------------------------------------- -->
|
||||||
|
<div class="col-lg-12 mb20">
|
||||||
|
<div class="table-responsive">
|
||||||
|
<form action="{{ route('stations_delete') }}" method="POST" id="form_delete">
|
||||||
|
@csrf
|
||||||
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
{{-- ★ チェック + 編集 用の1列 --}}
|
||||||
|
<th style="width:120px;" class="text-left">
|
||||||
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
|
</th>
|
||||||
|
<th class="sorting {{ ($sort=='station_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="station_id"><span>近傍駅ID</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='park_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="park_id"><span>駐車場ID</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='station_neighbor_station') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="station_neighbor_station"><span>近傍駅</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='station_name_ruby') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="station_name_ruby"><span>近傍駅ふりがな</span></th>
|
||||||
|
<th class="sorting {{ ($sort=='station_route_name') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="station_route_name"><span>路線名</span></th>
|
||||||
|
<th><span>近傍駅座標(緯度)</span></th>
|
||||||
|
<th><span>近傍駅座標(経度)</span></th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
<tbody>
|
||||||
|
@foreach($stations as $station)
|
||||||
|
<tr>
|
||||||
|
{{-- ★ 同じセル内に チェック + 編集ボタン) --}}
|
||||||
|
<td class="table-warning align-middle">
|
||||||
|
<div class="d-flex align-items-center">
|
||||||
|
<input type="checkbox" class="minimal m-0 checkbox" name="pk[]" value="{{ $station->station_id }}">
|
||||||
|
<a href="{{ route('stations_edit', ['id' => $station->station_id]) }}"
|
||||||
|
class="btn btn-sm btn-default ml-2">{{ __('編集') }}</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td class="sm-item text-left align-middle">{{ $station->station_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $station->park_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $station->station_neighbor_station }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $station->station_name_ruby }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $station->station_route_name }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $station->station_latitude }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $station->station_longitude }}</td>
|
||||||
|
</tr>
|
||||||
|
@endforeach
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- ▲ 単一テーブル構成ここまで ----------------------------------------- -->
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
<form action="{{ route('stations_export') }}" method="GET" id="form_export"></form>
|
||||||
|
@endsection
|
||||||
@ -9,7 +9,7 @@
|
|||||||
{{-- 登録・削除 ボタン(上部) --}}
|
{{-- 登録・削除 ボタン(上部) --}}
|
||||||
<div class="text-left mt-2 mb-3">
|
<div class="text-left mt-2 mb-3">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('tax_edit', ['tax_id' => $tax->tax_id]) }}" class="btn btn-lg btn-success">編集</a>
|
<a href="{{ route('tax_edit', ['id' => $tax->tax_id]) }}" class="btn btn-lg btn-success">編集</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn成功 btn-success">登録</button>
|
<button type="submit" class="btn btn-lg btn成功 btn-success">登録</button>
|
||||||
@if($isEdit)
|
@if($isEdit)
|
||||||
@ -66,7 +66,7 @@
|
|||||||
{{-- 登録・削除 ボタン(下部重ね) --}}
|
{{-- 登録・削除 ボタン(下部重ね) --}}
|
||||||
<div class="text-left mt-2">
|
<div class="text-left mt-2">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('tax_edit', ['tax_id' => $tax->tax_id]) }}" class="btn btn-lg btn-success">編集</a>
|
<a href="{{ route('tax_edit', ['id' => $tax->tax_id]) }}" class="btn btn-lg btn-success">編集</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
||||||
@if($isEdit)
|
@if($isEdit)
|
||||||
|
|||||||
@ -21,7 +21,7 @@
|
|||||||
|
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<form action="{{ route('tax_edit', ['tax_id' => $tax->tax_id]) }}" method="POST">
|
<form action="{{ route('tax_edit', ['id' => $tax->tax_id]) }}" method="POST">
|
||||||
@csrf
|
@csrf
|
||||||
@include('admin.tax._form', [
|
@include('admin.tax._form', [
|
||||||
'tax' => $tax,
|
'tax' => $tax,
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
@extends('layouts.app')
|
@extends('layouts.app')
|
||||||
@section('title', '消費税マスタ')
|
@section('title', '[東京都|〇〇駐輪場] 消費税マスタ')
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<!-- Content Header -->
|
<!-- Content Header -->
|
||||||
@ -23,60 +23,51 @@
|
|||||||
<!-- Main Content -->
|
<!-- Main Content -->
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
{{-- 一覧のソート用(既存規約踏襲) --}}
|
{{-- 並び替え用 hidden --}}
|
||||||
<form action="{{ route('tax') }}" method="POST" id="list-form">
|
<form action="{{ route('tax') }}" method="POST" id="list-form">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
<!-- ツールバー -->
|
||||||
<div class="container-fluid mb20">
|
<div class="container-fluid mb20">
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('tax_add') }}'">新規</button>
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('tax_add') }}'">新規</button>
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">{{ __('CSV出力') }}</button>
|
||||||
|
<div class="d-flex justify-content-end">
|
||||||
{{ $taxes->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
{{ $taxes->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12">
|
<!-- メッセージ表示 -->
|
||||||
@if(session('success'))
|
<div class="form col-lg-12">
|
||||||
<div class="alert alert-success alert-dismissible">{{ session('success') }}</div>
|
@if(Session::has('success'))
|
||||||
@elseif(session('error'))
|
<div class="alert alert-success alert-dismissible" role="alert">
|
||||||
<div class="alert alert-danger alert-dismissible">{{ session('error') }}</div>
|
<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>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<!-- ▼ 単一テーブル構成 ----------------------------------------- -->
|
||||||
<!-- 左側チェックボックス&編集ボタン -->
|
<div class="col-lg-12 mb20">
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<div class="table-responsive">
|
||||||
<form action="{{ route('tax_delete') }}" method="POST" id="form_delete">
|
<form action="{{ route('tax_delete') }}" method="POST" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th><input type="checkbox" class="minimal m-0" id="checkbox_all"></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($taxes as $tax)
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
<input type="checkbox" class="minimal m-0 checkbox" value="{{ $tax->tax_id }}" name="id[]">
|
|
||||||
<div class="btn_action">
|
|
||||||
<a href="{{ route('tax_edit', ['tax_id' => $tax->tax_id]) }}" class="btn btn-sm btn-default ml10">編集</a>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- 右側データテーブル -->
|
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
|
{{-- チェック + 編集 --}}
|
||||||
|
<th style="width:120px;" class="text-left">
|
||||||
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
|
</th>
|
||||||
<th class="sorting {{ ($sort=='tax_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="tax_id">
|
<th class="sorting {{ ($sort=='tax_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="tax_id">
|
||||||
<span>消費税ID</span>
|
<span>消費税ID</span>
|
||||||
</th>
|
</th>
|
||||||
@ -91,30 +82,37 @@
|
|||||||
<tbody>
|
<tbody>
|
||||||
@foreach($taxes as $tax)
|
@foreach($taxes as $tax)
|
||||||
<tr>
|
<tr>
|
||||||
<td class="sm-item text-left">{{ $tax->tax_id }}</td>
|
{{-- 同じセルに チェック + 編集ボタン --}}
|
||||||
<td class="sm-item text-left">
|
<td class="table-warning align-middle">
|
||||||
|
<div class="d-flex align-items-center">
|
||||||
|
<input type="checkbox" class="minimal m-0 checkbox" name="id[]" value="{{ $tax->tax_id }}">
|
||||||
|
<a href="{{ route('tax_edit', ['id' => $tax->tax_id]) }}" class="btn btn-sm btn-default ml-2">編集</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $tax->tax_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">
|
||||||
@php
|
@php
|
||||||
|
|
||||||
$val = is_numeric($tax->tax_percent)
|
$val = is_numeric($tax->tax_percent)
|
||||||
? number_format((float)$tax->tax_percent, 2, '.', '')
|
? number_format((float)$tax->tax_percent, 2, '.', '')
|
||||||
: (string)$tax->tax_percent;
|
: (string)$tax->tax_percent;
|
||||||
@endphp
|
@endphp
|
||||||
{{ $val }}%
|
{{ $val }}%
|
||||||
</td>
|
</td>
|
||||||
<td class="sm-item text-left">{{ optional($tax->tax_day)->format('Y-m-d') }}</td>
|
<td class="sm-item text-left align-middle">{{ optional($tax->tax_day)->format('Y-m-d') }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<!-- ▲ 単一テーブル構成ここまで ----------------------------------------- -->
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<form action="{{ route('tax_export') }}" method="GET" id="form_export"></form>
|
<form action="{{ route('tax_export') }}" method="GET" id="form_export"></form>
|
||||||
|
|
||||||
{{-- 一括削除 & ソートのJS(既存規約に合わせ最小限) --}}
|
|
||||||
@push('scripts')
|
@push('scripts')
|
||||||
<script>
|
<script>
|
||||||
// 全選択
|
// 全選択
|
||||||
@ -134,7 +132,7 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// ヘッダクリックでソート変更(既存 list と同様のカスタム属性 "sort" を使用)
|
// ヘッダクリックでソート
|
||||||
document.querySelectorAll('th.sorting').forEach(th => {
|
document.querySelectorAll('th.sorting').forEach(th => {
|
||||||
th.addEventListener('click', function(){
|
th.addEventListener('click', function(){
|
||||||
const form = document.getElementById('list-form');
|
const form = document.getElementById('list-form');
|
||||||
|
|||||||
@ -9,7 +9,7 @@
|
|||||||
{{-- 登録・削除 ボタン --}}
|
{{-- 登録・削除 ボタン --}}
|
||||||
<div class="text-left mt-4">
|
<div class="text-left mt-4">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('terms_edit', ['term_id' => $term->terms_id]) }}" class="btn btn-lg btn-success">編集</a>
|
<a href="{{ route('terms_edit', ['id' => $term->terms_id]) }}" class="btn btn-lg btn-success">編集</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
||||||
@if($isEdit)
|
@if($isEdit)
|
||||||
@ -98,7 +98,7 @@
|
|||||||
{{-- 登録・削除 ボタン --}}
|
{{-- 登録・削除 ボタン --}}
|
||||||
<div class="text-left mt-4">
|
<div class="text-left mt-4">
|
||||||
@if($isInfo)
|
@if($isInfo)
|
||||||
<a href="{{ route('terms_edit', ['term_id' => $term->terms_id]) }}" class="btn btn-lg btn-success">編集</a>
|
<a href="{{ route('terms_edit', ['id' => $term->terms_id]) }}" class="btn btn-lg btn-success">編集</a>
|
||||||
@else
|
@else
|
||||||
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
<button type="submit" class="btn btn-lg btn-success">登録</button>
|
||||||
@if($isEdit)
|
@if($isEdit)
|
||||||
|
|||||||
@ -21,7 +21,7 @@
|
|||||||
|
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
<form action="{{ route('terms_edit', ['term_id' => $term->terms_id]) }}" method="POST">
|
<form action="{{ route('terms_edit', ['id' => $term->terms_id]) }}" method="POST">
|
||||||
@csrf
|
@csrf
|
||||||
@include('admin.terms._form', [
|
@include('admin.terms._form', [
|
||||||
'term' => $term,
|
'term' => $term,
|
||||||
|
|||||||
@ -23,60 +23,52 @@
|
|||||||
<!-- Main Content -->
|
<!-- Main Content -->
|
||||||
<section class="content">
|
<section class="content">
|
||||||
<div class="container-fluid">
|
<div class="container-fluid">
|
||||||
|
{{-- 並び替え用 hidden --}}
|
||||||
<form action="{{ route('terms') }}" method="POST" id="list-form">
|
<form action="{{ route('terms') }}" method="POST" id="list-form">
|
||||||
@csrf
|
@csrf
|
||||||
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<div class="container-fluid mb20">
|
<!-- 操作ボタン&ページネーション -->
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('terms_add') }}'"> 新規</button>
|
<div class="container-fluid mb20 d-flex justify-content-between align-items-center">
|
||||||
|
<div>
|
||||||
|
<button type="button" class="btn btn-sm btn-default mr10" onclick="location.href='{{ route('terms_add') }}'">新規</button>
|
||||||
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
<button type="button" class="btn btn-sm btn-default mr10" id="delete">削除</button>
|
||||||
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">CSV出力</button>
|
<button type="submit" class="btn btn-sm btn-default mr10" form="form_export">CSV出力</button>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
{{ $terms->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
{{ $terms->appends(['sort' => $sort ?? '', 'sort_type' => $sort_type ?? ''])->links('pagination') }}
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- メッセージ表示 -->
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
@if(session('success'))
|
@if(session('success'))
|
||||||
<div class="alert alert-success alert-dismissible">{{ session('success') }}</div>
|
<div class="alert alert-success alert-dismissible" role="alert">
|
||||||
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||||
|
{{ session('success') }}
|
||||||
|
</div>
|
||||||
@elseif(session('error'))
|
@elseif(session('error'))
|
||||||
<div class="alert alert-danger alert-dismissible">{{ session('error') }}</div>
|
<div class="alert alert-danger alert-dismissible" role="alert">
|
||||||
|
<button type="button" class="close" data-dismiss="alert" aria-hidden="true">×</button>
|
||||||
|
{{ session('error') }}
|
||||||
|
</div>
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-lg-12 row sample03-wrapper no_padding_right mb20">
|
<!-- ▼ 単一テーブル構成 -->
|
||||||
<!-- 左側チェックボックス&編集ボタン -->
|
<div class="col-lg-12 mb20">
|
||||||
<div class="col-xl-2 col-lg-2 col-md-2 col-sm-3 col-xs-3 table_left">
|
<div class="table-responsive">
|
||||||
<form action="{{ route('terms_delete') }}" method="POST" id="form_delete">
|
<form action="{{ route('terms_delete') }}" method="POST" id="form_delete">
|
||||||
@csrf
|
@csrf
|
||||||
<table class="table dataTable">
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th><input type="checkbox" class="minimal m-0" id="checkbox_all"></th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
@foreach($terms as $term)
|
|
||||||
<tr>
|
|
||||||
<td>
|
|
||||||
<input type="checkbox" class="minimal m-0 checkbox" value="{{ $term->terms_id }}" name="id[]">
|
|
||||||
<div class="btn_action">
|
|
||||||
<a href="{{ route('terms_edit', ['term_id' => $term->terms_id]) }}" class="btn btn-sm btn-default ml10">編集</a>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@endforeach
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- 右側データテーブル -->
|
|
||||||
<div class="col-lg-10 col-xl-10 col-md-10 col-sm-9 col-xs-9 table_right no_padding_right">
|
|
||||||
<div class="scroll">
|
|
||||||
<table class="table dataTable">
|
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
|
{{-- ★ チェック + 編集 用の1列 --}}
|
||||||
|
<th style="width:120px;" class="text-left">
|
||||||
|
<input type="checkbox" class="minimal m-0" id="checkbox_all">
|
||||||
|
</th>
|
||||||
<th class="sorting {{ ($sort=='terms_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="terms_id">
|
<th class="sorting {{ ($sort=='terms_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="terms_id">
|
||||||
<span>利用契約ID</span>
|
<span>利用契約ID</span>
|
||||||
</th>
|
</th>
|
||||||
@ -90,26 +82,34 @@
|
|||||||
<th class="sorting {{ ($sort=='start_date') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="start_date">
|
<th class="sorting {{ ($sort=='start_date') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="start_date">
|
||||||
<span>使用開始日</span>
|
<span>使用開始日</span>
|
||||||
</th>
|
</th>
|
||||||
|
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@foreach($terms as $term)
|
@foreach($terms as $term)
|
||||||
<tr>
|
<tr>
|
||||||
<td class="sm-item text-left">{{ $term->terms_id }}</td>
|
{{-- ★ チェックボックス + 編集ボタン --}}
|
||||||
<td class="sm-item text-left">{{ $term->city_id }}</td>
|
<td class="table-warning align-middle">
|
||||||
<td class="sm-item text-left">{{ $term->use_flag ? '○' : '' }}</td>
|
<div class="d-flex align-items-center">
|
||||||
<td class="sm-item text-left">{{ $term->terms_revision }}</td>
|
<input type="checkbox" class="minimal m-0 checkbox" name="pk[]" value="{{ $term->terms_id }}">
|
||||||
<td class="sm-item text-left">{{ $term->terms_text }}</td>
|
<a href="{{ route('terms_edit', ['id' => $term->terms_id]) }}"
|
||||||
<td class="sm-item text-left">{{ $term->memo }}</td>
|
class="btn btn-sm btn-default ml-2">{{ __('編集') }}</a>
|
||||||
<td class="sm-item text-left">{{ \Carbon\Carbon::parse($term->start_date)->format('Y-m-d') }}</td>
|
</div>
|
||||||
|
</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $term->terms_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $term->city_id }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $term->use_flag ? '○' : '' }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $term->terms_revision }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $term->terms_text }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ $term->memo }}</td>
|
||||||
|
<td class="sm-item text-left align-middle">{{ \Carbon\Carbon::parse($term->start_date)->format('Y-m-d') }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
@endforeach
|
@endforeach
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<!-- ▲ 単一テーブル構成ここまで -->
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
|
|||||||
93
resources/views/admin/zones/_form.blade.php
Normal file
93
resources/views/admin/zones/_form.blade.php
Normal file
@ -0,0 +1,93 @@
|
|||||||
|
@csrf
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-lg-2 col-form-label">ゾーン名ID<span class="text-danger">※</span></label>
|
||||||
|
<div class="col-lg-6">
|
||||||
|
<input type="text" name="zone_id" class="form-control"
|
||||||
|
value="{{ old('zone_id', $zone->zone_id ?? '') }}" required>
|
||||||
|
@error('zone_id')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-lg-2 col-form-label">駐輪場ID<span class="text-danger">※</span></label>
|
||||||
|
<div class="col-lg-6">
|
||||||
|
<input type="number" name="park_id" class="form-control"
|
||||||
|
value="{{ old('park_id', $zone->park_id ?? '') }}" required>
|
||||||
|
@error('park_id')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-lg-2 col-form-label">駐輪分類ID</label>
|
||||||
|
<div class="col-lg-6">
|
||||||
|
<input type="number" name="ptype_id" class="form-control"
|
||||||
|
value="{{ old('ptype_id', $zone->ptype_id ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-lg-2 col-form-label">車種区分ID</label>
|
||||||
|
<div class="col-lg-6">
|
||||||
|
<input type="number" name="psection_id" class="form-control"
|
||||||
|
value="{{ old('psection_id', $zone->psection_id ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-lg-2 col-form-label">ゾーン名<span class="text-danger">※</span></label>
|
||||||
|
<div class="col-lg-6">
|
||||||
|
<input type="text" name="zone_name" class="form-control"
|
||||||
|
value="{{ old('zone_name', $zone->zone_name ?? '') }}" required>
|
||||||
|
@error('zone_name')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-lg-2 col-form-label">ゾーン内現在契約台数</label>
|
||||||
|
<div class="col-lg-6">
|
||||||
|
<input type="number" name="zone_number" class="form-control"
|
||||||
|
value="{{ old('zone_number', $zone->zone_number ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-lg-2 col-form-label">ゾーン内標準台数</label>
|
||||||
|
<div class="col-lg-6">
|
||||||
|
<input type="number" name="zone_standard" class="form-control"
|
||||||
|
value="{{ old('zone_standard', $zone->zone_standard ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-lg-2 col-form-label">ゾーン内許容台数</label>
|
||||||
|
<div class="col-lg-6">
|
||||||
|
<input type="number" name="zone_tolerance" class="form-control"
|
||||||
|
value="{{ old('zone_tolerance', $zone->zone_tolerance ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group row">
|
||||||
|
<label class="col-lg-2 col-form-label">ゾーン順</label>
|
||||||
|
<div class="col-lg-6">
|
||||||
|
<input type="number" name="zone_sort" class="form-control form-control-lg"
|
||||||
|
value="{{ old('zone_sort', $zone->zone_sort ?? '') }}">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group col-12 text-left">
|
||||||
|
@if(isset($zone) && $zone->zone_id)
|
||||||
|
{{-- 編集画面 --}}
|
||||||
|
<button type="submit" class="btn btn-primary">保存</button>
|
||||||
|
<a href="{{ route('zones') }}" class="btn btn-secondary">戻る</a>
|
||||||
|
@else
|
||||||
|
{{-- 新規画面 --}}
|
||||||
|
<button type="submit" class="btn btn-success">登録</button>
|
||||||
|
<a href="{{ route('zones') }}" class="btn btn-secondary">削除</a>
|
||||||
|
@endif
|
||||||
|
</div>
|
||||||
34
resources/views/admin/zones/add.blade.php
Normal file
34
resources/views/admin/zones/add.blade.php
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
@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="{{ route('zones') }}">ゾーンマスタ</a></li>
|
||||||
|
<li class="breadcrumb-item active">新規登録</li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<section class="content">
|
||||||
|
<div class="col-lg-12">
|
||||||
|
<div class="card">
|
||||||
|
<div class="card-body">
|
||||||
|
<form action="{{ route('zones_add') }}" method="POST" class="form-horizontal">
|
||||||
|
@include('admin.zones._form')
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
@endsection
|
||||||
35
resources/views/admin/zones/edit.blade.php
Normal file
35
resources/views/admin/zones/edit.blade.php
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
@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="{{ route('zones') }}">ゾーンマスタ</a></li>
|
||||||
|
<li class="breadcrumb-item active">編集</li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<section class="content">
|
||||||
|
<div class="col-lg-12">
|
||||||
|
<div class="card">
|
||||||
|
<div class="card-body">
|
||||||
|
<form action="{{ route('zones_edit', $zone->zone_id) }}" method="POST" class="form-horizontal">
|
||||||
|
@method('POST')
|
||||||
|
@include('admin.zones._form')
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
@endsection
|
||||||
51
resources/views/admin/zones/info.blade.php
Normal file
51
resources/views/admin/zones/info.blade.php
Normal file
@ -0,0 +1,51 @@
|
|||||||
|
@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="{{ route('zones') }}">ゾーンマスタ</a></li>
|
||||||
|
<li class="breadcrumb-item active">詳細</li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<section class="content">
|
||||||
|
<div class="col-lg-12">
|
||||||
|
<div class="card">
|
||||||
|
<div class="card-body">
|
||||||
|
{{-- 共通フォームをインクルード --}}
|
||||||
|
<form class="form-horizontal">
|
||||||
|
@csrf
|
||||||
|
|
||||||
|
{{-- form.blade.phpの内容を読み込み --}}
|
||||||
|
@include('admin.zones.form', ['zone' => $zone])
|
||||||
|
|
||||||
|
{{-- すべてのフォーム要素を非活性にするJS --}}
|
||||||
|
<script>
|
||||||
|
document.addEventListener('DOMContentLoaded', function() {
|
||||||
|
document.querySelectorAll('input, select, textarea').forEach(function(el) {
|
||||||
|
el.setAttribute('disabled', true);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<div class="form-group col-12 text-center">
|
||||||
|
<a href="{{ route('zones') }}" class="btn btn-secondary">戻る</a>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
@endsection
|
||||||
194
resources/views/admin/zones/list.blade.php
Normal file
194
resources/views/admin/zones/list.blade.php
Normal file
@ -0,0 +1,194 @@
|
|||||||
|
@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 active">ゾーンマスタ</li>
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<section class="content">
|
||||||
|
<!-- ▼ 絞り込みフィルター -->
|
||||||
|
<div class="col-lg-12">
|
||||||
|
<div class="card">
|
||||||
|
<div class="card-header">
|
||||||
|
<h3 class="card-title">絞り込みフィルター</h3>
|
||||||
|
</div>
|
||||||
|
<div class="card-body">
|
||||||
|
<form action="{{ route('zones') }}" method="POST" id="list-form" class="form-horizontal">
|
||||||
|
@csrf
|
||||||
|
<input type="hidden" name="sort" value="{{ $sort ?? '' }}">
|
||||||
|
<input type="hidden" name="sort_type" value="{{ $sort_type ?? '' }}">
|
||||||
|
|
||||||
|
<table class="table table-borderless mb-0" style="width: 100%;">
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<th style="text-align: left;">駐輪場ID</th>
|
||||||
|
<td>
|
||||||
|
<input type="text" name="park_id" value="{{ old('park_id', $park_id ?? '') }}"
|
||||||
|
class="form-control input-sm" placeholder="123456">
|
||||||
|
</td>
|
||||||
|
<th style="text-align: left;">駐輪分類ID</th>
|
||||||
|
<td>
|
||||||
|
<input type="text" name="ptype_id" value="{{ old('ptype_id', $ptype_id ?? '') }}"
|
||||||
|
class="form-control input-sm" placeholder="1">
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<th style="text-align: left;">車種区分ID</th>
|
||||||
|
<td>
|
||||||
|
<input type="text" name="psection_id" value="{{ old('psection_id', $psection_id ?? '') }}"
|
||||||
|
class="form-control input-sm" placeholder="2">
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
|
||||||
|
<div class="form-group col-12 text-left mt-3">
|
||||||
|
<button type="submit" name="action" value="filter" class="btn btn-default">絞り込み</button>
|
||||||
|
<button type="submit" name="action" value="reset" class="btn btn-default">解除</button>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- ▲ 絞り込みフィルター -->
|
||||||
|
|
||||||
|
<!-- ▼ ツールバー -->
|
||||||
|
<div class="container-fluid mb20">
|
||||||
|
<a href="{{ route('zones_add') }}" class="btn btn-sm btn-default mr10">新規</a>
|
||||||
|
<button type="submit" form="deleteForm" class="btn btn-sm btn-default mr10"
|
||||||
|
onclick="return confirm('選択したゾーンを削除しますか?');">削除</button>
|
||||||
|
<div class="d-flex justify-content-end">
|
||||||
|
{{ $zones->appends(request()->all())->links('pagination') }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- ▲ ツールバー -->
|
||||||
|
|
||||||
|
<!-- ▼ 一覧テーブル -->
|
||||||
|
<div class="col-lg-12 mb20">
|
||||||
|
<div class="table-responsive">
|
||||||
|
<form id="deleteForm" method="POST" action="{{ route('zones_delete') }}">
|
||||||
|
@csrf
|
||||||
|
<table class="table table-bordered table-striped dataTable text-nowrap">
|
||||||
|
<thead>
|
||||||
|
<tr>
|
||||||
|
<!-- 全選択チェックボックス -->
|
||||||
|
<th style="width:140px;" class="text-left">
|
||||||
|
<input type="checkbox" onclick="$('input[name*=\'pk\']').prop('checked', this.checked);">
|
||||||
|
</th>
|
||||||
|
|
||||||
|
<!-- ゾーンID -->
|
||||||
|
<th class="sorting {{ ($sort=='zone_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="zone_id">
|
||||||
|
<span>ゾーンID</span>
|
||||||
|
</th>
|
||||||
|
|
||||||
|
<!-- 駐輪場ID -->
|
||||||
|
<th class="sorting {{ ($sort=='park_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="park_id">
|
||||||
|
<span>駐輪場ID</span>
|
||||||
|
</th>
|
||||||
|
|
||||||
|
<!-- 駐輪分類ID -->
|
||||||
|
<th class="sorting {{ ($sort=='ptype_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="ptype_id">
|
||||||
|
<span>駐輪分類ID</span>
|
||||||
|
</th>
|
||||||
|
|
||||||
|
<!-- ゾーン名 -->
|
||||||
|
<th class="sorting {{ ($sort=='zone_name') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="zone_name">
|
||||||
|
<span>ゾーン名</span>
|
||||||
|
</th>
|
||||||
|
|
||||||
|
<!-- ゾーン内現在契約台数 -->
|
||||||
|
<th class="sorting {{ ($sort=='zone_number') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="zone_number">
|
||||||
|
<span>ゾーン内現在契約台数</span>
|
||||||
|
</th>
|
||||||
|
|
||||||
|
<!-- ゾーン内標準台数 -->
|
||||||
|
<th class="sorting {{ ($sort=='zone_standard') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="zone_standard">
|
||||||
|
<span>ゾーン内標準台数</span>
|
||||||
|
</th>
|
||||||
|
|
||||||
|
<!-- ゾーン内許容台数 -->
|
||||||
|
<th class="sorting {{ ($sort=='zone_tolerance') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="zone_tolerance">
|
||||||
|
<span>ゾーン内許容台数</span>
|
||||||
|
</th>
|
||||||
|
|
||||||
|
<!-- ゾーン順 -->
|
||||||
|
<th class="sorting {{ ($sort=='zone_sort') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="zone_sort">
|
||||||
|
<span>ゾーン順</span>
|
||||||
|
</th>
|
||||||
|
|
||||||
|
<!-- 車種区分ID -->
|
||||||
|
<th class="sorting {{ ($sort=='psection_id') ? ($sort_type=='asc'?'sorting_asc':'sorting_desc') : '' }}" sort="psection_id">
|
||||||
|
<span>車種区分ID</span>
|
||||||
|
</th>
|
||||||
|
</tr>
|
||||||
|
</thead>
|
||||||
|
|
||||||
|
<tbody>
|
||||||
|
@foreach($zones as $item)
|
||||||
|
<tr>
|
||||||
|
<td class="table-warning align-middle">
|
||||||
|
<div class="d-flex align-items-center">
|
||||||
|
<input type="checkbox" class="m-0 checkbox" name="pk[]" value="{{ $item->zone_id }}">
|
||||||
|
<a href="{{ route('zones_edit', ['id' => $item->zone_id]) }}" class="btn btn-sm btn-default ml-2">編集</a>
|
||||||
|
</div>
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td>{{ $item->zone_id }}</td>
|
||||||
|
<td>{{ $item->park_id }}</td>
|
||||||
|
<td>{{ $item->ptype_id }}</td>
|
||||||
|
<td>{{ $item->zone_name }}</td>
|
||||||
|
<td>{{ $item->zone_number }}</td>
|
||||||
|
<td>{{ $item->zone_standard }}</td>
|
||||||
|
<td>{{ $item->zone_tolerance }}</td>
|
||||||
|
<td>{{ $item->zone_sort }}</td>
|
||||||
|
<td>{{ $item->psection_id }}</td>
|
||||||
|
</tr>
|
||||||
|
@endforeach
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- ▲ 一覧テーブル -->
|
||||||
|
</section>
|
||||||
|
|
||||||
|
@push('scripts')
|
||||||
|
<script>
|
||||||
|
document.addEventListener('DOMContentLoaded', function () {
|
||||||
|
// ---------------------
|
||||||
|
// ソート機能
|
||||||
|
// ---------------------
|
||||||
|
document.querySelectorAll('th.sorting').forEach(th => {
|
||||||
|
th.addEventListener('click', function() {
|
||||||
|
const form = document.getElementById('list-form');
|
||||||
|
const current = "{{ $sort ?? '' }}";
|
||||||
|
const currentType = "{{ $sort_type ?? '' }}";
|
||||||
|
const nextCol = this.getAttribute('sort');
|
||||||
|
let nextType = 'asc';
|
||||||
|
if (current === nextCol) {
|
||||||
|
nextType = (currentType === 'asc') ? 'desc' : 'asc';
|
||||||
|
}
|
||||||
|
form.querySelector('[name=sort]').value = nextCol;
|
||||||
|
form.querySelector('[name=sort_type]').value = nextType;
|
||||||
|
form.submit();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
@endpush
|
||||||
|
|
||||||
|
@endsection
|
||||||
Loading…
Reference in New Issue
Block a user