@extends('layouts.admin') @section('title', 'Resorts') @section('content') @php $canEdit = \App\Http\Controllers\Admin\ResortController::allowed('edit'); // A resort reaches the website only when it is active; without an active room type // it is listed but cannot be booked, so flag it for the team. $live = $items->where('is_active', true); $noRooms = $live->where('active_rooms_count', 0)->count(); @endphp
Your resorts and room inventory will appear here.
| Resort | Destination | Rooms | From / night | Source | Website | Actions |
|---|---|---|---|---|---|---|
|
@if($image)
{{ $item->name }}
@if($item->is_featured)@endif
/{{ $item->slug }}
|
{{ $item->destination?->name ?: '—' }} | @if($item->rooms_count) {{ $item->active_rooms_count }} / {{ $item->rooms_count }} active @else None @endif | {{ $item->starting_price !== null ? number_format((float) $item->starting_price, 2) : '—' }} |
{{-- Lowercased first: headline() spells an all-caps value out letter by letter ("O W N"). --}}
{{ Str::headline(strtolower($item->source_type)) }} · {{ Str::headline(strtolower($item->availability_mode)) }}
{{ $item->supplier?->name ?: Str::headline(strtolower($item->booking_mode)).' booking' }}
|
@if(! $item->is_active) Inactive @elseif($item->active_rooms_count === 0) Live · no rooms @else Live @endif | @if($canEdit) Edit Add Room @endif |