@extends('theme.default.layouts.app')
@section('dashboard-title')
Reports
@endsection
@section('content')
@php
$reports = collect($reports ?? []);
@endphp
| Report Name |
Category |
Date |
Actions |
@forelse ($reports as $report)
@php
$reportMonth = filled($report->report_date ?? null)
? \Carbon\Carbon::parse($report->report_date)->format('Y-m')
: (filled($report->date ?? null)
? \Carbon\Carbon::parse($report->date)->format('Y-m')
: '');
@endphp
| {{ $report->name }} |
{{ $report->category }} |
{{ $report->date ? \Carbon\Carbon::parse($report->date)->format('M, Y') : '-' }}
|
Download
|
@empty
|
No reports found
|
@endforelse
@endsection
@section('scripts')
@php
$hotFile = public_path('hot');
$hotUrl = file_exists($hotFile) ? trim((string) file_get_contents($hotFile)) : null;
$hotHost = $hotUrl ? parse_url($hotUrl, PHP_URL_HOST) : null;
$requestHost = request()->getHost();
$useDevServer = $hotHost && $requestHost && strcasecmp($hotHost, $requestHost) === 0;
@endphp
@if($useDevServer)
@vite(['resources/views/theme/default/assets/js/pages/report.js'], 'build/themes/default')
@else
@endif
@endsection