@extends('layouts.app') @section('title', 'Company Documents') @section('breadcrumbs') @endsection @section('content')
{{-- Header --}}

Company Documents

Track licenses, registrations, and regulatory documents

@if(auth()->user()->role === 'company_admin') Add Document @endif
{{-- Stat Pills --}}
{{ $stats['valid'] }} Valid {{ $stats['expiring'] }} Expiring {{ $stats['expired'] }} Expired
{{-- Filters --}}
Clear
{{-- Documents Table --}}
@if($documents->count() > 0) @foreach($documents as $doc) @endforeach
Document Type Name / Number Issue Date Expiry Date Days Left Renewal Status Assigned To Actions
{{ $doc->document_type_label }} @if($doc->document_name)
{{ $doc->document_name }}
@endif @if($doc->document_number)
#{{ $doc->document_number }}
@endif @if(!$doc->document_name && !$doc->document_number) @endif
{{ $doc->issue_date?->format('d M Y') ?? '—' }} {{ $doc->expiry_date?->format('d M Y') ?? 'No expiry' }} @if($doc->expiry_date) @if($doc->days_until_expiry <= 0) Expired {{ abs($doc->days_until_expiry) }}d ago @else {{ $doc->days_until_expiry }} days @endif @else @endif @if(auth()->user()->role === 'company_admin')
@csrf @method('PATCH')
@else {{ $doc->renewal_status_label }} @endif
{{ $doc->assignedUser?->name ?? '—' }}
@if($doc->file_path) @endif @if(auth()->user()->role === 'company_admin') @endif
@else

No documents found

Start tracking company documents by adding your first one.

@if(auth()->user()->role === 'company_admin') Add Document @endif
@endif
@if($documents->hasPages())
{{ $documents->appends(request()->query())->links() }}
@endif
{{-- Delete Confirmation Modal --}}
@endsection