diff --git a/app/Http/Controllers/AdminController.php b/app/Http/Controllers/AdminController.php index f5cdda0102f6a0a2ffc19e1b81e53904c785b48f..5fadc5001efb6cc84108e01fc25e5726417a53a4 100644 --- a/app/Http/Controllers/AdminController.php +++ b/app/Http/Controllers/AdminController.php @@ -6,9 +6,12 @@ use Illuminate\Http\Request; use App\Models\Member; use App\Models\Receipt; +use Illuminate\Pagination\Paginator; use Illuminate\Support\Facades\DB; + + class AdminController extends Controller { /* @@ -27,6 +30,7 @@ public function Admin_home(){ public function Approve_tranfer(){ $raw = new Receipt(); $data['user_receipt'] = $raw->get_recipt(); + //$data = $data['user_receipt']->paginate(10); return view('Admin/Transection/v_approve_tranfer', $data); } diff --git a/app/Models/Receipt.php b/app/Models/Receipt.php index 53a201f40450f43aa5df7ff2e91416f55bd28d98..c83a4ae3d6b9e93cbe105afc434f582c542c537c 100644 --- a/app/Models/Receipt.php +++ b/app/Models/Receipt.php @@ -5,6 +5,7 @@ use Illuminate\Database\Eloquent\Factories\HasFactory; use Illuminate\Database\Eloquent\Model; use Illuminate\Support\Facades\DB; +use Illuminate\Pagination\Paginator; /** * @property integer $id diff --git a/public/icon/evidence/clock.png b/public/icon/evidence/clock.png new file mode 100644 index 0000000000000000000000000000000000000000..261f6ea0c2041d02bd7a6b85477331db0dc9b48e Binary files /dev/null and b/public/icon/evidence/clock.png differ diff --git a/public/image/404.png b/public/image/404.png new file mode 100644 index 0000000000000000000000000000000000000000..a4d643815cfb4b58d01798f9719d1224f004f0e8 Binary files /dev/null and b/public/image/404.png differ diff --git a/resources/views/Admin/Transection/v_approve_tranfer.blade.php b/resources/views/Admin/Transection/v_approve_tranfer.blade.php index afc7f8071a6c2bc4d3938456d5122a1ec6e35026..824c714b372092ae3de8a03be3501b39d67d3f56 100644 --- a/resources/views/Admin/Transection/v_approve_tranfer.blade.php +++ b/resources/views/Admin/Transection/v_approve_tranfer.blade.php @@ -3,12 +3,16 @@ <!DOCTYPE html> <html> +<script src="https://code.jquery.com/jquery-3.5.1.js"></script> +<script src="https://cdn.datatables.net/1.13.4/js/jquery.dataTables.min.js"></script> +<link rel="stylesheet" href="https://cdn.datatables.net/1.13.4/css/jquery.dataTables.min.css"> <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet" - integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous" /> + integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous" /> <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js" - integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous"></script> + integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous"> +</script> <html lang="en"> - <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/5.3.0/css/bootstrap.min.css" +<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/5.3.0/css/bootstrap.min.css" integrity="sha512-jRcyS0JzoOe9Mq3OEn5Q+U67/l7o+f+B2dG1mVWmHJ+ud7M9XmFmB7GJj6o4b4Yl+SGoSyKkfcf1FbzN1Sd9zA==" crossorigin="anonymous" referrerpolicy="no-referrer" /> @@ -20,16 +24,16 @@ <style> .box { - width: 20%; - height: 120px; - border-radius: 10px; - margin-right: 10px; - background-color: #ffffff; - display: inline-block; + width: 20%; + height: 120px; + border-radius: 10px; + margin-right: 10px; + background-color: #ffffff; + display: inline-block; } - .col{ - left: 405px; + .col { + left: 405px; width: 1040px; height: auto; margin: 0 auto; @@ -37,98 +41,151 @@ } - .container{ + .container { margin: 0 auto; } .table-bordered { - border: 10px solid #dee2e6; - } - - .table-bordered th, - .table-bordered td { - border: 10px solid #dee2e6; - border-top-width: 0; - border-left-width: 0; - } - - .table-bordered thead th:first-child, - .table-bordered td:first-child { - border-left-width: 2px; - border-top-left-radius: 10px; - border-bottom-left-radius: 10px; - } - - .table-bordered thead th:last-child, - .table-bordered td:last-child { - border-right-width: 2px; - border-top-right-radius: 10px; - border-bottom-right-radius: 10px; - } - - .table-bordered thead th, - .table-bordered td { - vertical-align: middle; - } - </style> + border: 10px solid #dee2e6; + } + + .table-bordered th, + .table-bordered td { + border: 10px solid #dee2e6; + border-top-width: 0; + border-left-width: 0; + } + + .table-bordered thead th:first-child, + .table-bordered td:first-child { + border-left-width: 2px; + border-top-left-radius: 10px; + border-bottom-left-radius: 10px; + } + + .table-bordered thead th:last-child, + .table-bordered td:last-child { + border-right-width: 2px; + border-top-right-radius: 10px; + border-bottom-right-radius: 10px; + } + + .table-bordered thead th, + .table-bordered td { + vertical-align: middle; + } + + </style> </head> <body> <br> <!-- จำเป็นต้องมี --> <br> <!-- จำเป็นต้องมี --> <br> <!-- จำเป็นต้องมี --> - <h1 class="m-5">หลักฐานการแจ้งฝากเงิน</h1> + <h1 class="m-5">หลักฐานการแจ้งฝากเงิน</h1> <div class="container"> <div class="container"> - <div class="row"> - <div class="col mt-5"> - <div class="row m-3 d-flex justify-content-end"> - <div class="col-3"> - <input type="text" class="form-control" placeholder="ค้นหา"> - </div> + <div class="row"> + <div class="col mt-5"> + {{-- <div class="row m-3 d-flex justify-content-end"> + <div class="col-3"> + <input type="text" class="form-control" placeholder="ค้นหา"> + </div> + </div> --}} + <table class="table"> + <thead> + <tr> + <th>วันที่ส่งสลิป</th> + <th>เวลา</th> + <th>ชื่อ-นามสกุล</th> + <th>รูป</th> + <th>จำนวนเงิน</th> + <th>สถานะ</th> + <th>Action</th> + </tr> + </thead> + <tbody> + @foreach ($user_receipt as $user) + <tr> + <td>{{$user->rec_date}}</td> + <td>{{$user->rec_time}}</td> + <td>{{$user->rec_name}}</td> + + {{-- image --}} + @if ($user->rec_img) + <td> <img src="receipt\{{$user->rec_img}}" width="200px" height="100px" > </td> + @else + <td> <img src="image\404.png" width="200px" height="100px" > </td> + @endif + + + {{-- amount --}} + <td>{{$user->rec_amount}}</td> + + {{-- status --}} + @if($user->rec_status == 2) + <td><img src="icon\evidence\failed.png" width="20px" height="20px"></td> + <td></td> + @elseif ($user->rec_status == 1) + <td><img src="icon\evidence\succeed.png" width="25px" height="25px"></td> + <td></td> + @else + <td><img src="icon\evidence\clock.png" width="20px" height="20px"></td> + <td> + {{-- <form action="{{route('accept', ['rec_id' => $user->id, 'mem_id' => $user->mem_id])}}, " method="POST"><button> ยืนยัน </button> </form> + <form action=""><button onclick="denied()"> ยกเลิก </button> </form> --}} + </td> + @endif + + + </tr> + @endforeach + </tbody> + </table> + {{-- {{ $user_receipt->links() }} --}} + {{-- <div class="d-grid gap-2 d-md-flex justify-content-md-end m-3"> + <button class="btn btn-light" type="button">ก่อนหน้า</button> + <button class="btn btn-primary" type="button">1</button> + <button class="btn btn-light" type="button">2</button> + <button class="btn btn-light" type="button">3</button> + <button class="btn btn-light" type="button">4</button> + <button class="btn btn-light" type="button">5</button> + <button class="btn btn-light" type="button">ถัดไป</button> + </div> --}} + </div> </div> - <table class="table"> - <thead> - <tr> - <th>วันที่ส่งสลิป</th> - <th>เวลา</th> - <th>ชื่อ-นามสกุล</th> - <th>รูป</th> - <th>จำนวนเงิน</th> - <th>สถานะ</th> - </tr> - </thead> - <tbody> - @foreach ($user_receipt as $user) - <tr> - <td>{{$user->rec_name}}</td> - <td>{{$user->rec_img}}</td> - <td>{{$user->rec_amount}}</td> - <td>{{$user->rec_status}}</td> - </tr> - @endforeach - </tbody> - </table> - <div class="d-grid gap-2 d-md-flex justify-content-md-end m-3"> - <button class="btn btn-light" type="button">ก่อนหน้า</button> - <button class="btn btn-primary" type="button">1</button> - <button class="btn btn-light" type="button">2</button> - <button class="btn btn-light" type="button">3</button> - <button class="btn btn-light" type="button">4</button> - <button class="btn btn-light" type="button">5</button> - <button class="btn btn-light" type="button">ถัดไป</button> - </div> - </div> </div> - </div> - - +<script> + $(document).ready(function () { + $('table').DataTable(); + }); +</script> </body> +{{-- <script> + function accept(rec, mem) + { + var rec_id = rec + var mem_id = mem + // console.log(user_id); + // console.log(mem_id); + console.log(rec_id); + console.log(mem_id); + console.log("success"); + + + } + + function denied() + { + console.log("denied"); + } +</script> --}} + </html> @endsection diff --git a/resources/views/vendor/pagination/bootstrap-4.blade.php b/resources/views/vendor/pagination/bootstrap-4.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..63c6f56b59e0b2ed1c88c32e3197f05daab80e76 --- /dev/null +++ b/resources/views/vendor/pagination/bootstrap-4.blade.php @@ -0,0 +1,46 @@ +@if ($paginator->hasPages()) + <nav> + <ul class="pagination"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <li class="page-item disabled" aria-disabled="true" aria-label="@lang('pagination.previous')"> + <span class="page-link" aria-hidden="true">‹</span> + </li> + @else + <li class="page-item"> + <a class="page-link" href="{{ $paginator->previousPageUrl() }}" rel="prev" aria-label="@lang('pagination.previous')">‹</a> + </li> + @endif + + {{-- Pagination Elements --}} + @foreach ($elements as $element) + {{-- "Three Dots" Separator --}} + @if (is_string($element)) + <li class="page-item disabled" aria-disabled="true"><span class="page-link">{{ $element }}</span></li> + @endif + + {{-- Array Of Links --}} + @if (is_array($element)) + @foreach ($element as $page => $url) + @if ($page == $paginator->currentPage()) + <li class="page-item active" aria-current="page"><span class="page-link">{{ $page }}</span></li> + @else + <li class="page-item"><a class="page-link" href="{{ $url }}">{{ $page }}</a></li> + @endif + @endforeach + @endif + @endforeach + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <li class="page-item"> + <a class="page-link" href="{{ $paginator->nextPageUrl() }}" rel="next" aria-label="@lang('pagination.next')">›</a> + </li> + @else + <li class="page-item disabled" aria-disabled="true" aria-label="@lang('pagination.next')"> + <span class="page-link" aria-hidden="true">›</span> + </li> + @endif + </ul> + </nav> +@endif diff --git a/resources/views/vendor/pagination/bootstrap-5.blade.php b/resources/views/vendor/pagination/bootstrap-5.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..a1795a4d84e3b4ee6a3f618f50a27548b112f930 --- /dev/null +++ b/resources/views/vendor/pagination/bootstrap-5.blade.php @@ -0,0 +1,88 @@ +@if ($paginator->hasPages()) + <nav class="d-flex justify-items-center justify-content-between"> + <div class="d-flex justify-content-between flex-fill d-sm-none"> + <ul class="pagination"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <li class="page-item disabled" aria-disabled="true"> + <span class="page-link">@lang('pagination.previous')</span> + </li> + @else + <li class="page-item"> + <a class="page-link" href="{{ $paginator->previousPageUrl() }}" rel="prev">@lang('pagination.previous')</a> + </li> + @endif + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <li class="page-item"> + <a class="page-link" href="{{ $paginator->nextPageUrl() }}" rel="next">@lang('pagination.next')</a> + </li> + @else + <li class="page-item disabled" aria-disabled="true"> + <span class="page-link">@lang('pagination.next')</span> + </li> + @endif + </ul> + </div> + + <div class="d-none flex-sm-fill d-sm-flex align-items-sm-center justify-content-sm-between"> + <div> + <p class="small text-muted"> + {!! __('Showing') !!} + <span class="fw-semibold">{{ $paginator->firstItem() }}</span> + {!! __('to') !!} + <span class="fw-semibold">{{ $paginator->lastItem() }}</span> + {!! __('of') !!} + <span class="fw-semibold">{{ $paginator->total() }}</span> + {!! __('results') !!} + </p> + </div> + + <div> + <ul class="pagination"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <li class="page-item disabled" aria-disabled="true" aria-label="@lang('pagination.previous')"> + <span class="page-link" aria-hidden="true">‹</span> + </li> + @else + <li class="page-item"> + <a class="page-link" href="{{ $paginator->previousPageUrl() }}" rel="prev" aria-label="@lang('pagination.previous')">‹</a> + </li> + @endif + + {{-- Pagination Elements --}} + @foreach ($elements as $element) + {{-- "Three Dots" Separator --}} + @if (is_string($element)) + <li class="page-item disabled" aria-disabled="true"><span class="page-link">{{ $element }}</span></li> + @endif + + {{-- Array Of Links --}} + @if (is_array($element)) + @foreach ($element as $page => $url) + @if ($page == $paginator->currentPage()) + <li class="page-item active" aria-current="page"><span class="page-link">{{ $page }}</span></li> + @else + <li class="page-item"><a class="page-link" href="{{ $url }}">{{ $page }}</a></li> + @endif + @endforeach + @endif + @endforeach + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <li class="page-item"> + <a class="page-link" href="{{ $paginator->nextPageUrl() }}" rel="next" aria-label="@lang('pagination.next')">›</a> + </li> + @else + <li class="page-item disabled" aria-disabled="true" aria-label="@lang('pagination.next')"> + <span class="page-link" aria-hidden="true">›</span> + </li> + @endif + </ul> + </div> + </div> + </nav> +@endif diff --git a/resources/views/vendor/pagination/default.blade.php b/resources/views/vendor/pagination/default.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..0db70b56275c4f0d215e000020a5ba43c20ca874 --- /dev/null +++ b/resources/views/vendor/pagination/default.blade.php @@ -0,0 +1,46 @@ +@if ($paginator->hasPages()) + <nav> + <ul class="pagination"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <li class="disabled" aria-disabled="true" aria-label="@lang('pagination.previous')"> + <span aria-hidden="true">‹</span> + </li> + @else + <li> + <a href="{{ $paginator->previousPageUrl() }}" rel="prev" aria-label="@lang('pagination.previous')">‹</a> + </li> + @endif + + {{-- Pagination Elements --}} + @foreach ($elements as $element) + {{-- "Three Dots" Separator --}} + @if (is_string($element)) + <li class="disabled" aria-disabled="true"><span>{{ $element }}</span></li> + @endif + + {{-- Array Of Links --}} + @if (is_array($element)) + @foreach ($element as $page => $url) + @if ($page == $paginator->currentPage()) + <li class="active" aria-current="page"><span>{{ $page }}</span></li> + @else + <li><a href="{{ $url }}">{{ $page }}</a></li> + @endif + @endforeach + @endif + @endforeach + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <li> + <a href="{{ $paginator->nextPageUrl() }}" rel="next" aria-label="@lang('pagination.next')">›</a> + </li> + @else + <li class="disabled" aria-disabled="true" aria-label="@lang('pagination.next')"> + <span aria-hidden="true">›</span> + </li> + @endif + </ul> + </nav> +@endif diff --git a/resources/views/vendor/pagination/semantic-ui.blade.php b/resources/views/vendor/pagination/semantic-ui.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..ef0dbb184c63d8011a59df68410a439c22c26ade --- /dev/null +++ b/resources/views/vendor/pagination/semantic-ui.blade.php @@ -0,0 +1,36 @@ +@if ($paginator->hasPages()) + <div class="ui pagination menu" role="navigation"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <a class="icon item disabled" aria-disabled="true" aria-label="@lang('pagination.previous')"> <i class="left chevron icon"></i> </a> + @else + <a class="icon item" href="{{ $paginator->previousPageUrl() }}" rel="prev" aria-label="@lang('pagination.previous')"> <i class="left chevron icon"></i> </a> + @endif + + {{-- Pagination Elements --}} + @foreach ($elements as $element) + {{-- "Three Dots" Separator --}} + @if (is_string($element)) + <a class="icon item disabled" aria-disabled="true">{{ $element }}</a> + @endif + + {{-- Array Of Links --}} + @if (is_array($element)) + @foreach ($element as $page => $url) + @if ($page == $paginator->currentPage()) + <a class="item active" href="{{ $url }}" aria-current="page">{{ $page }}</a> + @else + <a class="item" href="{{ $url }}">{{ $page }}</a> + @endif + @endforeach + @endif + @endforeach + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <a class="icon item" href="{{ $paginator->nextPageUrl() }}" rel="next" aria-label="@lang('pagination.next')"> <i class="right chevron icon"></i> </a> + @else + <a class="icon item disabled" aria-disabled="true" aria-label="@lang('pagination.next')"> <i class="right chevron icon"></i> </a> + @endif + </div> +@endif diff --git a/resources/views/vendor/pagination/simple-bootstrap-4.blade.php b/resources/views/vendor/pagination/simple-bootstrap-4.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..4bb491742a3d30c6a9226719a83975de001b1e1b --- /dev/null +++ b/resources/views/vendor/pagination/simple-bootstrap-4.blade.php @@ -0,0 +1,27 @@ +@if ($paginator->hasPages()) + <nav> + <ul class="pagination"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <li class="page-item disabled" aria-disabled="true"> + <span class="page-link">@lang('pagination.previous')</span> + </li> + @else + <li class="page-item"> + <a class="page-link" href="{{ $paginator->previousPageUrl() }}" rel="prev">@lang('pagination.previous')</a> + </li> + @endif + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <li class="page-item"> + <a class="page-link" href="{{ $paginator->nextPageUrl() }}" rel="next">@lang('pagination.next')</a> + </li> + @else + <li class="page-item disabled" aria-disabled="true"> + <span class="page-link">@lang('pagination.next')</span> + </li> + @endif + </ul> + </nav> +@endif diff --git a/resources/views/vendor/pagination/simple-bootstrap-5.blade.php b/resources/views/vendor/pagination/simple-bootstrap-5.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..a89005ee7d8195623fa2f40376c3fc59843db520 --- /dev/null +++ b/resources/views/vendor/pagination/simple-bootstrap-5.blade.php @@ -0,0 +1,29 @@ +@if ($paginator->hasPages()) + <nav role="navigation" aria-label="Pagination Navigation"> + <ul class="pagination"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <li class="page-item disabled" aria-disabled="true"> + <span class="page-link">{!! __('pagination.previous') !!}</span> + </li> + @else + <li class="page-item"> + <a class="page-link" href="{{ $paginator->previousPageUrl() }}" rel="prev"> + {!! __('pagination.previous') !!} + </a> + </li> + @endif + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <li class="page-item"> + <a class="page-link" href="{{ $paginator->nextPageUrl() }}" rel="next">{!! __('pagination.next') !!}</a> + </li> + @else + <li class="page-item disabled" aria-disabled="true"> + <span class="page-link">{!! __('pagination.next') !!}</span> + </li> + @endif + </ul> + </nav> +@endif diff --git a/resources/views/vendor/pagination/simple-default.blade.php b/resources/views/vendor/pagination/simple-default.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..36bdbc18c655b0ed852e627419d7c739fed226fc --- /dev/null +++ b/resources/views/vendor/pagination/simple-default.blade.php @@ -0,0 +1,19 @@ +@if ($paginator->hasPages()) + <nav> + <ul class="pagination"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <li class="disabled" aria-disabled="true"><span>@lang('pagination.previous')</span></li> + @else + <li><a href="{{ $paginator->previousPageUrl() }}" rel="prev">@lang('pagination.previous')</a></li> + @endif + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <li><a href="{{ $paginator->nextPageUrl() }}" rel="next">@lang('pagination.next')</a></li> + @else + <li class="disabled" aria-disabled="true"><span>@lang('pagination.next')</span></li> + @endif + </ul> + </nav> +@endif diff --git a/resources/views/vendor/pagination/simple-tailwind.blade.php b/resources/views/vendor/pagination/simple-tailwind.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..6872cca360d5e11ed6df0ea78836130425b2b6f7 --- /dev/null +++ b/resources/views/vendor/pagination/simple-tailwind.blade.php @@ -0,0 +1,25 @@ +@if ($paginator->hasPages()) + <nav role="navigation" aria-label="Pagination Navigation" class="flex justify-between"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <span class="relative inline-flex items-center px-4 py-2 text-sm font-medium text-gray-500 bg-white border border-gray-300 cursor-default leading-5 rounded-md"> + {!! __('pagination.previous') !!} + </span> + @else + <a href="{{ $paginator->previousPageUrl() }}" rel="prev" class="relative inline-flex items-center px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 leading-5 rounded-md hover:text-gray-500 focus:outline-none focus:ring ring-gray-300 focus:border-blue-300 active:bg-gray-100 active:text-gray-700 transition ease-in-out duration-150"> + {!! __('pagination.previous') !!} + </a> + @endif + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <a href="{{ $paginator->nextPageUrl() }}" rel="next" class="relative inline-flex items-center px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 leading-5 rounded-md hover:text-gray-500 focus:outline-none focus:ring ring-gray-300 focus:border-blue-300 active:bg-gray-100 active:text-gray-700 transition ease-in-out duration-150"> + {!! __('pagination.next') !!} + </a> + @else + <span class="relative inline-flex items-center px-4 py-2 text-sm font-medium text-gray-500 bg-white border border-gray-300 cursor-default leading-5 rounded-md"> + {!! __('pagination.next') !!} + </span> + @endif + </nav> +@endif diff --git a/resources/views/vendor/pagination/tailwind.blade.php b/resources/views/vendor/pagination/tailwind.blade.php new file mode 100644 index 0000000000000000000000000000000000000000..5bf323b406f2c5e3afbc895ffc4fa81d0e32613e --- /dev/null +++ b/resources/views/vendor/pagination/tailwind.blade.php @@ -0,0 +1,106 @@ +@if ($paginator->hasPages()) + <nav role="navigation" aria-label="{{ __('Pagination Navigation') }}" class="flex items-center justify-between"> + <div class="flex justify-between flex-1 sm:hidden"> + @if ($paginator->onFirstPage()) + <span class="relative inline-flex items-center px-4 py-2 text-sm font-medium text-gray-500 bg-white border border-gray-300 cursor-default leading-5 rounded-md"> + {!! __('pagination.previous') !!} + </span> + @else + <a href="{{ $paginator->previousPageUrl() }}" class="relative inline-flex items-center px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-300 leading-5 rounded-md hover:text-gray-500 focus:outline-none focus:ring ring-gray-300 focus:border-blue-300 active:bg-gray-100 active:text-gray-700 transition ease-in-out duration-150"> + {!! __('pagination.previous') !!} + </a> + @endif + + @if ($paginator->hasMorePages()) + <a href="{{ $paginator->nextPageUrl() }}" class="relative inline-flex items-center px-4 py-2 ml-3 text-sm font-medium text-gray-700 bg-white border border-gray-300 leading-5 rounded-md hover:text-gray-500 focus:outline-none focus:ring ring-gray-300 focus:border-blue-300 active:bg-gray-100 active:text-gray-700 transition ease-in-out duration-150"> + {!! __('pagination.next') !!} + </a> + @else + <span class="relative inline-flex items-center px-4 py-2 ml-3 text-sm font-medium text-gray-500 bg-white border border-gray-300 cursor-default leading-5 rounded-md"> + {!! __('pagination.next') !!} + </span> + @endif + </div> + + <div class="hidden sm:flex-1 sm:flex sm:items-center sm:justify-between"> + <div> + <p class="text-sm text-gray-700 leading-5"> + {!! __('Showing') !!} + @if ($paginator->firstItem()) + <span class="font-medium">{{ $paginator->firstItem() }}</span> + {!! __('to') !!} + <span class="font-medium">{{ $paginator->lastItem() }}</span> + @else + {{ $paginator->count() }} + @endif + {!! __('of') !!} + <span class="font-medium">{{ $paginator->total() }}</span> + {!! __('results') !!} + </p> + </div> + + <div> + <span class="relative z-0 inline-flex shadow-sm rounded-md"> + {{-- Previous Page Link --}} + @if ($paginator->onFirstPage()) + <span aria-disabled="true" aria-label="{{ __('pagination.previous') }}"> + <span class="relative inline-flex items-center px-2 py-2 text-sm font-medium text-gray-500 bg-white border border-gray-300 cursor-default rounded-l-md leading-5" aria-hidden="true"> + <svg class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20"> + <path fill-rule="evenodd" d="M12.707 5.293a1 1 0 010 1.414L9.414 10l3.293 3.293a1 1 0 01-1.414 1.414l-4-4a1 1 0 010-1.414l4-4a1 1 0 011.414 0z" clip-rule="evenodd" /> + </svg> + </span> + </span> + @else + <a href="{{ $paginator->previousPageUrl() }}" rel="prev" class="relative inline-flex items-center px-2 py-2 text-sm font-medium text-gray-500 bg-white border border-gray-300 rounded-l-md leading-5 hover:text-gray-400 focus:z-10 focus:outline-none focus:ring ring-gray-300 focus:border-blue-300 active:bg-gray-100 active:text-gray-500 transition ease-in-out duration-150" aria-label="{{ __('pagination.previous') }}"> + <svg class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20"> + <path fill-rule="evenodd" d="M12.707 5.293a1 1 0 010 1.414L9.414 10l3.293 3.293a1 1 0 01-1.414 1.414l-4-4a1 1 0 010-1.414l4-4a1 1 0 011.414 0z" clip-rule="evenodd" /> + </svg> + </a> + @endif + + {{-- Pagination Elements --}} + @foreach ($elements as $element) + {{-- "Three Dots" Separator --}} + @if (is_string($element)) + <span aria-disabled="true"> + <span class="relative inline-flex items-center px-4 py-2 -ml-px text-sm font-medium text-gray-700 bg-white border border-gray-300 cursor-default leading-5">{{ $element }}</span> + </span> + @endif + + {{-- Array Of Links --}} + @if (is_array($element)) + @foreach ($element as $page => $url) + @if ($page == $paginator->currentPage()) + <span aria-current="page"> + <span class="relative inline-flex items-center px-4 py-2 -ml-px text-sm font-medium text-gray-500 bg-white border border-gray-300 cursor-default leading-5">{{ $page }}</span> + </span> + @else + <a href="{{ $url }}" class="relative inline-flex items-center px-4 py-2 -ml-px text-sm font-medium text-gray-700 bg-white border border-gray-300 leading-5 hover:text-gray-500 focus:z-10 focus:outline-none focus:ring ring-gray-300 focus:border-blue-300 active:bg-gray-100 active:text-gray-700 transition ease-in-out duration-150" aria-label="{{ __('Go to page :page', ['page' => $page]) }}"> + {{ $page }} + </a> + @endif + @endforeach + @endif + @endforeach + + {{-- Next Page Link --}} + @if ($paginator->hasMorePages()) + <a href="{{ $paginator->nextPageUrl() }}" rel="next" class="relative inline-flex items-center px-2 py-2 -ml-px text-sm font-medium text-gray-500 bg-white border border-gray-300 rounded-r-md leading-5 hover:text-gray-400 focus:z-10 focus:outline-none focus:ring ring-gray-300 focus:border-blue-300 active:bg-gray-100 active:text-gray-500 transition ease-in-out duration-150" aria-label="{{ __('pagination.next') }}"> + <svg class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20"> + <path fill-rule="evenodd" d="M7.293 14.707a1 1 0 010-1.414L10.586 10 7.293 6.707a1 1 0 011.414-1.414l4 4a1 1 0 010 1.414l-4 4a1 1 0 01-1.414 0z" clip-rule="evenodd" /> + </svg> + </a> + @else + <span aria-disabled="true" aria-label="{{ __('pagination.next') }}"> + <span class="relative inline-flex items-center px-2 py-2 -ml-px text-sm font-medium text-gray-500 bg-white border border-gray-300 cursor-default rounded-r-md leading-5" aria-hidden="true"> + <svg class="w-5 h-5" fill="currentColor" viewBox="0 0 20 20"> + <path fill-rule="evenodd" d="M7.293 14.707a1 1 0 010-1.414L10.586 10 7.293 6.707a1 1 0 011.414-1.414l4 4a1 1 0 010 1.414l-4 4a1 1 0 01-1.414 0z" clip-rule="evenodd" /> + </svg> + </span> + </span> + @endif + </span> + </div> + </div> + </nav> +@endif diff --git a/routes/web.php b/routes/web.php index 5c9877a78394b5bf25dea27d24b10693c0e21f3a..e30317dbae867d467209634e135a5d43f27a9a1b 100644 --- a/routes/web.php +++ b/routes/web.php @@ -113,3 +113,5 @@ Route::post('/Insert_transfer',[App\Http\Controllers\MemberController::class, 'Insert_transfer'])->name('Insert_transfer'); +// Route::post()->name() +