@extends('layouts.front') @push('css') @endpush @section('content')

{{ $data->name ?? '' }}

@if ($data->rooms && count($data->rooms)) @php $bedRents = []; $roomRents = []; foreach ($data->rooms as $room) { $type = strtolower(trim($room->type)); if ($type === 'private room') { $roomRents[] = $room->rent; } else { $bedRents[] = $room->rent; } } $minBed = count($bedRents) ? min($bedRents) : null; $maxBed = count($bedRents) ? max($bedRents) : null; $minRoom = count($roomRents) ? min($roomRents) : null; $maxRoom = count($roomRents) ? max($roomRents) : null; @endphp
@if ($minBed) ₹{{ number_format($minBed) }} @if ($minBed != $maxBed) – ₹{{ number_format($maxBed) }} @endif /bed @endif @if ($minBed && $minRoom) — @endif @if ($minRoom) ₹{{ number_format($minRoom) }} @if ($minRoom != $maxRoom) – ₹{{ number_format($maxRoom) }} @endif /room @endif
@lang('For PG') @endif

{{ $data->locality }}, {{ $data->location->name ?? '' }}

@lang('PG Details')

@if ($data->total_beds)

{{ __('Total Beds : ') }} {{ $data->total_beds }}

@endif @if ($data->pg_for) @php $pgForList = explode(',', $data->pg_for); @endphp

{{ __('PG is for : ') }}

@foreach ($pgForList as $item) {{ ucwords(trim($item)) }} @endforeach
@endif @if ($data->suited_for) @php $suitedForList = explode(',', $data->suited_for); @endphp

{{ __('Best suited for : ') }}

@foreach ($suitedForList as $item) {{ ucwords(trim($item)) }} @endforeach
@endif @if ($data->meals_available)

{{ __('Meals Available: ') }} {{ ucwords($data->meals_available) }}

@endif @if ($data->meal_offerings) @php $mealOfferingsList = explode(',', $data->meal_offerings); @endphp

{{ __('Meal Offerings : ') }}

@foreach ($mealOfferingsList as $item) {{ ucwords(trim($item)) }} @endforeach
@endif @if ($data->meal_speciality) @php $mealSpecialityList = explode(',', $data->meal_speciality); @endphp

{{ __('Meal Speciality : ') }}

@foreach ($mealSpecialityList as $item) {{ ucwords(trim($item)) }} @endforeach
@endif @if ($data->notice_period)

{{ __('Notice Period (Days) : ') }} {{ $data->notice_period }}

@endif @if ($data->lock_in_period)

{{ __('Lock in Period (Days) : ') }} {{ $data->lock_in_period }}

@endif @if ($data->common_areas) @php $commonAreasList = explode(',', $data->common_areas); $commonAreasFormatted = collect($commonAreasList) ->map(fn($item) => ucwords(str_replace('_', ' ', trim($item)))) ->implode(', '); @endphp

{{ __('Common Areas : ') }}

@foreach (explode(',', $commonAreasFormatted) as $area) {{ trim($area) }} @endforeach
@endif
{{-- caretacker details --}}

@lang('Owner/Caretaker Details')

{{ __('Property Managed By : ') }} {{ ucwords(str_replace('_', ' ', trim($data->caretaker))) }}

{{ __('Property Manager stays at Property : ') }} {{ ucwords($data->is_manager_stays ?? '') }}

{{-- pg rules --}}

@lang('PG Rules')

{{ __('Non-Veg Allowed : ') }} {{ ucwords($data->veg_allowed ?? '') }}

{{ __('Opposit Sex Allowed : ') }} {{ ucwords($data->opposit_sex_allowed ?? '') }}

{{ __('Any Time Allowed : ') }} {{ ucwords($data->any_time_allowed ?? '') }}

@if ($data->any_time_allowed === 'no' && $data->last_entry_time)

{{ __('Last Time Entry : ') }} {{ $data->last_entry_time }}

@endif

{{ __('Visitors Allowed : ') }} {{ ucwords($data->visitors_allowed ?? '') }}

{{ __('Guardians Allowed : ') }} {{ ucwords($data->guardians_allowed ?? '') }}

{{ __('Drinking Allowed : ') }} {{ ucwords($data->drinking_allowed ?? '') }}

{{ __('Smoking Allowed : ') }} {{ ucwords($data->smoking_allowed ?? '') }}

{{-- rooms details --}}

@lang('Rooms Details')

@foreach ($data->rooms as $room)
@php $icon = ''; $type = strtolower(trim($room->type)); if ($type === 'private room') { $icon = ''; } elseif ($type === 'double sharing') { $icon = ''; } elseif ($type === 'triple sharing' || $type === '3+ sharing') { $icon = ''; } else { $icon = ''; } @endphp {!! $icon !!}{{ $room->type }}
Beds: {{ $room->total_beds }}
Rent: ₹{{ number_format($room->rent) }}
@if (!empty($room->deposit))
Security Deposit: ₹{{ number_format($room->deposit) }}
@endif @if (!empty($room->facilities)) @php // Decode JSON if it's a JSON string $facilities = $room->facilities; if (is_string($facilities)) { $decoded = json_decode($facilities, true); $facilities = is_array($decoded) ? $decoded : explode(',', $facilities); } @endphp @if (!empty($facilities) && is_array($facilities))
Facilities:

@foreach ($facilities as $facility)

{{ ucwords(str_replace('_', ' ', trim($facility))) }}

@endforeach

@endif @endif
@endforeach
@if ($data->attributes) @foreach ($attribute_name = json_decode($data->attributes, true) as $key => $attributes)

{{ $key }}

@foreach ($attributes as $key => $id)

{{ DB::table('attribute_options')->where('id', $id)->first()->name }}

@endforeach
@endforeach @endif {{-- Other Details --}}

@lang('Other Details')

{{ __('One Time Move in Charges (Rs) :') }} {{ $data->move_charges ? $data->move_charges : 'N/A' }}

{{ __('Meal Charges Per Month (Rs) :') }} {{ $data->meal_charges ? $data->meal_charges : 'N/A' }}

{{ __('Electricity Charges Per Month (Rs) :') }} {{ $data->electricity_charges ? $data->electricity_charges : 'N/A' }}

{{ __('Additional Information (Rs) :') }} {{ $data->additional_info ? $data->additional_info : 'N/A' }}

{{ count($reviews) }} @lang('Reviews')

    @foreach ($reviews as $key => $review)
  • {{ $review->user->name }}

    {{ $review->created_at->format('d M Y') }}

    {{ $review->message }}

  • @endforeach

@lang('Write A Review')

@csrf
@csrf
Contact Seller
Property Image {{ $data->user->name }}
 {{ $data->user->user_type == 'Agent' ? 'Seller' : $data->user->user_type }}
+91-{{ substr($data->user->phone, 0, 4) }}-XXX-XXX
@if (auth()->check())

Hi {{ auth()->user()->name }}!

@endif @if ($data->isContacted) @endif {{-- @endif --}}

Please share your contact

@if ($data->admin) @else @endif

@includeIf('partials.front.cta') @endsection @push('js') @endpush