246 lines
9.3 KiB
PHP
246 lines
9.3 KiB
PHP
@extends('dashboard.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>
|
|
|
|
<div class="user-profile-form">
|
|
|
|
<form action="{{ route('admin.tours.store') }}" method="POST">
|
|
|
|
@csrf
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-6">
|
|
<div class="form-group">
|
|
<label>عنوان تور</label>
|
|
|
|
<input type="text"
|
|
name="title"
|
|
class="form-control"
|
|
value="{{ old('title') }}"
|
|
placeholder="عنوان تور">
|
|
|
|
@error('title')
|
|
<span class="text-danger">{{ $message }}</span>
|
|
@enderror
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="col-md-6">
|
|
<div class="form-group">
|
|
<label>نوع تور</label>
|
|
|
|
<input type="text"
|
|
name="tour_type"
|
|
class="form-control"
|
|
value="{{ old('tour_type') }}"
|
|
placeholder="نوع تور">
|
|
|
|
@error('tour_type')
|
|
<span class="text-danger">{{ $message }}</span>
|
|
@enderror
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="col-md-6">
|
|
<div class="form-group">
|
|
<label>مبدأ</label>
|
|
|
|
<select name="origin_airports_id" class="form-control">
|
|
|
|
<option value="">
|
|
انتخاب مبدأ
|
|
</option>
|
|
|
|
@foreach($airports as $airport)
|
|
|
|
<option value="{{ $airport->id }}"
|
|
{{ old('origin_airports_id') == $airport->id ? 'selected' : '' }}>
|
|
{{ $airport->city }}
|
|
</option>
|
|
|
|
@endforeach
|
|
|
|
</select>
|
|
|
|
@error('origin_airports_id')
|
|
<span class="text-danger">{{ $message }}</span>
|
|
@enderror
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="col-md-6">
|
|
<div class="form-group">
|
|
<label>مقصد</label>
|
|
|
|
<select name="destination_airports_id" class="form-control">
|
|
|
|
<option value="">
|
|
انتخاب مقصد
|
|
</option>
|
|
|
|
@foreach($airports as $airport)
|
|
|
|
<option value="{{ $airport->id }}"
|
|
{{ old('destination_airports_id') == $airport->id ? 'selected' : '' }}>
|
|
{{ $airport->city }}
|
|
</option>
|
|
|
|
@endforeach
|
|
|
|
</select>
|
|
|
|
@error('destination_airports_id')
|
|
<span class="text-danger">{{ $message }}</span>
|
|
@enderror
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="col-md-6">
|
|
<div class="form-group">
|
|
|
|
<label>تاریخ حرکت</label>
|
|
|
|
<input type="text"
|
|
name="start_date"
|
|
id="start_date"
|
|
class="form-control"
|
|
value="{{ old('start_date') }}"
|
|
placeholder="تاریخ حرکت">
|
|
|
|
@error('start_date')
|
|
<span class="text-danger">{{ $message }}</span>
|
|
@enderror
|
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="col-md-6">
|
|
<div class="form-group">
|
|
|
|
<label>تاریخ برگشت</label>
|
|
|
|
<input type="text"
|
|
name="end_date"
|
|
id="end_date"
|
|
class="form-control"
|
|
value="{{ old('end_date') }}"
|
|
placeholder="تاریخ برگشت">
|
|
|
|
@error('end_date')
|
|
<span class="text-danger">{{ $message }}</span>
|
|
@enderror
|
|
|
|
</div>
|
|
</div>
|
|
<div class="col-md-6">
|
|
<div class="form-group">
|
|
<label>قیمت</label>
|
|
<input type="number" name="price" class="form-control" value="{{old('price')}}" placeholder="قیمت">
|
|
@error('price')
|
|
<span class="text-danger">{{$message}}</span>
|
|
@enderror
|
|
</div>
|
|
</div>
|
|
|
|
<div class="col-md-6">
|
|
<div class="form-group">
|
|
<label>ظرفیت</label>
|
|
<input type="number" name="capacity" class="form-control" value="{{old('capacity')}}" placeholder="ظرفیت">
|
|
@error('capacity')
|
|
<span class="text-danger">{{$message}}</span>
|
|
@enderror
|
|
</div>
|
|
</div>
|
|
|
|
<div class="col-md-12">
|
|
<div class="form-group">
|
|
|
|
<label>خلاصه تور</label>
|
|
|
|
<textarea name="summary"
|
|
class="form-control"
|
|
rows="4"
|
|
placeholder="خلاصه تور">{{ old('summary') }}</textarea>
|
|
|
|
@error('summary')
|
|
<span class="text-danger">{{ $message }}</span>
|
|
@enderror
|
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<div class="col-md-12">
|
|
<div class="form-group">
|
|
|
|
<label>توضیحات تور</label>
|
|
|
|
<textarea name="description"
|
|
class="form-control"
|
|
rows="6"
|
|
placeholder="توضیحات تور">{{ old('description') }}</textarea>
|
|
|
|
@error('description')
|
|
<span class="text-danger">{{ $message }}</span>
|
|
@enderror
|
|
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<button type="submit" class="theme-btn mt-4">
|
|
ساخت تور
|
|
<i class="far fa-plus"></i>
|
|
</button>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
@endsection
|
|
|
|
@section('scripts')
|
|
|
|
<script>
|
|
$(document).ready(function () {
|
|
|
|
$('#start_date').persianDatepicker({
|
|
format: 'YYYY/MM/DD',
|
|
autoClose: true
|
|
});
|
|
|
|
$('#end_date').persianDatepicker({
|
|
format: 'YYYY/MM/DD',
|
|
autoClose: true
|
|
});
|
|
|
|
});
|
|
</script>
|
|
|
|
@endsection
|