fix(admin): resolve issues on tour create page
This commit is contained in:
@@ -35,11 +35,11 @@
|
|||||||
<div class="col-xl-6">
|
<div class="col-xl-6">
|
||||||
<label class="form-label">عنوان تور <span class="text-danger">*</span></label>
|
<label class="form-label">عنوان تور <span class="text-danger">*</span></label>
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
class="form-control"
|
class="form-control"
|
||||||
name="title"
|
name="title"
|
||||||
placeholder="مثال: تور تفریحی استانبول ویژه نوروز"
|
placeholder="مثال: تور تفریحی استانبول ویژه نوروز"
|
||||||
value="{{ old('title') }}"
|
value="{{ old('title') }}"
|
||||||
/>
|
/>
|
||||||
@error('title')
|
@error('title')
|
||||||
<span class="text-danger small">{{ $message }}</span>
|
<span class="text-danger small">{{ $message }}</span>
|
||||||
@@ -53,7 +53,7 @@
|
|||||||
<option value="">یک مورد را انتخاب کنید</option>
|
<option value="">یک مورد را انتخاب کنید</option>
|
||||||
@foreach(\App\Enums\Tour\TourScope::cases() as $scope)
|
@foreach(\App\Enums\Tour\TourScope::cases() as $scope)
|
||||||
<option
|
<option
|
||||||
value="{{ $scope->value }}" {{ old('tour_scope') == $scope->value ? 'selected' : '' }}>
|
value="{{ $scope->value }}" {{ old('tour_scope') == $scope->value ? 'selected' : '' }}>
|
||||||
{{ method_exists($scope, 'label') ? $scope->label() : $scope->name }}
|
{{ method_exists($scope, 'label') ? $scope->label() : $scope->name }}
|
||||||
</option>
|
</option>
|
||||||
@endforeach
|
@endforeach
|
||||||
@@ -75,12 +75,12 @@
|
|||||||
|
|
||||||
<div class="col-xl-6">
|
<div class="col-xl-6">
|
||||||
<label class="form-label">نوع حمل و نقل / سفر <span
|
<label class="form-label">نوع حمل و نقل / سفر <span
|
||||||
class="text-danger">*</span></label>
|
class="text-danger">*</span></label>
|
||||||
<select class="form-control" name="tour_mode">
|
<select class="form-control" name="tour_mode">
|
||||||
<option value="">یک مورد را انتخاب کنید</option>
|
<option value="">یک مورد را انتخاب کنید</option>
|
||||||
@foreach(\App\Enums\Tour\TourMode::cases() as $mode)
|
@foreach(\App\Enums\Tour\TourMode::cases() as $mode)
|
||||||
<option
|
<option
|
||||||
value="{{ $mode->value }}" {{ old('tour_mode') == $mode->value ? 'selected' : '' }}>
|
value="{{ $mode->value }}" {{ old('tour_mode') == $mode->value ? 'selected' : '' }}>
|
||||||
{{ method_exists($mode, 'label') ? $mode->label() : $mode->name }}
|
{{ method_exists($mode, 'label') ? $mode->label() : $mode->name }}
|
||||||
</option>
|
</option>
|
||||||
@endforeach
|
@endforeach
|
||||||
@@ -95,9 +95,9 @@
|
|||||||
<label class="form-label">سبک تور <span class="text-danger">*</span></label>
|
<label class="form-label">سبک تور <span class="text-danger">*</span></label>
|
||||||
<select class="form-control" name="tour_type">
|
<select class="form-control" name="tour_type">
|
||||||
<option value="">یک مورد را انتخاب کنید</option>
|
<option value="">یک مورد را انتخاب کنید</option>
|
||||||
@foreach(\App\Enums\Flight\TourType::cases() as $type)
|
@foreach(\App\Enums\Tour\TourType::cases() as $type)
|
||||||
<option
|
<option
|
||||||
value="{{ $type->value }}" {{ old('tour_type') == $type->value ? 'selected' : '' }}>
|
value="{{ $type->value }}" {{ old('tour_type') == $type->value ? 'selected' : '' }}>
|
||||||
{{ method_exists($type, 'label') ? $type->label() : $type->name }}
|
{{ method_exists($type, 'label') ? $type->label() : $type->name }}
|
||||||
</option>
|
</option>
|
||||||
@endforeach
|
@endforeach
|
||||||
@@ -114,7 +114,7 @@
|
|||||||
<option value="">شهر مبدا را انتخاب کنید</option>
|
<option value="">شهر مبدا را انتخاب کنید</option>
|
||||||
@foreach($cities as $city)
|
@foreach($cities as $city)
|
||||||
<option
|
<option
|
||||||
value="{{ $city->id }}" {{ old('origin_city_id') == $city->id ? 'selected' : '' }}>
|
value="{{ $city->id }}" {{ old('origin_city_id') == $city->id ? 'selected' : '' }}>
|
||||||
{{ $city->name }}
|
{{ $city->name }}
|
||||||
</option>
|
</option>
|
||||||
@endforeach
|
@endforeach
|
||||||
@@ -131,7 +131,7 @@
|
|||||||
<option value="">شهر مقصد را انتخاب کنید</option>
|
<option value="">شهر مقصد را انتخاب کنید</option>
|
||||||
@foreach($cities as $city)
|
@foreach($cities as $city)
|
||||||
<option
|
<option
|
||||||
value="{{ $city->id }}" {{ old('destination_city_id') == $city->id ? 'selected' : '' }}>
|
value="{{ $city->id }}" {{ old('destination_city_id') == $city->id ? 'selected' : '' }}>
|
||||||
{{ $city->name }}
|
{{ $city->name }}
|
||||||
</option>
|
</option>
|
||||||
@endforeach
|
@endforeach
|
||||||
@@ -206,26 +206,26 @@
|
|||||||
<hr class="my-4">
|
<hr class="my-4">
|
||||||
<h6 class="fw-bold mb-2">گالری تصاویر تور</h6>
|
<h6 class="fw-bold mb-2">گالری تصاویر تور</h6>
|
||||||
<div
|
<div
|
||||||
class="image-upload-wrapper d-flex flex-wrap gap-2 px-0 pt-0 mt-2"
|
class="image-upload-wrapper d-flex flex-wrap gap-2 px-0 pt-0 mt-2"
|
||||||
id="imagePreviewContainer"
|
id="imagePreviewContainer"
|
||||||
style="border-radius: 8px; padding: 10px;"
|
style="border-radius: 8px; padding: 10px;"
|
||||||
>
|
>
|
||||||
<label
|
<label
|
||||||
id="uploadPlaceholder"
|
id="uploadPlaceholder"
|
||||||
class="upload-placeholder"
|
class="upload-placeholder"
|
||||||
for="imageInput"
|
for="imageInput"
|
||||||
style="cursor: pointer; width:150px; height:150px; display: flex; justify-content: center; align-items: center; border: 2px dashed #ccc; border-radius: 8px; padding: 20px; text-align: center;"
|
style="cursor: pointer; width:150px; height:150px; display: flex; justify-content: center; align-items: center; border: 2px dashed #ccc; border-radius: 8px; padding: 20px; text-align: center;"
|
||||||
>
|
>
|
||||||
<div>📷<br><strong>آپلود تصاویر</strong></div>
|
<div>📷<br><strong>آپلود تصاویر</strong></div>
|
||||||
<small style="color:#999;">JPG / PNG / WEBP</small>
|
<small style="color:#999;">JPG / PNG / WEBP</small>
|
||||||
</label>
|
</label>
|
||||||
<input
|
<input
|
||||||
id="imageInput"
|
id="imageInput"
|
||||||
name="images[]"
|
name="images[]"
|
||||||
type="file"
|
type="file"
|
||||||
accept=".jpg,.png,.jpeg,.webp"
|
accept=".jpg,.png,.jpeg,.webp"
|
||||||
multiple
|
multiple
|
||||||
style="display:none"
|
style="display:none"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
@error('images')
|
@error('images')
|
||||||
|
|||||||
Reference in New Issue
Block a user