Maintenance History

Room {{ $room->room_number }}

{{ $room->roomType->name ?? 'No Type' }} • Floor {{ $room->floor }}

{{ ucfirst($room->status) }} @if($room->has_active_maintenance) Active Maintenance @endif
Total Requests
{{ $maintenances->total() }}
Active Requests
{{ $room->activeMaintenanceRequests->count() }}
Completed
@php $completedCount = $room->maintenanceRequests->where('status', 'completed')->count(); @endphp {{ $completedCount }}
Repair Requests
@php $repairCount = $room->maintenanceRequests->where('maintenance_type', 'repair')->count(); @endphp {{ $repairCount }}
Maintenance History {{ $maintenances->total() }}
@if($maintenances->count() > 0)
@foreach($maintenances as $maintenance) @endforeach
ID Title Type Priority Status Reported Date Scheduled Date Completed Date Assigned To Actions
#{{ $maintenance->id }} {{ $maintenance->title }} {{ $maintenance->maintenance_type }} @if($maintenance->maintenance_type === 'repair') Repair @endif {{ ucfirst($maintenance->priority) }} {{ ucfirst(str_replace('_', ' ', $maintenance->status)) }} {{ $maintenance->reported_date->format('M j, Y') }} @if($maintenance->scheduled_date) {{ $maintenance->scheduled_date->format('M j, Y') }} @else Not scheduled @endif @if($maintenance->completed_date) {{ $maintenance->completed_date->format('M j, Y') }} @else - @endif {{ $maintenance->assignedTechnician?->name ?? 'Not Assigned' }}
Showing {{ $maintenances->firstItem() }} to {{ $maintenances->lastItem() }} of {{ $maintenances->total() }} maintenance requests
{{ $maintenances->links() }}
@else

No maintenance history found

This room has no maintenance requests yet.

Create First Request
@endif