@extends('layouts.dashboard') @section('title', 'Visit Management') @section('content')
Schedule, track, and manage field visits
Scheduled
{{ \App\Models\Visit::where('status', 'scheduled')->count() }}
In Progress
{{ \App\Models\Visit::where('status', 'in_progress')->count() }}
Completed
{{ \App\Models\Visit::where('status', 'completed')->count() }}
Cancelled
{{ \App\Models\Visit::where('status', 'cancelled')->count() }}
|
Date & Time
|
Client
|
Employee
|
Location
|
Status
|
Actions
|
|---|---|---|---|---|---|
|
{{ $visit->scheduled_date->format('M d, Y') }}
{{ $visit->scheduled_time }}
@if($visit->started_at)
Started: {{ $visit->started_at->format('h:i A') }}
@endif
@if($visit->completed_at)
Completed: {{ $visit->completed_at->format('h:i A') }}
@endif
|
{{ $visit->client->name }}
{{ $visit->client->phone }}
|
{{ $visit->employee->name }}
{{ $visit->employee->employee_id }}
|
{{ $visit->area }}, {{ $visit->city->name }}
{{ $visit->governorate->name }}
@if($visit->latitude && $visit->longitude)
GPS Enabled
@endif
|
@php $statusColors = [ 'scheduled' => 'bg-blue-100 text-blue-800', 'in_progress' => 'bg-amber-100 text-amber-800', 'completed' => 'bg-emerald-100 text-emerald-800', 'cancelled' => 'bg-red-100 text-red-800' ]; $statusIcons = [ 'scheduled' => 'fa-clock', 'in_progress' => 'fa-spinner', 'completed' => 'fa-check-circle', 'cancelled' => 'fa-times-circle' ]; @endphp {{ str_replace('_', ' ', ucfirst($visit->status)) }} | |
No Visits FoundYou haven't scheduled any visits yet. Get started by scheduling your first field visit. Schedule Your First Visit |
|||||