{{-- resources/views/admin/monitoring/trips/index.blade.php --}} @extends('admin.layouts.app') @section('title', 'Trips Management') @section('page-title', 'Trips Management') @section('page-description', 'Monitor and manage user-created trips, templates, and destinations.') @section('content')

Total Trips

{{ $trips->total() }}

Active Trips

{{ $trips->where('status', 'active')->count() }}

Flagged Trips

{{ $trips->where('admin_status', 'flagged')->count() }}

Featured Trips

{{ $trips->where('is_featured', true)->count() }}

User Trips Monitor

Monitoring user-created trips
@if($trips->count() > 0)
@foreach($trips as $trip) @endforeach
Trip Creator Destination Dates Status Budget Actions
{{ $trip->title }}
@if($trip->is_featured) Featured @endif @if($trip->trip_template_id) Template @endif
@if($trip->description)
{{ Str::limit($trip->description, 50) }}
@endif
{{ $trip->creator->name }}
{{ $trip->creator->email }}
{{ $trip->destination }}
{{ $trip->start_date->format('M j') }} - {{ $trip->end_date->format('M j, Y') }}
{{ $trip->duration ?? $trip->start_date->diffInDays($trip->end_date) + 1 }} days
@php $statusColors = [ 'active' => 'bg-green-100 text-green-800', 'completed' => 'bg-blue-100 text-blue-800', 'cancelled' => 'bg-red-100 text-red-800', 'pending' => 'bg-yellow-100 text-yellow-800' ]; $adminStatusColors = [ 'approved' => 'bg-green-100 text-green-800', 'under_review' => 'bg-yellow-100 text-yellow-800', 'flagged' => 'bg-red-100 text-red-800', 'restricted' => 'bg-gray-100 text-gray-800' ]; @endphp {{ ucfirst($trip->status) }} {{ ucfirst(str_replace('_', ' ', $trip->admin_status)) }}
{{ $trip->budget ? '$' . number_format($trip->budget, 2) : 'N/A' }}
@csrf @method('PATCH')
@if($trip->trip_template_id) @endif
{{ $trips->withQueryString()->links() }}
@else

No trips found

@if(request()->hasAny(['search', 'status', 'admin_status', 'is_featured']))

Try adjusting your search criteria.

@else

Users haven't created any trips yet.

@endif
@endif
@endsection