feat: complete tour in admin side
This commit is contained in:
@@ -122,7 +122,7 @@ class TourController extends Controller
|
|||||||
|
|
||||||
'duration' => $request->input('duration'),
|
'duration' => $request->input('duration'),
|
||||||
|
|
||||||
'views' => 0,
|
'departure_time' => $request->input('departure_time'),
|
||||||
|
|
||||||
'price' => $request->input('price'),
|
'price' => $request->input('price'),
|
||||||
|
|
||||||
@@ -206,6 +206,10 @@ class TourController extends Controller
|
|||||||
|
|
||||||
'duration' => $request->input('duration'),
|
'duration' => $request->input('duration'),
|
||||||
|
|
||||||
|
'views' => 0,
|
||||||
|
|
||||||
|
'departure_time' => $request->input('departure_time'),
|
||||||
|
|
||||||
'price' => $request->input('price'),
|
'price' => $request->input('price'),
|
||||||
|
|
||||||
'status' => $request->input('status'),
|
'status' => $request->input('status'),
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ class IndexController extends Controller
|
|||||||
public function index()
|
public function index()
|
||||||
{
|
{
|
||||||
$flights = Flight::query()
|
$flights = Flight::query()
|
||||||
|
->where('status', \App\Enums\FlightStatus::ENABLE)
|
||||||
->with([
|
->with([
|
||||||
'airport.city',
|
'airport.city',
|
||||||
'airline',
|
'airline',
|
||||||
@@ -23,6 +24,7 @@ class IndexController extends Controller
|
|||||||
->paginate();
|
->paginate();
|
||||||
|
|
||||||
$tours = Tour::query()
|
$tours = Tour::query()
|
||||||
|
->where('status', \App\Enums\TourStatus::ENABLE)
|
||||||
->orderByDesc('created_at')
|
->orderByDesc('created_at')
|
||||||
->limit(10)
|
->limit(10)
|
||||||
->paginate();
|
->paginate();
|
||||||
|
|||||||
@@ -59,6 +59,11 @@ class tourStoreRequest extends FormRequest
|
|||||||
'integer',
|
'integer',
|
||||||
'min:1',
|
'min:1',
|
||||||
],
|
],
|
||||||
|
'departure_time' => [
|
||||||
|
'required',
|
||||||
|
'date',
|
||||||
|
'after_or_equal:today',
|
||||||
|
],
|
||||||
|
|
||||||
'price' => [
|
'price' => [
|
||||||
'required',
|
'required',
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ class tourUpdateRequest extends FormRequest
|
|||||||
*/
|
*/
|
||||||
public function authorize(): bool
|
public function authorize(): bool
|
||||||
{
|
{
|
||||||
return false;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -59,6 +59,11 @@ class tourUpdateRequest extends FormRequest
|
|||||||
'integer',
|
'integer',
|
||||||
'min:1',
|
'min:1',
|
||||||
],
|
],
|
||||||
|
'departure_time' => [
|
||||||
|
'required',
|
||||||
|
'date',
|
||||||
|
'after_or_equal:today',
|
||||||
|
],
|
||||||
|
|
||||||
'price' => [
|
'price' => [
|
||||||
'required',
|
'required',
|
||||||
|
|||||||
@@ -70,19 +70,22 @@
|
|||||||
<!-- End::slide -->
|
<!-- End::slide -->
|
||||||
|
|
||||||
<!-- Start::slide -->
|
<!-- Start::slide -->
|
||||||
|
@if(auth('admin')->user()->permission?->admin_view)
|
||||||
<li class="slide ">
|
<li class="slide ">
|
||||||
<a href=""
|
<a href="{{ route('admin.tours.index') }}"
|
||||||
class="side-menu__item {{activeAdminSidebar(['admin.orders.index' , 'admin.orders.shoe', 'admin.orders.edit'])}}">
|
class="side-menu__item {{activeAdminSidebar(['admin.tour.index' , 'admin.tour.create', 'admin.tour.edit'])}}">
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" class="side-menu__icon" width="1em"
|
<svg xmlns="http://www.w3.org/2000/svg" class="side-menu__icon"
|
||||||
|
width="1em"
|
||||||
height="1em" viewBox="0 0 24 24">
|
height="1em" viewBox="0 0 24 24">
|
||||||
<path fill="none" stroke="currentColor" stroke-linecap="round"
|
<path fill="none" stroke="currentColor" stroke-linecap="round"
|
||||||
stroke-linejoin="round" stroke-width="1.5"
|
stroke-linejoin="round" stroke-width="1.5"
|
||||||
d="M2.5 12c0-4.478 0-6.718 1.391-8.109S7.521 2.5 12 2.5c4.478 0 6.718 0 8.109 1.391S21.5 7.521 21.5 12c0 4.478 0 6.718-1.391 8.109S16.479 21.5 12 21.5c-4.478 0-6.718 0-8.109-1.391S2.5 16.479 2.5 12M11 7h6M7 7h1m-1 5h1m-1 5h1m3-5h6m-6 5h6"
|
d="M2.5 12c0-4.478 0-6.718 1.391-8.109S7.521 2.5 12 2.5c4.478 0 6.718 0 8.109 1.391S21.5 7.521 21.5 12c0 4.478 0 6.718-1.391 8.109S16.479 21.5 12 21.5c-4.478 0-6.718 0-8.109-1.391S2.5 16.479 2.5 12M11 7h6M7 7h1m-1 5h1m-1 5h1m3-5h6m-6 5h6"
|
||||||
color="currentColor"></path>
|
color="currentColor"></path>
|
||||||
</svg>
|
</svg>
|
||||||
<span class="side-menu__label">مدیریت سفارشات</span>
|
<span class="side-menu__label">مدیریت تورها</span>
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
@endif
|
||||||
<!-- End::slide -->
|
<!-- End::slide -->
|
||||||
|
|
||||||
<!-- Start::slide -->
|
<!-- Start::slide -->
|
||||||
|
|||||||
@@ -1,17 +1,264 @@
|
|||||||
@extends('admin.layouts.app')
|
@extends('admin.layouts.app')
|
||||||
@section('breadcrumb')<div><h1 class="page-title fw-medium fs-18 mb-1">درج تور</h1><span class="text-muted fs-12">فیلدهای مورد نیاز سفر</span></div>@endsection
|
|
||||||
@section('content')<div class="container-fluid pt-4">@include('admin.partials.errors')<form action="{{ isset($tour) ? route('admin.tours.update',$tour) : route('admin.tours.store') }}" method="POST" enctype="multipart/form-data">@csrf @if(false) @method('PUT') @endif
|
@section('content')
|
||||||
<div class="row g-3"><div class="col-xl-8"><div class="card custom-card"><div class="card-header"><div class="card-title">اطلاعات تور</div></div><div class="card-body"><div class="row gy-3">
|
<div class="main-content app-content">
|
||||||
<div class="col-md-6"><label class="form-label">عنوان سفر *</label><input class="form-control" name="title" value="{{ old('title',$tour->title ?? '') }}" required></div>
|
<div class="container-fluid pt-4">
|
||||||
<div class="col-md-6"><label class="form-label">مدت تور (روز) *</label><input type="number" min="1" class="form-control" name="duration" value="{{ old('duration',$tour->duration ?? '') }}" required></div>
|
|
||||||
<div class="col-md-6"><label class="form-label">مبدأ *</label><input class="form-control" name="origin" value="{{ old('origin',$tour->origin ?? '') }}" required></div>
|
<div class="row">
|
||||||
<div class="col-md-6"><label class="form-label">مقصد *</label><input class="form-control" name="destination" value="{{ old('destination',$tour->destination ?? '') }}" required></div>
|
<div class="col-xl-12">
|
||||||
<div class="col-md-6"><label class="form-label">قیمت پایه</label><input type="number" min="0" class="form-control" name="price" value="{{ old('price',$tour->price ?? '') }}"></div>
|
|
||||||
<div class="col-md-6"><label class="form-label">وضعیت</label><select class="form-control" name="status"><option value="1" @selected((string)old('status',$tour->status ?? 1)==='1')>فعال</option><option value="0" @selected((string)old('status',$tour->status ?? 1)==='0')>غیرفعال</option></select></div>
|
<form action="{{ route('admin.tours.store') }}" method="POST" enctype="multipart/form-data">
|
||||||
<div class="col-12"><label class="form-label">خلاصه تور *</label><textarea class="form-control" name="summary" rows="3" required>{{ old('summary',$tour->summary ?? '') }}</textarea></div>
|
|
||||||
<div class="col-12"><label class="form-label">توضیحات *</label><textarea class="form-control" name="descriptions" rows="7" required>{{ old('descriptions',$tour->descriptions ?? '') }}</textarea></div>
|
@csrf
|
||||||
</div></div></div></div><div class="col-xl-4"><div class="card custom-card"><div class="card-header"><div class="card-title">تصویر تور</div></div><div class="card-body"><input type="file" class="form-control" name="image" accept="image/*"><small class="text-muted d-block mt-2">تصویر اختیاری است.</small></div></div></div></div>
|
|
||||||
<div class="card custom-card mt-3"><div class="card-footer d-flex justify-content-end gap-2"><a href="{{ route('admin.tours.index') }}" class="btn btn-light">انصراف</a><button class="btn btn-primary">{{ isset($tour) ? 'ذخیره تغییرات' : 'ثبت تور' }}</button></div></div></form>
|
@error('general')
|
||||||
@if(false)<div class="card custom-card mt-3"><div class="card-header d-flex justify-content-between align-items-center"><div class="card-title mb-0">تاریخهای تور</div></div><div class="card-body"><form method="POST" action="{{ route('admin.tour-dates.store',$tour) }}">@csrf<div class="row g-2"><div class="col-md-3"><input class="form-control jalali-date" name="start_date_jalali" placeholder="شروع شمسی" required></div><div class="col-md-3"><input class="form-control jalali-date" name="end_date_jalali" placeholder="پایان شمسی" required></div><div class="col-md-2"><input type="number" min="0" class="form-control" name="price" placeholder="قیمت" required></div><div class="col-md-2"><input type="number" min="1" class="form-control" name="capacity" placeholder="ظرفیت" required></div><div class="col-md-2"><button class="btn btn-primary w-100">افزودن تاریخ</button></div></div></form><hr><div class="table-responsive"><table class="table text-nowrap"><thead><tr><th>شروع</th><th>پایان</th><th>قیمت</th><th>ظرفیت</th><th>وضعیت</th><th></th></tr></thead><tbody>@forelse(($tour->tourDates ?? []) as $date)<tr><td>{{ $date->start_date->toJalali()->format('Y/m/d') }}</td><td>{{ $date->end_date->toJalali()->format('Y/m/d') }}</td><td>{{ number_format($date->price) }}</td><td>{{ $date->capacity }}</td><td>{{ $date->status ? 'فعال':'غیرفعال' }}</td><td><form method="POST" action="{{ route('admin.tour-dates.destroy',$date) }}" onsubmit="return confirm('حذف تاریخ تور؟')">@csrf @method('DELETE')<button class="btn btn-danger-light btn-sm">حذف</button></form></td></tr>@empty<tr><td colspan="6" class="text-center text-muted">تاریخی برای این تور ثبت نشده است.</td></tr>@endforelse</tbody></table></div></div></div>@endif
|
<span class="text-danger">{{ $message }}</span>
|
||||||
</div>@endsection
|
@enderror
|
||||||
@push('scripts')<script>$(function(){ if($.fn.persianDatepicker){ $('.jalali-date').persianDatepicker({format:'YYYY/MM/DD',autoClose:true}); }});</script>@endpush
|
|
||||||
|
<div class="card custom-card">
|
||||||
|
|
||||||
|
<div class="card-header">
|
||||||
|
<div class="card-title">
|
||||||
|
ایجاد تور
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="card-body pt-0">
|
||||||
|
|
||||||
|
<div class="row gy-3">
|
||||||
|
|
||||||
|
<!-- Title -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">عنوان تور</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="title"
|
||||||
|
placeholder="عنوان تور را وارد کنید"
|
||||||
|
value="{{ old('title') }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('title')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Origin -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">مبدأ</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="origin"
|
||||||
|
placeholder="مبدأ تور را وارد کنید"
|
||||||
|
value="{{ old('origin') }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('origin')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Destination -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">مقصد</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="destination"
|
||||||
|
placeholder="مقصد تور را وارد کنید"
|
||||||
|
value="{{ old('destination') }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('destination')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Departure Time -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">تاریخ و زمان حرکت</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="departure_time_jalali"
|
||||||
|
id="departure_time_jalali"
|
||||||
|
data-jdp
|
||||||
|
data-jdp-target-value-input="#departure_time_gregorian"
|
||||||
|
data-jdp-target-value-type="gregorian"
|
||||||
|
autocomplete="off"
|
||||||
|
placeholder="مثلاً 1403/05/29 14:30"
|
||||||
|
value="{{ old('departure_time_jalali') }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="hidden"
|
||||||
|
name="departure_time"
|
||||||
|
id="departure_time_gregorian"
|
||||||
|
value="{{ old('departure_time') }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('departure_time')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Duration -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">مدت تور</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="number"
|
||||||
|
class="form-control"
|
||||||
|
name="duration"
|
||||||
|
placeholder="مدت تور را وارد کنید"
|
||||||
|
value="{{ old('duration') }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('duration')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Price -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">قیمت</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="number"
|
||||||
|
class="form-control"
|
||||||
|
name="price"
|
||||||
|
placeholder="قیمت تور را وارد کنید"
|
||||||
|
value="{{ old('price') }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('price')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Status -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">وضعیت</label>
|
||||||
|
|
||||||
|
<select class="form-control" name="status">
|
||||||
|
|
||||||
|
<option
|
||||||
|
value="0"
|
||||||
|
@selected(old('status') == '0')
|
||||||
|
>
|
||||||
|
غیرفعال
|
||||||
|
</option>
|
||||||
|
|
||||||
|
<option
|
||||||
|
value="1"
|
||||||
|
@selected(old('status', '1') == '1')
|
||||||
|
>
|
||||||
|
فعال
|
||||||
|
</option>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
|
||||||
|
@error('status')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Summary -->
|
||||||
|
<div class="col-xl-12">
|
||||||
|
<label class="form-label">خلاصه</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="summary"
|
||||||
|
placeholder="خلاصهای از تور"
|
||||||
|
value="{{ old('summary') }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('summary')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Description -->
|
||||||
|
<div class="col-xl-12">
|
||||||
|
<label class="form-label">توضیحات</label>
|
||||||
|
|
||||||
|
<textarea
|
||||||
|
class="form-control"
|
||||||
|
name="description"
|
||||||
|
rows="4"
|
||||||
|
placeholder="توضیحات تور را وارد کنید"
|
||||||
|
>{{ old('description') }}</textarea>
|
||||||
|
|
||||||
|
@error('description')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Image -->
|
||||||
|
<div class="col-xl-12">
|
||||||
|
|
||||||
|
<label class="form-label">تصویر تور</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="file"
|
||||||
|
class="form-control"
|
||||||
|
name="image"
|
||||||
|
accept=".jpg,.jpeg,.png,.webp"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('image')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="card-footer text-end">
|
||||||
|
|
||||||
|
<button type="submit" class="btn btn-primary">
|
||||||
|
ایجاد تور
|
||||||
|
</button>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="https://unpkg.com/@majidh1/jalalidatepicker/dist/jalalidatepicker.min.css">
|
||||||
|
<script src="https://unpkg.com/@majidh1/jalalidatepicker/dist/jalalidatepicker.min.js"></script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
jalaliDatepicker.startWatch({
|
||||||
|
date: true,
|
||||||
|
time: true,
|
||||||
|
hasSecond: false,
|
||||||
|
targetValueInput: 'attr',
|
||||||
|
targetValueType: 'attr',
|
||||||
|
minDate: 'today'
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
@endsection
|
||||||
|
|||||||
@@ -1,17 +1,275 @@
|
|||||||
@extends('admin.layouts.app')
|
@extends('admin.layouts.app')
|
||||||
@section('breadcrumb')<div><h1 class="page-title fw-medium fs-18 mb-1">{{ isset($tour) ? 'ویرایش تور' : 'درج تور' }}</h1><span class="text-muted fs-12">فیلدهای مورد نیاز سفر</span></div>@endsection
|
|
||||||
@section('content')<div class="container-fluid pt-4">@include('admin.partials.errors')<form action="{{ isset($tour) ? route('admin.tours.update',$tour) : route('admin.tours.store') }}" method="POST" enctype="multipart/form-data">@csrf @if(isset($tour)) @method('PUT') @endif
|
@section('content')
|
||||||
<div class="row g-3"><div class="col-xl-8"><div class="card custom-card"><div class="card-header"><div class="card-title">اطلاعات تور</div></div><div class="card-body"><div class="row gy-3">
|
<div class="main-content app-content">
|
||||||
<div class="col-md-6"><label class="form-label">عنوان سفر *</label><input class="form-control" name="title" value="{{ old('title',$tour->title ?? '') }}" required></div>
|
<div class="container-fluid pt-4">
|
||||||
<div class="col-md-6"><label class="form-label">مدت تور (روز) *</label><input type="number" min="1" class="form-control" name="duration" value="{{ old('duration',$tour->duration ?? '') }}" required></div>
|
|
||||||
<div class="col-md-6"><label class="form-label">مبدأ *</label><input class="form-control" name="origin" value="{{ old('origin',$tour->origin ?? '') }}" required></div>
|
<div class="row">
|
||||||
<div class="col-md-6"><label class="form-label">مقصد *</label><input class="form-control" name="destination" value="{{ old('destination',$tour->destination ?? '') }}" required></div>
|
<div class="col-xl-12">
|
||||||
<div class="col-md-6"><label class="form-label">قیمت پایه</label><input type="number" min="0" class="form-control" name="price" value="{{ old('price',$tour->price ?? '') }}"></div>
|
|
||||||
<div class="col-md-6"><label class="form-label">وضعیت</label><select class="form-control" name="status"><option value="1" @selected((string)old('status',$tour->status ?? 1)==='1')>فعال</option><option value="0" @selected((string)old('status',$tour->status ?? 1)==='0')>غیرفعال</option></select></div>
|
@error('error')
|
||||||
<div class="col-12"><label class="form-label">خلاصه تور *</label><textarea class="form-control" name="summary" rows="3" required>{{ old('summary',$tour->summary ?? '') }}</textarea></div>
|
<span class="text-danger">{{ $message }}</span>
|
||||||
<div class="col-12"><label class="form-label">توضیحات *</label><textarea class="form-control" name="descriptions" rows="7" required>{{ old('descriptions',$tour->descriptions ?? '') }}</textarea></div>
|
@enderror
|
||||||
</div></div></div></div><div class="col-xl-4"><div class="card custom-card"><div class="card-header"><div class="card-title">تصویر تور</div></div><div class="card-body"><input type="file" class="form-control" name="image" accept="image/*"><small class="text-muted d-block mt-2">تصویر اختیاری است.</small></div></div></div></div>
|
|
||||||
<div class="card custom-card mt-3"><div class="card-footer d-flex justify-content-end gap-2"><a href="{{ route('admin.tours.index') }}" class="btn btn-light">انصراف</a><button class="btn btn-primary">{{ isset($tour) ? 'ذخیره تغییرات' : 'ثبت تور' }}</button></div></div></form>
|
|
||||||
@if(isset($tour))<div class="card custom-card mt-3"><div class="card-header d-flex justify-content-between align-items-center"><div class="card-title mb-0">تاریخهای تور</div></div><div class="card-body"><form method="POST" action="{{ route('admin.tour-dates.store',$tour) }}">@csrf<div class="row g-2"><div class="col-md-3"><input class="form-control jalali-date" name="start_date_jalali" placeholder="شروع شمسی" required></div><div class="col-md-3"><input class="form-control jalali-date" name="end_date_jalali" placeholder="پایان شمسی" required></div><div class="col-md-2"><input type="number" min="0" class="form-control" name="price" placeholder="قیمت" required></div><div class="col-md-2"><input type="number" min="1" class="form-control" name="capacity" placeholder="ظرفیت" required></div><div class="col-md-2"><button class="btn btn-primary w-100">افزودن تاریخ</button></div></div></form><hr><div class="table-responsive"><table class="table text-nowrap"><thead><tr><th>شروع</th><th>پایان</th><th>قیمت</th><th>ظرفیت</th><th>وضعیت</th><th></th></tr></thead><tbody>@forelse(($tour->tourDates ?? []) as $date)<tr><td>{{ $date->start_date->toJalali()->format('Y/m/d') }}</td><td>{{ $date->end_date->toJalali()->format('Y/m/d') }}</td><td>{{ number_format($date->price) }}</td><td>{{ $date->capacity }}</td><td>{{ $date->status ? 'فعال':'غیرفعال' }}</td><td><form method="POST" action="{{ route('admin.tour-dates.destroy',$date) }}" onsubmit="return confirm('حذف تاریخ تور؟')">@csrf @method('DELETE')<button class="btn btn-danger-light btn-sm">حذف</button></form></td></tr>@empty<tr><td colspan="6" class="text-center text-muted">تاریخی برای این تور ثبت نشده است.</td></tr>@endforelse</tbody></table></div></div></div>@endif
|
<form action="{{ route('admin.tours.update', $tour) }}" method="POST" enctype="multipart/form-data">
|
||||||
</div>@endsection
|
@csrf
|
||||||
@push('scripts')<script>$(function(){ if($.fn.persianDatepicker){ $('.jalali-date').persianDatepicker({format:'YYYY/MM/DD',autoClose:true}); }});</script>@endpush
|
@method('put')
|
||||||
|
|
||||||
|
<div class="card custom-card">
|
||||||
|
|
||||||
|
<div class="card-header">
|
||||||
|
<div class="card-title">
|
||||||
|
ویرایش تور
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="card-body pt-0">
|
||||||
|
|
||||||
|
<div class="row gy-3">
|
||||||
|
|
||||||
|
<!-- Title -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">عنوان تور</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="title"
|
||||||
|
placeholder="عنوان تور را وارد کنید"
|
||||||
|
value="{{ old('title', $tour->title) }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('title')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Origin -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">مبدأ</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="origin"
|
||||||
|
placeholder="مبدأ تور را وارد کنید"
|
||||||
|
value="{{ old('origin', $tour->origin) }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('origin')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Destination -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">مقصد</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="destination"
|
||||||
|
placeholder="مقصد تور را وارد کنید"
|
||||||
|
value="{{ old('destination', $tour->destination) }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('destination')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- Departure Time -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">تاریخ و زمان حرکت</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="departure_time_jalali"
|
||||||
|
id="departure_time_jalali"
|
||||||
|
data-jdp
|
||||||
|
data-jdp-target-value-input="#departure_time_gregorian"
|
||||||
|
data-jdp-target-value-type="gregorian"
|
||||||
|
autocomplete="off"
|
||||||
|
placeholder="مثلاً 1403/05/29 14:30"
|
||||||
|
value="{{ old('departure_time_jalali', $tour->departure_time ? verta($tour->departure_time)->format('Y/m/d H:i') : '') }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="hidden"
|
||||||
|
name="departure_time"
|
||||||
|
id="departure_time_gregorian"
|
||||||
|
value="{{ old('departure_time', optional($tour->departure_time)->format('Y-m-d H:i:s')) }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('departure_time')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Duration -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">مدت تور</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="number"
|
||||||
|
class="form-control"
|
||||||
|
name="duration"
|
||||||
|
placeholder="مدت تور را وارد کنید"
|
||||||
|
value="{{ old('duration', $tour->duration) }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('duration')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Price -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">قیمت</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="number"
|
||||||
|
class="form-control"
|
||||||
|
name="price"
|
||||||
|
placeholder="قیمت تور را وارد کنید"
|
||||||
|
value="{{ old('price', $tour->price) }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('price')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Status -->
|
||||||
|
<div class="col-xl-6">
|
||||||
|
<label class="form-label">وضعیت</label>
|
||||||
|
|
||||||
|
<select class="form-control" name="status">
|
||||||
|
|
||||||
|
<option
|
||||||
|
value="0"
|
||||||
|
@selected(old('status', $tour->status) == 0)
|
||||||
|
>
|
||||||
|
غیرفعال
|
||||||
|
</option>
|
||||||
|
|
||||||
|
<option
|
||||||
|
value="1"
|
||||||
|
@selected(old('status', $tour->status) == 1)
|
||||||
|
>
|
||||||
|
فعال
|
||||||
|
</option>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
|
||||||
|
@error('status')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Summary -->
|
||||||
|
<div class="col-xl-12">
|
||||||
|
<label class="form-label">خلاصه</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="text"
|
||||||
|
class="form-control"
|
||||||
|
name="summary"
|
||||||
|
placeholder="خلاصهای از تور"
|
||||||
|
value="{{ old('summary', $tour->summary) }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('summary')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Description -->
|
||||||
|
<div class="col-xl-12">
|
||||||
|
<label class="form-label">توضیحات</label>
|
||||||
|
|
||||||
|
<textarea
|
||||||
|
class="form-control"
|
||||||
|
name="description"
|
||||||
|
rows="4"
|
||||||
|
placeholder="توضیحات تور را وارد کنید"
|
||||||
|
>{{ old('description', $tour->description) }}</textarea>
|
||||||
|
|
||||||
|
@error('description')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Image -->
|
||||||
|
<div class="col-xl-12">
|
||||||
|
<label class="form-label">تصویر تور</label>
|
||||||
|
|
||||||
|
<input
|
||||||
|
type="file"
|
||||||
|
class="form-control"
|
||||||
|
name="image"
|
||||||
|
accept=".jpg,.jpeg,.png,.webp"
|
||||||
|
>
|
||||||
|
|
||||||
|
@error('image')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
|
||||||
|
@if($tour->file)
|
||||||
|
<div class="mt-3">
|
||||||
|
<img
|
||||||
|
src="{{ getFileUrl($tour->file->id) }}"
|
||||||
|
alt="{{ $tour->title }}"
|
||||||
|
style="width:150px;height:150px;object-fit:cover;border-radius:8px;"
|
||||||
|
>
|
||||||
|
</div>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="card-footer text-end">
|
||||||
|
|
||||||
|
<button type="submit" class="btn btn-primary">
|
||||||
|
ذخیره تغییرات
|
||||||
|
</button>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="https://unpkg.com/@majidh1/jalalidatepicker/dist/jalalidatepicker.min.css">
|
||||||
|
<script src="https://unpkg.com/@majidh1/jalalidatepicker/dist/jalalidatepicker.min.js"></script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
jalaliDatepicker.startWatch({
|
||||||
|
date: true,
|
||||||
|
time: true,
|
||||||
|
hasSecond: false,
|
||||||
|
targetValueInput: 'attr',
|
||||||
|
targetValueType: 'attr',
|
||||||
|
minDate: 'today'
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
@endsection
|
||||||
|
|||||||
@@ -1,3 +1,313 @@
|
|||||||
@extends('admin.layouts.app')
|
@extends('admin.layouts.app')
|
||||||
@section('breadcrumb')<div><h1 class="page-title fw-medium fs-18 mb-1">مدیریت تورها</h1><span class="text-muted fs-12">درج، ویرایش، حذف و مدیریت تورهای داخلی و خارجی</span></div>@endsection
|
|
||||||
@section('content')<div class="container-fluid pt-4">@include('admin.partials.errors')<div class="card custom-card"><div class="card-body"><form method="GET"><div class="row g-2"><div class="col-md-5"><input class="form-control" name="search" value="{{ request('search') }}" placeholder="عنوان، مبدأ یا مقصد"></div><div class="col-md-2"><select class="form-control" name="status"><option value="">همه وضعیتها</option><option value="1" @selected(request('status')==='1')>فعال</option><option value="0" @selected(request('status')==='0')>غیرفعال</option></select></div><div class="col-md-2"><button class="btn btn-light w-100">جستجو</button></div><div class="col-md-3"><a href="{{ route('admin.tours.create') }}" class="btn btn-primary w-100"><i class="ri-add-line"></i> تور جدید</a></div></div></form></div></div><div class="card custom-card mt-3"><div class="table-responsive"><table class="table text-nowrap table-hover mb-0"><thead><tr><th>عنوان تور</th><th>مسیر</th><th>مدت</th><th>قیمت</th><th>بازدید</th><th>وضعیت</th><th>عملیات</th></tr></thead><tbody>@forelse(($tours ?? []) as $tour)<tr><td><div class="fw-semibold">{{ $tour->title }}</div><small class="text-muted">#{{ $tour->id }}</small></td><td>{{ $tour->origin }} ← {{ $tour->destination }}</td><td>{{ $tour->duration }} روز</td><td>{{ number_format($tour->price ?? 0) }} تومان</td><td>{{ number_format($tour->views ?? 0) }}</td><td>@if($tour->status)<span class="badge bg-success-transparent">فعال</span>@else<span class="badge bg-danger-transparent">غیرفعال</span>@endif</td><td><div class="hstack gap-2"><a href="{{ route('admin.tours.show',$tour) }}" class="btn btn-primary-light btn-icon btn-sm"><i class="ri-eye-line"></i></a><a href="{{ route('admin.tours.edit',$tour) }}" class="btn btn-secondary-light btn-icon btn-sm"><i class="ri-edit-line"></i></a><form method="POST" action="{{ route('admin.tours.destroy',$tour) }}" onsubmit="return confirm('حذف این تور؟')">@csrf @method('DELETE')<button class="btn btn-danger-light btn-icon btn-sm"><i class="ri-delete-bin-line"></i></button></form></div></td></tr>@empty<tr><td colspan="7" class="text-center py-5 text-muted">توری ثبت نشده است.</td></tr>@endforelse</tbody></table></div></div>{{ ($tours ?? collect())->links() }}</div>@endsection
|
@section('breadcrumb')
|
||||||
|
<div>
|
||||||
|
<h1 class="page-title fw-medium fs-18 mb-2">لیست تورها</h1>
|
||||||
|
<div>
|
||||||
|
<nav>
|
||||||
|
<ol class="breadcrumb mb-0">
|
||||||
|
<li class="breadcrumb-item">
|
||||||
|
<a href="javascript:void(0)">مدیریت تورها</a>
|
||||||
|
</li>
|
||||||
|
<li class="breadcrumb-item active" aria-current="page">
|
||||||
|
لیست تورها
|
||||||
|
</li>
|
||||||
|
</ol>
|
||||||
|
</nav>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
@endsection
|
||||||
|
|
||||||
|
@section('content')
|
||||||
|
<div class="main-content app-content">
|
||||||
|
<div class="container-fluid pt-4">
|
||||||
|
|
||||||
|
@error('success')
|
||||||
|
<span class="text-success">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
|
||||||
|
@error('errors')
|
||||||
|
<span class="text-danger">{{ $message }}</span>
|
||||||
|
@enderror
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-xl-12">
|
||||||
|
<div class="card custom-card">
|
||||||
|
|
||||||
|
<div class="card-body p-3">
|
||||||
|
|
||||||
|
<form method="GET">
|
||||||
|
|
||||||
|
<div class="d-flex align-items-center justify-content-between flex-wrap gap-3">
|
||||||
|
|
||||||
|
<div class="d-flex flex-wrap gap-1 project-list-main align-items-center">
|
||||||
|
|
||||||
|
<div class="d-flex me-2">
|
||||||
|
|
||||||
|
<input
|
||||||
|
class="form-control me-2"
|
||||||
|
type="search"
|
||||||
|
name="search"
|
||||||
|
placeholder="جستجو تور"
|
||||||
|
value="{{ request()->input('search') }}"
|
||||||
|
aria-label="جستجو"
|
||||||
|
>
|
||||||
|
|
||||||
|
<button class="btn btn-light" type="submit">
|
||||||
|
جستجو
|
||||||
|
</button>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<select
|
||||||
|
id="choices-single-default"
|
||||||
|
class="form-control"
|
||||||
|
name="sort"
|
||||||
|
>
|
||||||
|
|
||||||
|
<option value="" selected>
|
||||||
|
مرتبسازی بر اساس
|
||||||
|
</option>
|
||||||
|
|
||||||
|
<option
|
||||||
|
value="created_at"
|
||||||
|
@selected(request()->input('sort') == 'created_at')
|
||||||
|
>
|
||||||
|
جدیدترین
|
||||||
|
</option>
|
||||||
|
|
||||||
|
<option
|
||||||
|
value="price_asc"
|
||||||
|
@selected(request()->input('sort') == 'price_asc')
|
||||||
|
>
|
||||||
|
قیمت (کم به زیاد)
|
||||||
|
</option>
|
||||||
|
|
||||||
|
<option
|
||||||
|
value="price_desc"
|
||||||
|
@selected(request()->input('sort') == 'price_desc')
|
||||||
|
>
|
||||||
|
قیمت (زیاد به کم)
|
||||||
|
</option>
|
||||||
|
|
||||||
|
<option
|
||||||
|
value="duration_asc"
|
||||||
|
@selected(request()->input('sort') == 'duration_asc')
|
||||||
|
>
|
||||||
|
مدت زمان (کم به زیاد)
|
||||||
|
</option>
|
||||||
|
|
||||||
|
<option
|
||||||
|
value="duration_desc"
|
||||||
|
@selected(request()->input('sort') == 'duration_desc')
|
||||||
|
>
|
||||||
|
مدت زمان (زیاد به کم)
|
||||||
|
</option>
|
||||||
|
|
||||||
|
</select>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
@if(auth('admin')->user()->permission?->tour_create)
|
||||||
|
|
||||||
|
<div class="d-flex">
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="{{ route('admin.tours.create') }}"
|
||||||
|
class="btn btn-primary me-2"
|
||||||
|
>
|
||||||
|
<i class="ri-add-line me-1 fw-medium align-middle"></i>
|
||||||
|
ایجاد تور
|
||||||
|
</a>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
@endif
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Tours Table -->
|
||||||
|
<div class="row">
|
||||||
|
|
||||||
|
<div class="col-xl-12">
|
||||||
|
|
||||||
|
<div class="card custom-card">
|
||||||
|
|
||||||
|
<div class="table-responsive">
|
||||||
|
|
||||||
|
<table class="table text-nowrap table-bordered">
|
||||||
|
|
||||||
|
<thead>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<th>عکس</th>
|
||||||
|
<th>عنوان</th>
|
||||||
|
<th>مبدا</th>
|
||||||
|
<th>مقصد</th>
|
||||||
|
<th>زمان حرکت</th>
|
||||||
|
<th>مدت زمان</th>
|
||||||
|
<th>قیمت</th>
|
||||||
|
<th>وضعیت</th>
|
||||||
|
<th>تاریخ ثبت</th>
|
||||||
|
<th>تاریخ ویرایش</th>
|
||||||
|
<th>عملیات</th>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
</thead>
|
||||||
|
|
||||||
|
|
||||||
|
<tbody>
|
||||||
|
|
||||||
|
@foreach($tours as $tour)
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
|
||||||
|
{{-- Image --}}
|
||||||
|
<td>
|
||||||
|
|
||||||
|
<span class="avatar avatar-md avatar-square bg-light">
|
||||||
|
|
||||||
|
@if($tour->file?->id)
|
||||||
|
|
||||||
|
<img
|
||||||
|
src="{{ getFileUrl($tour->file->id) }}"
|
||||||
|
class="w-100 h-100"
|
||||||
|
alt="{{ $tour->title }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@else
|
||||||
|
|
||||||
|
<img
|
||||||
|
src="{{ asset('images/no-image.png') }}"
|
||||||
|
class="w-100 h-100"
|
||||||
|
alt="{{ $tour->title }}"
|
||||||
|
>
|
||||||
|
|
||||||
|
@endif
|
||||||
|
|
||||||
|
</span>
|
||||||
|
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td>
|
||||||
|
|
||||||
|
<span class="fw-semibold">
|
||||||
|
{{ $tour->title }}
|
||||||
|
</span>
|
||||||
|
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td>
|
||||||
|
{{ $tour->origin }}
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td>
|
||||||
|
{{ $tour->destination }}
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td>
|
||||||
|
{{ $tour->departure_time->toJalali()->format('H:i Y-m-d') }}
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td>
|
||||||
|
{{ $tour->duration }} روز
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td>
|
||||||
|
|
||||||
|
{{ number_format($tour->price) }}
|
||||||
|
تومان
|
||||||
|
|
||||||
|
</td>
|
||||||
|
|
||||||
|
<td>
|
||||||
|
|
||||||
|
@if($tour->status == \App\Enums\TourStatus::ENABLE)
|
||||||
|
<span class="badge bg-primary-transparent">فعال</span>
|
||||||
|
@elseif($tour->status == \App\Enums\TourStatus::DISABLE)
|
||||||
|
<span class="badge bg-warning-transparent">غیرفعال</span>
|
||||||
|
@endif
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>{{ $tour->created_at->toJalali()->format('H:i Y-m-d') }}</td>
|
||||||
|
<td>{{ $tour->updated_at->toJalali()->format('H:i Y-m-d') }}</td>
|
||||||
|
|
||||||
|
|
||||||
|
{{-- Actions --}}
|
||||||
|
<td>
|
||||||
|
|
||||||
|
<div class="hstack gap-2 fs-15">
|
||||||
|
|
||||||
|
@if(auth('admin')->user()->permission?->tour_edit)
|
||||||
|
|
||||||
|
<a
|
||||||
|
href="{{ route('admin.tours.edit', $tour->id) }}"
|
||||||
|
class="btn btn-secondary-light btn-icon btn-sm"
|
||||||
|
data-bs-toggle="tooltip"
|
||||||
|
data-bs-placement="top"
|
||||||
|
title="ویرایش"
|
||||||
|
>
|
||||||
|
<i class="ti ti-pencil"></i>
|
||||||
|
</a>
|
||||||
|
|
||||||
|
@endif
|
||||||
|
|
||||||
|
|
||||||
|
@if(auth('admin')->user()->permission?->tour_delete)
|
||||||
|
|
||||||
|
<form
|
||||||
|
action="{{ route('admin.tours.destroy', $tour->id) }}"
|
||||||
|
method="POST"
|
||||||
|
onsubmit="return confirm('آیا از حذف این تور مطمئن هستید؟')"
|
||||||
|
>
|
||||||
|
|
||||||
|
@csrf
|
||||||
|
@method('DELETE')
|
||||||
|
|
||||||
|
<button
|
||||||
|
type="submit"
|
||||||
|
class="btn btn-icon btn-sm btn-danger-light"
|
||||||
|
title="حذف"
|
||||||
|
>
|
||||||
|
<i class="ri-delete-bin-line"></i>
|
||||||
|
</button>
|
||||||
|
|
||||||
|
</form>
|
||||||
|
|
||||||
|
@endif
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</td>
|
||||||
|
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
@endforeach
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
|
||||||
|
</table>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{{ $tours->links() }}
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
@endsection
|
||||||
|
|||||||
Reference in New Issue
Block a user