@php $rt = $roomTypeModel ?? null; $translationsByLang = $rt?->translations->keyBy('language_id') ?? collect(); $rtAiGroup = 'room-type-'.($rt?->id ?? 'new'); $rtAiContext = array_filter([ 'Hotel' => $hotel->name, 'Tipologia' => old('name', $rt?->name), 'Nº de quartos' => old('room_count', $rt?->room_count), ], fn ($v) => $v !== null && $v !== ''); @endphp

Identificação

Facilities de Quarto

@php $selected = old('facilities', $selectedFacilities); @endphp @if ($allFacilities->isEmpty())

Ainda não existem facilities de quarto configuradas. Criar em CONFIG > Facilities de Quarto.

@else @foreach ($allFacilities->groupBy(fn ($f) => $f->category ?: 'Outras') as $category => $items)
{{ $category }}
@foreach ($items as $f) @endforeach
@endforeach @endif

Descrições por idioma

@foreach ($languages as $l) {{ $l->name }} @endforeach
@foreach ($languages as $i => $l) @php $t = $translationsByLang->get($l->id); @endphp
@endforeach
@if ($rt?->exists) @include('admin.partials.photo-gallery', [ 'model' => $rt, 'max' => \App\Models\RoomType::MAX_PHOTOS, 'routeParams' => [$hotel, $rt], 'routePrefix' => 'admin.hotels.room-types.photos', ]) @endif
Cancelar