@extends('layouts.dashboard') @section('content')

Sales Working Projects | Status: {{ ucfirst($status ?? 'Working') }}

{{-- Summary --}}

Total Projects

{{ $projects->count() }}

Prediction Amount ({{ $monthName }})

${{ number_format($predictionAmount, 2) }}

Amount Received ({{ $monthName }})

${{ number_format($amountReceived, 2) }}

{{-- Filters --}}
{{-- Table --}}
@forelse($projects as $index => $project) @php $statusColors = [ 'complete' => 'bg-blue-200 text-blue-800', 'working' => 'bg-green-200 text-green-800', 'hold' => 'bg-yellow-200 text-yellow-800', 'paused' => 'bg-purple-200 text-purple-800', 'issues' => 'bg-red-200 text-red-800', 'temp hold' => 'bg-orange-200 text-orange-800', 'closed' => 'bg-gray-200 text-gray-800', ]; $statusKey = strtolower(trim($project->project_status ?? 'working')); $statusClass = $statusColors[$statusKey] ?? 'bg-gray-200 text-gray-800'; @endphp @empty @endforelse
# Name / URL Office Info Price / Received / Duration Action Date Client Type Category Status
{{ $index + 1 }} {{ $project->name_or_url }}
Dashboard
Sales: {{ optional($project->salesPerson)->name ?? '-' }}
PM: {{ optional($project->projectManager)->name ?? '-' }}
TL: {{ optional($project->teamLead)->name ?? '-' }}
Price: ${{ number_format($project->price ?? 0, 2) }}
Hours: {{ $project->estimated_hours ?? 'N/A' }}
@if($project->duration_days) Duration: {{ $project->duration_days }} day(s) @else Duration: N/A @endif
{{-- Update Status --}} Status {{-- Monthly Report --}} Report {{-- Payment Details --}} Payment {{-- View Project --}} View {{-- Edit Project --}} Edit
{{ $project->created_at->format('d M Y') }} {{ $project->client_type }} {{ optional($project->projectCategory)->name ?? '-' }}
{{ optional($project->projectSubCategory)->name ?? '-' }}
{{ ucfirst($statusKey) }}
No projects found.
@endsection