git commit "update flight page"
This commit is contained in:
@@ -1,129 +1,47 @@
|
||||
@foreach($flights as $flight)
|
||||
<!-- FLIGHT ITEM -->
|
||||
<div class="swiper-slide flight-card group">
|
||||
<div class="col-md-4">
|
||||
<div class="card border-0 shadow-sm rounded-4 overflow-hidden h-100">
|
||||
|
||||
<!-- flight header -->
|
||||
<div class="flight-card_header">
|
||||
<div class="flight-image">
|
||||
|
||||
<div>
|
||||
<span class="flight-airline">
|
||||
{{ $flight->airline }}
|
||||
</span>
|
||||
<img src="{{ asset($flight->image) }}"
|
||||
alt="{{ $flight->airline }}">
|
||||
|
||||
<span class="flight-number">
|
||||
{{ $flight->flight_number }}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
@if($flight->flight_class)
|
||||
<span class="flight-class">
|
||||
{{ $flight->flight_class }}
|
||||
</span>
|
||||
@endif
|
||||
<span class="flight-badge">
|
||||
پرواز
|
||||
</span>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<!-- flight route -->
|
||||
<div class="flight-card_route">
|
||||
<div class="card-body d-flex flex-column">
|
||||
|
||||
<div class="flight-airport">
|
||||
<h5 class="fw-bold">
|
||||
{{ $flight->airline }}
|
||||
</h5>
|
||||
|
||||
<span>
|
||||
مبدا
|
||||
</span>
|
||||
|
||||
<strong>
|
||||
{{ $flight->origin }}
|
||||
</strong>
|
||||
<div class="route">
|
||||
<span>{{ $flight->origin }}</span>
|
||||
|
||||
<span class="line"></span>
|
||||
|
||||
<span>{{ $flight->destination }}</span>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flight-route-line">
|
||||
✈
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flight-airport">
|
||||
|
||||
<span>
|
||||
مقصد
|
||||
</span>
|
||||
<div class="mt-auto d-flex justify-content-between align-items-center">
|
||||
|
||||
<strong>
|
||||
{{ $flight->destination }}
|
||||
{{ number_format($flight->price) }} تومان
|
||||
</strong>
|
||||
|
||||
<a href="{{ route('flights.show',$flight) }}"
|
||||
class="btn btn-primary rounded-pill">
|
||||
مشاهده
|
||||
</a>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<!-- flight details -->
|
||||
<div class="flight-card_details">
|
||||
|
||||
<div>
|
||||
<span>
|
||||
تاریخ پرواز
|
||||
</span>
|
||||
|
||||
<strong>
|
||||
{{ $flight->departure_date?->format('Y/m/d') }}
|
||||
</strong>
|
||||
</div>
|
||||
|
||||
|
||||
<div>
|
||||
<span>
|
||||
ساعت حرکت
|
||||
</span>
|
||||
|
||||
<strong>
|
||||
{{ $flight->departure_time?->format('H:i') }}
|
||||
</strong>
|
||||
</div>
|
||||
|
||||
|
||||
<div>
|
||||
<span>
|
||||
ساعت رسیدن
|
||||
</span>
|
||||
|
||||
<strong>
|
||||
{{ $flight->arrival_time?->format('H:i') }}
|
||||
</strong>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<!-- flight footer -->
|
||||
<div class="flight-card_footer">
|
||||
|
||||
<div class="flight-price">
|
||||
|
||||
<span>
|
||||
قیمت
|
||||
</span>
|
||||
|
||||
<strong>
|
||||
{{ number_format($flight->price) }}
|
||||
|
||||
<small>
|
||||
تومان
|
||||
</small>
|
||||
</strong>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<a href="#" class="flight-detail-button">
|
||||
جزئیات
|
||||
</a>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@endforeach
|
||||
</div></div>
|
||||
|
||||
@@ -1,74 +1,43 @@
|
||||
@foreach($tours as $tour)
|
||||
<!-- TOUR ITEM -->
|
||||
<div class="swiper-slide tour-card group">
|
||||
<div class="swiper-slide">
|
||||
<div class="card border-0 shadow-sm rounded-4 overflow-hidden h-100">
|
||||
|
||||
<!-- tour image -->
|
||||
<a href="#">
|
||||
<div class="position-relative" style="height: 170px;">
|
||||
@if($tour->image)
|
||||
<img src="{{ asset('storage/'.$tour->image) }}"
|
||||
class="w-100 h-100 object-fit-cover"
|
||||
alt="{{ $tour->title }}">
|
||||
@else
|
||||
<div class="w-100 h-100 bg-light"></div>
|
||||
@endif
|
||||
|
||||
<img
|
||||
class="tour-card_img"
|
||||
src="{{ $tour->image ?? asset('assets/img/placeholder.jpg') }}"
|
||||
alt="{{ $tour->title }}"
|
||||
>
|
||||
<span class="position-absolute top-0 end-0 m-2 badge rounded-pill" style="background: var(--teal);">
|
||||
تور
|
||||
</span>
|
||||
</div>
|
||||
|
||||
</a>
|
||||
<div class="card-body d-flex flex-column">
|
||||
<h5 class="card-title fw-bold fs-6 mb-2">{{ $tour->title }}</h5>
|
||||
|
||||
<!-- tour content -->
|
||||
<div class="tour-card_content">
|
||||
@if($tour->summary)
|
||||
<p class="text-secondary small mb-3">{{ \Illuminate\Support\Str::limit($tour->summary, 70) }}</p>
|
||||
@endif
|
||||
|
||||
<!-- title -->
|
||||
<a href="#" class="tour-card_title">
|
||||
{{ $tour->title }}
|
||||
</a>
|
||||
<div class="small text-secondary mb-3">
|
||||
<i class="bi bi-calendar-event"></i>
|
||||
تاریخ حرکت: {{ optional($tour->departure_date)->format('Y/m/d') }}
|
||||
</div>
|
||||
|
||||
<!-- destination -->
|
||||
<div class="tour-card_destination">
|
||||
|
||||
<span>
|
||||
📍
|
||||
<div class="mt-auto d-flex justify-content-between align-items-center">
|
||||
<span class="fw-bold" style="color: var(--blue);">
|
||||
{{ number_format($tour->price) }} تومان
|
||||
</span>
|
||||
|
||||
{{ $tour->destination }}
|
||||
|
||||
<a href="{{ route('tours.show', $tour) }}"
|
||||
class="btn btn-sm rounded-pill px-3 text-white"
|
||||
style="background: var(--blue);">
|
||||
مشاهده
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<!-- details -->
|
||||
<div class="tour-card_details">
|
||||
|
||||
<div>
|
||||
<span>مدت تور</span>
|
||||
|
||||
<strong>
|
||||
{{ $tour->duration }} روز
|
||||
</strong>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<span>ظرفیت</span>
|
||||
|
||||
<strong>
|
||||
{{ $tour->capacity }} نفر
|
||||
</strong>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- price -->
|
||||
<div class="tour-card_price">
|
||||
|
||||
<span>
|
||||
شروع قیمت از
|
||||
</span>
|
||||
|
||||
<strong>
|
||||
{{ number_format($tour->price) }}
|
||||
<small>تومان</small>
|
||||
</strong>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@endforeach
|
||||
</div>
|
||||
|
||||
@@ -1,35 +0,0 @@
|
||||
@extends('layouts.app')
|
||||
|
||||
@section('content')
|
||||
|
||||
<div class="container">
|
||||
|
||||
<h2>آرشیو پروازها</h2>
|
||||
|
||||
@foreach($flights as $flight)
|
||||
|
||||
<div>
|
||||
{{ $flight->airline }}
|
||||
-
|
||||
{{ $flight->flight_number }}
|
||||
|
||||
<br>
|
||||
|
||||
{{ $flight->origin }}
|
||||
→
|
||||
{{ $flight->destination }}
|
||||
|
||||
<br>
|
||||
|
||||
{{ $flight->departure_date }}
|
||||
</div>
|
||||
|
||||
<hr>
|
||||
|
||||
@endforeach
|
||||
|
||||
{{ $flights->links() }}
|
||||
|
||||
</div>
|
||||
|
||||
@endsection
|
||||
@@ -1,136 +0,0 @@
|
||||
@extends('layouts.app')
|
||||
|
||||
@section('content')
|
||||
|
||||
<div class="theme-page-section _pt-100 _pb-100">
|
||||
|
||||
<div class="container">
|
||||
|
||||
<div class="theme-search-results">
|
||||
|
||||
<div class="theme-search-results-header">
|
||||
<h2>نتایج جستجوی پرواز</h2>
|
||||
|
||||
<p>
|
||||
{{ $flights->count() }} پرواز پیدا شد
|
||||
</p>
|
||||
</div>
|
||||
|
||||
|
||||
@forelse($flights as $flight)
|
||||
|
||||
<div class="theme-search-results-item">
|
||||
|
||||
<div class="row">
|
||||
|
||||
{{-- ایرلاین --}}
|
||||
<div class="col-md-2">
|
||||
<strong>
|
||||
{{ $flight->airline }}
|
||||
</strong>
|
||||
|
||||
<div>
|
||||
{{ $flight->flight_number }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
{{-- مبدا --}}
|
||||
<div class="col-md-2 text-center">
|
||||
|
||||
<strong>
|
||||
{{ $flight->origin }}
|
||||
</strong>
|
||||
|
||||
<div>
|
||||
{{ $flight->departure_time }}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
{{-- مسیر --}}
|
||||
<div class="col-md-2 text-center">
|
||||
|
||||
<span>
|
||||
→
|
||||
</span>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
{{-- مقصد --}}
|
||||
<div class="col-md-2 text-center">
|
||||
|
||||
<strong>
|
||||
{{ $flight->destination }}
|
||||
</strong>
|
||||
|
||||
<div>
|
||||
{{ $flight->arrival_time }}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
{{-- کلاس --}}
|
||||
<div class="col-md-2 text-center">
|
||||
|
||||
<div>
|
||||
کلاس:
|
||||
{{ $flight->flight_class }}
|
||||
</div>
|
||||
|
||||
<div>
|
||||
ظرفیت:
|
||||
{{ $flight->capacity }}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
{{-- قیمت --}}
|
||||
<div class="col-md-2 text-center">
|
||||
|
||||
<strong>
|
||||
{{ number_format($flight->price) }}
|
||||
</strong>
|
||||
|
||||
<div>
|
||||
تومان
|
||||
</div>
|
||||
|
||||
<button class="btn btn-primary">
|
||||
انتخاب پرواز
|
||||
</button>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@empty
|
||||
|
||||
<div class="text-center">
|
||||
|
||||
<h3>
|
||||
پروازی پیدا نشد
|
||||
</h3>
|
||||
|
||||
<p>
|
||||
لطفاً مبدا، مقصد یا تاریخ دیگری را امتحان کنید.
|
||||
</p>
|
||||
|
||||
</div>
|
||||
|
||||
@endforelse
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@endsection
|
||||
|
||||
@@ -0,0 +1,72 @@
|
||||
<section class="flight-detail-page">
|
||||
<div class="container">
|
||||
|
||||
<div class="flight-detail-card">
|
||||
|
||||
<div class="flight-detail-image">
|
||||
<img src="{{ asset($flight->image) }}"
|
||||
alt="{{ $flight->airline }}">
|
||||
</div>
|
||||
|
||||
<div class="flight-detail-content">
|
||||
|
||||
<div class="d-flex justify-content-between align-items-center mb-4">
|
||||
<h1>{{ $flight->airline }}</h1>
|
||||
|
||||
<span class="flight-badge-show">
|
||||
پرواز
|
||||
</span>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="route-box">
|
||||
|
||||
<div>
|
||||
<small>مبدا</small>
|
||||
<strong>{{ $flight->origin }}</strong>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="route-line">
|
||||
✈
|
||||
</div>
|
||||
|
||||
|
||||
<div>
|
||||
<small>مقصد</small>
|
||||
<strong>{{ $flight->destination }}</strong>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flight-info-grid">
|
||||
|
||||
<div>
|
||||
<span>کلاس پرواز</span>
|
||||
<b>{{ $flight->flight_class }}</b>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<span>ظرفیت</span>
|
||||
<b>{{ $flight->capacity }} نفر</b>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<span>تاریخ حرکت</span>
|
||||
<b>{{ $flight->departure_date }}</b>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<span>قیمت</span>
|
||||
<b>{{ number_format($flight->price) }} تومان</b>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</section>
|
||||
@@ -1,8 +1,36 @@
|
||||
@extends('layouts.app')
|
||||
|
||||
@section('content')
|
||||
<section class="container mt-5">
|
||||
<h3 class="fw-bold mb-4">آخرین پروازها و تورها</h3>
|
||||
|
||||
@include('components.flight')
|
||||
@include('components.tour')
|
||||
<div class="swiper LatestProducts w-100">
|
||||
<div class="swiper-wrapper py-3">
|
||||
@forelse($newestFlight as $flight)
|
||||
@include('components.flight')
|
||||
@empty
|
||||
<p class="text-secondary">هنوز پروازی ثبت نشده است.</p>
|
||||
@endforelse
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
<section class="container my-5">
|
||||
<h3 class="fw-bold mb-4">همه پروازها و تورها</h3>
|
||||
|
||||
<div class="row g-4">
|
||||
@forelse($flights as $flight)
|
||||
<div class="col-md-4">
|
||||
@include('components.flight')
|
||||
</div>
|
||||
@empty
|
||||
<p class="text-secondary">چیزی برای نمایش وجود ندارد.</p>
|
||||
@endforelse
|
||||
</div>
|
||||
|
||||
<div class="mt-4">
|
||||
{{ $flights->links() }}
|
||||
</div>
|
||||
</section>
|
||||
|
||||
@endsection
|
||||
|
||||
@@ -3,14 +3,15 @@
|
||||
|
||||
<!-- index.html 07:26:20 -->
|
||||
<head>
|
||||
<title>airline_agency</title>
|
||||
<title>@yield('title', 'سامانه آژانس هواپیمایی')</title>
|
||||
<meta charset="UTF-8"/>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<link rel="stylesheet" href="{{asset('assets/css/font-awesome.css')}}"/>
|
||||
<link rel="stylesheet" href="{{asset('assets/css/lineicons.css')}}"/>
|
||||
<link rel="stylesheet" href="{{asset('assets/css/weather-icons.css')}}"/>
|
||||
<link rel="stylesheet" href="{{asset('assets/css/bootstrap.css')}}"/>
|
||||
<link rel="stylesheet" href="{{asset('assets/css/styles.css')}}"/>
|
||||
<link rel="stylesheet" href="{{ asset('assets/css/styles.css?v=2') }}">
|
||||
<link rel="stylesheet" href="{{ asset('assets/css/styles2.css?v=2') }}">
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
</div>
|
||||
|
||||
|
||||
<form action="{{ route('flights.search') }}" method="GET">
|
||||
<form action="{{ route('users.favorite.index') }}" method="GET">
|
||||
|
||||
|
||||
<div class="flight-fields">
|
||||
|
||||
@@ -0,0 +1,74 @@
|
||||
@foreach($tours as $tour)
|
||||
<!-- TOUR ITEM -->
|
||||
<div class="swiper-slide tour-card group">
|
||||
|
||||
<!-- tour image -->
|
||||
<a href="#">
|
||||
|
||||
<img
|
||||
class="tour-card_img"
|
||||
src="{{ $tour->image ?? asset('assets/img/placeholder.jpg') }}"
|
||||
alt="{{ $tour->title }}"
|
||||
>
|
||||
|
||||
</a>
|
||||
|
||||
<!-- tour content -->
|
||||
<div class="tour-card_content">
|
||||
|
||||
<!-- title -->
|
||||
<a href="#" class="tour-card_title">
|
||||
{{ $tour->title }}
|
||||
</a>
|
||||
|
||||
<!-- destination -->
|
||||
<div class="tour-card_destination">
|
||||
|
||||
<span>
|
||||
📍
|
||||
</span>
|
||||
|
||||
{{ $tour->destination }}
|
||||
|
||||
</div>
|
||||
|
||||
<!-- details -->
|
||||
<div class="tour-card_details">
|
||||
|
||||
<div>
|
||||
<span>مدت تور</span>
|
||||
|
||||
<strong>
|
||||
{{ $tour->duration }} روز
|
||||
</strong>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<span>ظرفیت</span>
|
||||
|
||||
<strong>
|
||||
{{ $tour->capacity }} نفر
|
||||
</strong>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- price -->
|
||||
<div class="tour-card_price">
|
||||
|
||||
<span>
|
||||
شروع قیمت از
|
||||
</span>
|
||||
|
||||
<strong>
|
||||
{{ number_format($tour->price) }}
|
||||
<small>تومان</small>
|
||||
</strong>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
@endforeach
|
||||
@@ -0,0 +1,3 @@
|
||||
<div>
|
||||
<!-- Happiness is not something readymade. It comes from your own actions. - Dalai Lama -->
|
||||
</div>
|
||||
Reference in New Issue
Block a user