fix:edit booking blade
This commit is contained in:
@@ -23,5 +23,15 @@ if (!function_exists('getUserFullName')) {
|
|||||||
}
|
}
|
||||||
return Storage::disk('public')->url($file->path);
|
return Storage::disk('public')->url($file->path);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!function_exists('activeAccountSidebar')) {
|
||||||
|
function activeAccountSidebar(string $routeName): string
|
||||||
|
{
|
||||||
|
if (\Illuminate\Support\Facades\Route::currentRouteName() == $routeName) {
|
||||||
|
return 'bg-blue-500/10 text-blue-500';
|
||||||
|
}
|
||||||
|
return 'hover:text-blue-500';
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -28,6 +28,8 @@ class TourController extends Controller
|
|||||||
|
|
||||||
$tour->load([
|
$tour->load([
|
||||||
'file',
|
'file',
|
||||||
|
'tourDates',
|
||||||
|
|
||||||
'comments' => function ($query) {
|
'comments' => function ($query) {
|
||||||
$query->where('status', CommentStatus::APPROVED)
|
$query->where('status', CommentStatus::APPROVED)
|
||||||
->with('user')
|
->with('user')
|
||||||
|
|||||||
@@ -0,0 +1,64 @@
|
|||||||
|
@extends('account.layouts.app')
|
||||||
|
@section('title', 'رزروهای من')
|
||||||
|
@section('account-content')
|
||||||
|
<div class="user-profile-wrapper">
|
||||||
|
<div class="col-lg-12 mb-4">
|
||||||
|
<div class="user-profile-card">
|
||||||
|
<h4 class="user-profile-card-title">
|
||||||
|
رزروهای من
|
||||||
|
</h4>
|
||||||
|
@forelse($bookings as $booking)
|
||||||
|
<div class="border-bottom py-4">
|
||||||
|
@if($booking->flight)
|
||||||
|
<h5>
|
||||||
|
رزرو پرواز
|
||||||
|
</h5>
|
||||||
|
<p>
|
||||||
|
{{ $booking->flight->departureAirport->city->name }}
|
||||||
|
|
||||||
|
<i class="far fa-exchange mx-1"></i>
|
||||||
|
|
||||||
|
{{ $booking->flight->arrivalAirport->city->name }}
|
||||||
|
</p>
|
||||||
|
|
||||||
|
@elseif($booking->tourDate && $booking->tourDate->tour)
|
||||||
|
<h5>
|
||||||
|
رزرو تور
|
||||||
|
</h5>
|
||||||
|
|
||||||
|
<p>
|
||||||
|
{{ $booking->tourDate->tour->title }}
|
||||||
|
</p>
|
||||||
|
@endif
|
||||||
|
<p>
|
||||||
|
کد پیگیری:
|
||||||
|
{{ $booking->tracking_code }}
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
بزرگسال:
|
||||||
|
{{ $booking->adult_count }}
|
||||||
|
-
|
||||||
|
کودک:
|
||||||
|
{{ $booking->child_count }}
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
مبلغ:
|
||||||
|
{{ number_format($booking->total_price) }}
|
||||||
|
تومان
|
||||||
|
</p>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
@empty
|
||||||
|
<div class="text-center py-5">
|
||||||
|
<p>
|
||||||
|
هنوز رزروی ثبت نکردهاید.
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
@endforelse
|
||||||
|
<div class="mt-4">
|
||||||
|
{{ $bookings->links() }}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
@endsection
|
||||||
Reference in New Issue
Block a user