@php function getFormattedDateRange($checkinDate, $checkoutDate) { if ($checkinDate && $checkoutDate) { $checkIn = \Carbon\Carbon::parse($checkinDate); $checkOut = \Carbon\Carbon::parse($checkoutDate); if ($checkIn->format('j M Y') === $checkOut->format('j M Y')) { return $checkIn->format('j M'); } elseif ($checkIn->format('M') === $checkOut->format('M')) { return $checkIn->format('j') . ' to ' . $checkOut->format('j M'); } else { return $checkIn->format('j M') . ' to ' . $checkOut->format('j M'); } } elseif ($checkinDate) { return \Carbon\Carbon::parse($checkinDate)->format('j M'); } elseif ($checkoutDate) { return \Carbon\Carbon::parse($checkoutDate)->format('j M'); } return null; } @endphp
{{ $offerData['location'] }}
{{--
{{ $offerData['location'] }}
--}}
@foreach ($offerData['rooms'] as $index => $room) @endforeach @if ($offerData['show_grand_total']) {{-- --}} @endif
S.No. Hotel Room Categories Check In/ Out
Date
Total Rates
per room
{{ $index + 1 }} {{ $room['hotel'] }}
    @foreach ($room['categories'] as $category)
  • {{ $category }}
  • @endforeach
    @foreach ($room['checkin_dates'] as $key => $checkin) @php $checkout = $room['checkout_dates'][$key] ?? null; $dateRange = getFormattedDateRange($checkin, $checkout); @endphp @if ($dateRange)
  • {{ $dateRange }}
  • @else
  •  
  • @endif @endforeach
    @foreach ($room['total_rates'] as $rate)
  • @if ($rate > 0) {{ $offerData['currency'] }} {!! formatPrice($rate) !!} @else   @endif
  • @endforeach
Grand Total:
{{ $offerData['currency'] }} {!! formatPrice($offerData['grand_total']) !!}
{{ $offerData['grand_total_sub_text'] ?? '' }}
Grand Total:    {{ $offerData['currency'] }} {!! formatPrice($offerData['grand_total']) !!}
{{ $offerData['grand_total_sub_text'] ?? '' }}
@if (!empty($offerData['sections'])) @foreach ($offerData['sections'] as $section) @php $title = htmlspecialchars($section['title']); $description = $section['description']; // already HTML, don't encode it @endphp

{{ $title }}

{!! $description !!}
@endforeach @endif @if (!empty($offerData['general_conditions']))

General Sales Conditions

{!! $offerData['general_conditions'] !!}
@endif