Logo {{-- Logo --}} {{--

A.H.K Arkitek Hanan

Perkhidmatan Arkitek: Perancangan, Rekabentuk Dalaman, Dan Landskap

--}}
Alamat:
19, Jalan Besi 1, Taman Sri Putri,
81300 Skudai, Johor Darul Ta'zim
Tel: 07-562 3417
{{-- Info block at the top of the table --}}
Date Generated: {{ now()->format('d M Y') }} @php $allRegistered = $projects->every(fn($p) => $p->is_registration); @endphp @if ($allRegistered) All Registered @endif   |   Project Type: @php $filteredType = null; if (request('project_type_id')) { $filteredType = $projects->firstWhere('project_type_id', request('project_type_id'))?->project_type?->name; } @endphp @if($filteredType) {{ $filteredType }} @else All Types @endif
{{-- --}} {{-- --}} {{-- --}} @foreach ($projects as $project) {{-- --}} {{-- --}} {{-- --}} @endforeach
No. DescriptionRef NoClient Scope Submission StatusRemarksStart Date End DateAssignee(s) Progress Year Received
{{ $loop->iteration }} {{--
--}} {{ $project->ref_no ?? '-' }} {{--
--}}
{{ $project->description }}
{{ $project->ref_no }}{{ $project->client }} {{ Str::title($project->scope->name ?? '-') }} @php $statuses = \App\Models\Status::all()->keyBy('id'); @endphp @forelse ($project->submissionTypes as $type)
{{ strtoupper($type->name) }}: @php $statusId = $type->pivot->status_id ?? null; $statusName = $statusId && isset($statuses[$statusId]) ? $statuses[$statusId]->name : 'Pending'; $submissionDate = $type->pivot->submission_date ? \Carbon\Carbon::parse($type->pivot->submission_date)->format('d M Y') : null; $fileNo = $type->pivot->file_no ?? null; @endphp @if($fileNo) {{ $fileNo }} @endif @if($submissionDate) {{ $submissionDate }} @endif ({{ $statusName }})
@empty
-
@endforelse
{{ $project->remarks ?? '-' }} {{ $project->start_date ? $project->start_date->format('d M Y') : '-' }} {{ $project->end_date ? $project->end_date->format('d M Y') : '-' }} @if ($project->assignees->isNotEmpty()) {{ $project->assignees->pluck('name')->join(', ') }} @else - @endif {{-- {{ $project->weighted_progress }}% --}}
@if ($project->weighted_progress == 100) {{ $project->weighted_progress }}% @elseif ($project->weighted_progress == 0) {{ $project->weighted_progress }}% @else {{ $project->weighted_progress }}% @endif

{{ $project->remarks ?? '' }}

{{ $project->received_year }}
{{--

Project List by Year

@php $groupedProjects = $projects->groupBy('received_year'); @endphp @foreach ($groupedProjects as $year => $items)

{{ $year }}

@foreach ($items as $project)
{{ $project->description }}
Client: {{ $project->client }}
Scope: {{ $project->scope->name ?? '-' }}
@endforeach @endforeach --}}