Dashboard
@if ($headOffice->id == '37')
-
@foreach ($tabs as $index => $tab)
@php
$reportCount = $savedReports->where('dashboard', $tab['id'])->count();
$graphCount = $savedGraphs->filter(function ($graph) use ($tab) {
$sections = $graph->dashboard_section;
return is_array($sections) && in_array($tab['id'], $sections);
})->count();
@endphp
@if ($reportCount > 0 || $graphCount > 0)
- {{ $tab['label'] }} @endif @endforeach
{{ $section }}
@include('head_office.reports', [ 'reports' => $savedReports, 'dashboard' => 'patient_safety_incidents', 'section' => $section, ]) @endforeach
@php
$sections = $savedReports
->where('dashboard', 'controlled_drug_management')
->pluck('section')
->unique();
@endphp
@foreach ($sections as $section)
{{ $section }}
@include('head_office.reports', [ 'reports' => $savedReports, 'dashboard' => 'controlled_drug_management', 'section' => $section, ]) @endforeach
@php
$sections = $savedReports
->where('dashboard', 'central_fulfillment')
->pluck('section')
->unique();
@endphp
@foreach ($sections as $section)
{{ $section }}
@include('head_office.reports', [ 'reports' => $savedReports, 'dashboard' => 'central_fulfillment', 'section' => $section, ]) @endforeach
@php
$sections = $savedReports
->where('dashboard', 'freedom_to_speak_up')
->pluck('section')
->unique();
@endphp
@foreach ($sections as $section)
{{ $section }}
@include('head_office.reports', [ 'reports' => $savedReports, 'dashboard' => 'freedom_to_speak_up', 'section' => $section, ]) @endforeach
@php
$sections = $savedReports
->where('dashboard', 'pharmacy_premises_inspection')
->pluck('section')
->unique();
@endphp
@foreach ($sections as $section)
{{ $section }}
@include('head_office.reports', [ 'reports' => $savedReports, 'dashboard' => 'pharmacy_premises_inspection', 'section' => $section, ]) @endforeach
@php
$sections = $savedReports
->where('dashboard', 'nhs_and_iG')
->pluck('section')
->unique();
@endphp
@foreach ($sections as $section)