fix: update flight functionality

This commit is contained in:
2026-08-20 08:27:00 +03:30
parent f9dd90f1ac
commit 9b7934c0ba
2 changed files with 480 additions and 3 deletions
+273
View File
@@ -0,0 +1,273 @@
<div class="col-md-4 col-sm-6">
<div class="theme-search-results-item">
<div class="theme-search-results-item-header">
<div>
<strong>
{{ $flight->airline_name }}
</strong>
</div>
<div>
<strong>
{{ $flight->flight_number }}
</strong>
</div>
</div>
<div class="theme-search-results-item-body">
{{-- مسیر پرواز --}}
<div class="text-center">
<div>
<strong>
{{ $flight->origin }}
</strong>
<span>
→
</span>
<strong>
{{ $flight->destination }}
</strong>
</div>
</div>
<hr>
{{-- ساعت پرواز --}}
<div class="row">
<div class="col-xs-6 text-center">
<small>
حرکت
</small>
<div>
<strong>
{{ $flight->departure_time }}
</strong>
</div>
</div>
<div class="col-xs-6 text-center">
<small>
رسیدن
</small>
<div>
<strong>
{{ $flight->arrival_time }}
</strong>
</div>
</div>
</div>
<hr>
{{-- مدت --}}
<div class="text-center">
<small>
مدت پرواز
</small>
<div>
{{ $flight->duration }}
</div>
</div>
<hr>
{{-- قیمت --}}
<div class="text-center">
<small>
قیمت
</small>
<div>
<strong>
{{ number_format($flight->price) }}
</strong>
تومان
</div>
</div>
<div style="margin-top: 15px;">
<a
href="{{ route('flights.show', ['flight' => $flight->id]) }}"
class="btn btn-primary btn-block"
>
مشاهده جزئیات
</a>
</div>
</div>
</div>
</div>
{{--@extends('layouts.app')--}}
{{--@section('title', 'پروازها')--}}
{{--@section('content')--}}
{{-- <div class="theme-page-section theme-page-section-gray">--}}
{{-- <div class="container">--}}
{{-- <div class="theme-page-section-header">--}}
{{-- <h1 class="theme-page-section-title">--}}
{{-- پروازها--}}
{{-- </h1>--}}
{{-- <p>--}}
{{-- پرواز مورد نظر خود را انتخاب کنید.--}}
{{-- </p>--}}
{{-- </div>--}}
{{-- --}}{{-- Search --}}
{{-- <div class="theme-search-area theme-search-area-stacked theme-search-area-white">--}}
{{-- <div class="theme-search-area-form">--}}
{{-- <div class="row">--}}
{{-- <div class="col-md-3">--}}
{{-- <input--}}
{{-- class="form-control"--}}
{{-- type="text"--}}
{{-- placeholder="مبدا">--}}
{{-- </div>--}}
{{-- <div class="col-md-3">--}}
{{-- <input--}}
{{-- class="form-control"--}}
{{-- type="text"--}}
{{-- placeholder="مقصد">--}}
{{-- </div>--}}
{{-- <div class="col-md-2">--}}
{{-- <input--}}
{{-- class="form-control"--}}
{{-- type="text"--}}
{{-- placeholder="تاریخ">--}}
{{-- </div>--}}
{{-- <div class="col-md-2">--}}
{{-- <select class="form-control">--}}
{{-- <option>اقتصادی</option>--}}
{{-- <option>بیزینس</option>--}}
{{-- <option>فرست کلاس</option>--}}
{{-- </select>--}}
{{-- </div>--}}
{{-- <div class="col-md-2">--}}
{{-- <button class="btn btn-primary btn-block">--}}
{{-- جستجو--}}
{{-- </button>--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- --}}
{{-- --}}{{-- Flights --}}
{{-- <div class="row row-col-gap">--}}
{{-- @forelse($flights as $flight)--}}
{{-- @include('components.flight', [--}}
{{-- 'flight' => $flight--}}
{{-- ])--}}
{{-- @empty--}}
{{-- <div class="col-12">--}}
{{-- <div class="alert alert-info text-center">--}}
{{-- در حال حاضر پرواز فعالی برای نمایش وجود ندارد.--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- @endforelse--}}
{{-- </div>--}}
{{-- <div class="row row-col-gap">--}}
{{-- @include('components.flight', [--}}
{{-- 'airline' => 'ایران ایر',--}}
{{-- 'from' => 'تهران',--}}
{{-- 'to' => 'استانبول',--}}
{{-- 'departure' => '09:30',--}}
{{-- 'arrival' => '12:00',--}}
{{-- 'price' => '25,000,000'--}}
{{-- ])--}}
{{-- @include('components.flight', [--}}
{{-- 'airline' => 'ماهان',--}}
{{-- 'from' => 'تهران',--}}
{{-- 'to' => 'دبی',--}}
{{-- 'departure' => '14:00',--}}
{{-- 'arrival' => '17:00',--}}
{{-- 'price' => '18,500,000'--}}
{{-- ])--}}
{{-- @include('components.flight', [--}}
{{-- 'airline' => 'ترکیش ایرلاینز',--}}
{{-- 'from' => 'تهران',--}}
{{-- 'to' => 'استانبول',--}}
{{-- 'departure' => '20:30',--}}
{{-- 'arrival' => '23:30',--}}
{{-- 'price' => '22,000,000'--}}
{{-- ])--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- </div>--}}
{{--@endsection--}}
+207 -3
View File
@@ -1,3 +1,207 @@
<div>
<!-- Simplicity is an acquired taste. - Katharine Gerould -->
</div>
@extends('layouts.app')
@section('title', 'جزئیات پرواز')
@section('content')
<div class="theme-page-section theme-page-section-gray">
<div class="container">
<div class="theme-page-section-header">
<h1 class="theme-page-section-title">
جزئیات پرواز
</h1>
</div>
<div class="row">
<div class="col-md-8">
<div class="theme-search-results-item">
<div class="theme-search-results-item-preview">
<h3>
{{ $flight->origin }} → {{ $flight->destination }}
</h3>
<hr>
<p>
<strong>شماره پرواز:</strong> {{ $flight->flight_number }}
</p>
<p>
<strong>شرکت هواپیمایی:</strong> {{ $flight->airline_name }}
</p>
<p>
<strong>تاریخ حرکت:</strong> {{ $flight->departure_date }}
</p>
<p>
<strong>ساعت حرکت:</strong> {{ $flight->departure_time }}
</p>
<p>
<strong>تاریخ رسیدن:</strong> {{ $flight->arrival_date }}
</p>
<p>
<strong>ساعت رسیدن:</strong> {{ $flight->arrival_time }}
</p>
<p>
<strong>مدت پرواز:</strong> {{ $flight->duration }}
</p>
<p>
<strong>ظرفیت:</strong> {{ $flight->capacity }} نفر
</p>
</div>
</div>
</div>
<div class="col-md-4">
<div class="theme-search-results-item">
<div class="theme-search-results-item-preview">
<h4>قیمت بلیت</h4>
<h2>
{{ number_format($flight->price) }} تومان
</h2>
<a
href="{{ route('booking.flight', $flight) }}"
class="btn btn-primary"
>
رزرو پرواز
</a>
</div>
</div>
</div>
</div>
</div>
</div>
@endsection
{{--@extends('layouts.app')--}}
{{--@section('title', 'جزئیات پرواز')--}}
{{--@section('content')--}}
{{-- <div class="theme-page-section theme-page-section-gray">--}}
{{-- <div class="container">--}}
{{-- <div class="theme-page-section-header">--}}
{{-- <h1 class="theme-page-section-title">--}}
{{-- جزئیات پرواز--}}
{{-- </h1>--}}
{{-- </div>--}}
{{-- <div class="row">--}}
{{-- <div class="col-md-8">--}}
{{-- <div class="theme-search-results-item">--}}
{{-- <div class="theme-search-results-item-preview">--}}
{{-- <h3>--}}
{{-- تهران → استانبول--}}
{{-- </h3>--}}
{{-- <hr>--}}
{{-- <p>--}}
{{-- شرکت هواپیمایی: ایران ایر--}}
{{-- </p>--}}
{{-- <p>--}}
{{-- تاریخ: 1405/05/30--}}
{{-- </p>--}}
{{-- <p>--}}
{{-- ساعت حرکت: 09:30--}}
{{-- </p>--}}
{{-- <p>--}}
{{-- ساعت رسیدن: 12:00--}}
{{-- </p>--}}
{{-- <p>--}}
{{-- مدت پرواز: 3 ساعت و 30 دقیقه--}}
{{-- </p>--}}
{{-- <p>--}}
{{-- کلاس: اقتصادی--}}
{{-- </p>--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- <div class="col-md-4">--}}
{{-- <div class="theme-search-results-item">--}}
{{-- <div class="theme-search-results-item-preview">--}}
{{-- <h4>--}}
{{-- قیمت بلیت--}}
{{-- </h4>--}}
{{-- <h2>--}}
{{-- 25,000,000 تومان--}}
{{-- </h2>--}}
{{-- <a--}}
{{-- href="{{ route('booking.flight', $flight) }}"--}}
{{-- class="btn btn-primary"--}}
{{-- >--}}
{{-- رزرو پرواز--}}
{{-- </a>--}}
{{-- <button class="btn btn-primary btn-block">--}}
{{-- رزرو پرواز--}}
{{-- </button>--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- </div>--}}
{{-- </div>--}}
{{--@endsection--}}