Files
airline-agency/storage/framework/views/f883686e3d10fd2912a8d6fc8c97bffb.php
T

181 lines
11 KiB
PHP

<?php $__env->startSection('title' , 'علاقه مندی های من'); ?>
<?php $__env->startSection('account-content'); ?>
<div class="user-profile-wrapper">
<?php if(session('success')): ?>
<div class="col-lg-12 mb-3">
<div class="alert alert-success">
<?php echo e(session('success')); ?>
</div>
</div>
<?php endif; ?>
<?php if(session('error')): ?>
<div class="col-lg-12 mb-3">
<div class="alert alert-danger">
<?php echo e(session('error')); ?>
</div>
</div>
<?php endif; ?>
<div class="col-lg-12">
<div class="user-profile-card">
<div class="d-flex justify-content-between align-items-center mb-4">
<h4 class="user-profile-card-title mb-0">
<i class="far fa-heart text-danger me-1"></i>
علاقه‌مندی‌های من
</h4>
<span class="badge bg-primary">
<?php echo e(method_exists($favorites, 'total') ? $favorites->total() : $favorites->count()); ?> مورد
</span>
</div>
<div class="row mt-30">
<?php $__empty_1 = true; $__currentLoopData = $favorites; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $favorite): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); $__empty_1 = false; ?>
<?php if($favorite->tour): ?>
<div class="col-md-6 col-lg-4 mb-4">
<div class="hotel-item h-100 d-flex flex-column justify-content-between">
<div class="hotel-img position-relative">
<span class="badge bg-info position-absolute top-0 start-0 m-2">تور</span>
<?php if($favorite->tour->coverImage?->file): ?>
<img src="<?php echo e(getFileUrl($tour->coverImage->file_id)); ?>"
class="w-100 h-100"
alt="<?php echo e($favorite->tour->title); ?>">
<?php else: ?>
<img src="<?php echo e(asset('assets/admin/images/faces/DefaultAvatar.jpg')); ?>"
class="w-100 h-100"
alt="<?php echo e($favorite->tour->title); ?>">
<?php endif; ?>
<form method="POST" action="<?php echo e(route('accounts.favorites.tour.toggle', $favorite->tour->id)); ?>" class="d-inline">
<?php echo csrf_field(); ?>
<button type="submit" class="add-wishlist border-0 bg-transparent" title="حذف از علاقه‌مندی">
<i class="fas fa-heart text-danger"></i>
</button>
</form>
</div>
<div class="hotel-content d-flex flex-column flex-grow-1 justify-content-between">
<div>
<h4 class="hotel-title">
<a href="<?php echo e(route('tours.show', $favorite->tour->id)); ?>">
<?php echo e($favorite->tour->title); ?>
</a>
</h4>
<p><i class="far fa-location-dot"></i>
<?php echo e($favorite->tour->originCity->name ?? 'مبدأ'); ?>
<i class="fas fa-arrow-right-long"></i>
<?php echo e($favorite->tour->city?->name ?? 'مقصد'); ?>
</p>
</div>
<div class="hotel-bottom mt-3">
<div class="hotel-price">
<span class="hotel-price-amount">
<?php echo e(number_format(optional($favorite->tour->tourDepartures->first())->price ?? 0)); ?> تومان
</span>
</div>
<div class="hotel-text-btn">
<a href="<?php echo e(route('tours.show', $favorite->tour->id)); ?>">
نمایش جزئیات <i class="fas fa-arrow-left"></i>
</a>
</div>
</div>
</div>
</div>
</div>
<?php elseif($favorite->flight): ?>
<div class="col-md-6 col-lg-4 mb-4">
<div class="hotel-item h-100 d-flex flex-column justify-content-between">
<div class="hotel-img position-relative">
<span class="badge bg-primary position-absolute top-0 start-0 m-2">پرواز</span>
<?php if($favorite->flight->coverImage?->file_id): ?>
<img src="<?php echo e(getFileUrl($favorite->flight->coverImage->file_id)); ?>"
class="w-100 h-100"
alt="<?php echo e($favorite->flight->flight_number); ?>">
<?php else: ?>
<img src="<?php echo e(asset('assets/img/account/user.jpg')); ?>"
class="w-100 h-100"
alt="<?php echo e($favorite->flight->title); ?>">
<?php endif; ?>
<form method="POST" action="<?php echo e(route('accounts.favorites.flight.toggle', $favorite->flight->id)); ?>" class="d-inline">
<?php echo csrf_field(); ?>
<button type="submit" class="add-wishlist border-0 bg-transparent" title="حذف از علاقه‌مندی">
<i class="fas fa-heart text-danger"></i>
</button>
</form>
</div>
<div class="hotel-content d-flex flex-column flex-grow-1 justify-content-between">
<div>
<h4 class="hotel-title">
<a href="<?php echo e(route('flights.show', $favorite->flight->id)); ?>">
<?php echo e($favorite->flight->origin_airport?->city?->name ?? 'مبدأ'); ?> به <?php echo e($favorite->flight->airport?->city?->name ?? 'مقصد'); ?>
</a>
</h4>
<p class="text-muted mb-1">
<i class="far fa-plane"></i>
<?php echo e($favorite->flight->airline?->name); ?> (شماره: <?php echo e($favorite->flight->flight_number); ?>)
</p>
<?php if($favorite->flight->departure_time): ?>
<p class="small text-muted mb-0">
<i class="far fa-calendar-alt"></i>
<?php echo e(\Hekmatinasser\Verta\Verta::instance($favorite->flight->departure_time)->format('Y/m/d - H:i')); ?>
</p>
<?php endif; ?>
</div>
<div class="hotel-bottom mt-3">
<div class="hotel-price">
<span class="hotel-price-amount">
<?php echo e(number_format($favorite->flight->price)); ?>
<span class="hotel-price-type">تومان</span>
</span>
</div>
<div class="hotel-text-btn">
<a href="<?php echo e(route('flights.show', $favorite->flight->id)); ?>">
نمایش جزئیات <i class="fas fa-arrow-left"></i>
</a>
</div>
</div>
</div>
</div>
</div>
<?php endif; ?>
<?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); if ($__empty_1): ?>
<div class="col-12 text-center py-5">
<i class="far fa-heart-broken fa-3x text-muted mb-3"></i>
<h5>هنوز موردی به علاقه‌مندی‌هایتان اضافه نکرده‌اید.</h5>
<p class="text-muted mb-0">
تورها و پروازهای مورد علاقه خود را ذخیره کنید تا در هر زمان به راحتی به آن‌ها دسترسی داشته باشید.
</p>
</div>
<?php endif; ?>
</div>
<?php if($favorites->hasPages()): ?>
<div class="pagination-area my-4">
<div class="d-flex justify-content-center">
<?php echo e($favorites->links()); ?>
</div>
</div>
<?php endif; ?>
</div>
</div>
</div>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('account.layouts.app', array_diff_key(get_defined_vars(), ['__data' => 1, '__path' => 1]))->render(); ?><?php /**PATH C:\Users\ASUS\Desktop\airline-agency\resources\views/account/favorite-list.blade.php ENDPATH**/ ?>