92 lines
3.9 KiB
PHP
92 lines
3.9 KiB
PHP
|
@extends('layouts.app')
|
||
|
@use('Carbon\Carbon')
|
||
|
@section('content')
|
||
|
<div class="page-content">
|
||
|
<div class="container-fluid">
|
||
|
|
||
|
<!-- start page title -->
|
||
|
@include('layouts.partials.breadcrumb', ['title' => 'Trainer'])
|
||
|
|
||
|
<!-- end page title -->
|
||
|
|
||
|
<div class="card">
|
||
|
<div class="card-body">
|
||
|
<div class="row g-2">
|
||
|
<div class="col-sm-4">
|
||
|
<div class="search-box">
|
||
|
<input type="text" class="form-control" id="searchMemberList" placeholder="Search for name...">
|
||
|
<i class="ri-search-line search-icon"></i>
|
||
|
</div>
|
||
|
</div>
|
||
|
<!--end col-->
|
||
|
<div class="col-sm-auto ms-auto">
|
||
|
<div class="list-grid-nav hstack gap-1">
|
||
|
|
||
|
<a class="btn btn-success" href="{{ route('trainer.create') }}"><i
|
||
|
class="ri-add-fill me-1 align-bottom"></i> Create Trainer</a>
|
||
|
|
||
|
</div>
|
||
|
</div>
|
||
|
<!--end col-->
|
||
|
</div>
|
||
|
<!--end row-->
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
<div class="card-body">
|
||
|
<table id="buttons-datatables" class="display table-sm table-bordered table">
|
||
|
<thead class="table-light">
|
||
|
<tr>
|
||
|
<th class="tb-col"><span class="overline-title">S.N</span></th>
|
||
|
<th class="tb-col"><span class="overline-title">Full Name</span></th>
|
||
|
<th class="tb-col"><span class="overline-title"> Phone</span></th>
|
||
|
<th class="tb-col"><span class="overline-title"> Email</span></th>
|
||
|
<th class="tb-col"><span class="overline-title"> Shift</span></th>
|
||
|
<th class="tb-col"><span class="overline-title">Start Date</span></th>
|
||
|
<th class="tb-col"><span class="overline-title">End Date</span></th>
|
||
|
<th class="tb-col" data-sortable="false"><span class="overline-title">Action</span>
|
||
|
</th>
|
||
|
</tr>
|
||
|
</thead>
|
||
|
<tbody>
|
||
|
|
||
|
@foreach ($trainerLists as $index => $item)
|
||
|
<tr>
|
||
|
<td class="tb-col">{{ $index + 1 }}</td>
|
||
|
<td class="tb-col">{{ $item->first_name }} {{ $item->last_name }} </td>
|
||
|
<td class="tb-col">{{ $item->phone }}</td>
|
||
|
<td class="tb-col">{{ $item->email }}</td>
|
||
|
<td class="tb-col">{{ $item->shift }}</td>
|
||
|
<td class="tb-col">{{ Carbon::parse($item->start_date)->format('h:i A') }}</td>
|
||
|
<td class="tb-col">{{ Carbon::parse($item->end_date)->format('h:i A') }}</td>
|
||
|
<td class="tb-col">
|
||
|
<div class="hstack flex-wrap gap-3">
|
||
|
<a href="javascript:void(0);" class="link-info fs-15 view-item-btn"
|
||
|
data-bs-toggle="modal" data-bs-target="#viewModal">
|
||
|
<i class="ri-eye-line"></i>
|
||
|
</a>
|
||
|
<a href="{{ route('trainer.edit', $item->id) }}"
|
||
|
class="link-success fs-15 edit-item-btn"><i class="ri-edit-2-line"></i></a>
|
||
|
|
||
|
<a href="javascript:void(0);"
|
||
|
data-link="{{ route('trainer.destroy', $item->id) }}"
|
||
|
data-id="{{ $item->trainer_id }}"
|
||
|
class="link-danger fs-15 remove-item-btn"><i
|
||
|
class="ri-delete-bin-line"></i></a>
|
||
|
</div>
|
||
|
</td>
|
||
|
</tr>
|
||
|
@endforeach
|
||
|
</tbody>
|
||
|
</table>
|
||
|
</div>
|
||
|
|
||
|
|
||
|
@endsection
|
||
|
|
||
|
@push('js')
|
||
|
|
||
|
<script src="{{ asset('assets/js/pages/form-validation.init.js') }}"></script>
|
||
|
|
||
|
@endpush
|