{{ __('dashboard.heading', ['year' => $cycle->yearLabel()]) }}

{{ __('dashboard.intro') }}

@unless ($full) {{ __('dashboard.simplified_notice') }} {{ __('dashboard.see_offers') }} @endunless @if ($ambitious){{ __('dashboard.ambitious') }}@endif @if ($lighterPlan){{ __('dashboard.lighter') }}@endif {{-- Key figures (6.8) --}} @php $o = $data['objectives']; $a = $data['actions']; $r = $data['reviews']; $tiles = [ ['objectives_attained', $o['attained'].' / '.$o['active']], ['average_progress', App\Support\Percent::whole($o['average_progress']).' %'], ['actions_done', $a['done'].' / '.$a['total']], ['action_rate', App\Support\Percent::whole($a['rate']).' %'], ]; if ($full) { $tiles = array_merge($tiles, [ ['late_actions', (string) $a['late']], ['deadlines_respected', $a['deadlines_respected'].' / '.$a['done']], ['weekly_reviews', (string) $r['weekly_done']], ['priority_rate', App\Support\Percent::whole($r['average_priority_rate']).' %'], ['high_risks', (string) $data['risks']['high_open']], ]); } @endphp
@foreach ($tiles as [$key, $value])

{{ __('dashboard.'.$key) }}

{{ $value }}

@endforeach @if ($full) @php $f = $data['finance']; @endphp @foreach ([['outputs', App\Support\Money::format($f['outputs_actual']).' / '.App\Support\Money::format($f['outputs_planned'])], ['savings', App\Support\Money::format($f['savings'])], ['balance', App\Support\Money::format($f['balance'])]] as [$key, $value])

{{ __('dashboard.'.$key) }}

{{ $value }}

@endforeach @endif
{{-- This week's review --}}

{{ __('dashboard.review_title') }}

{{ $thisWeekReview?->completed_at ? __('dashboard.review_done') : __('dashboard.review_todo') }}

@if ($weeksBehind) {{ $thisWeekReview ? __('dashboard.review_open') : __('dashboard.review_go') }} @endif {{ __('dashboard.all_reviews') }}
{{-- Objectives --}}

{{ __('dashboard.objectives_title') }}

@forelse ($data['objective_rows'] as $row) @php $obj = $row['objective']; $variant = match ($row['status']) { \App\Enums\ObjectiveStatus::Achieved, \App\Enums\ObjectiveStatus::OnTrack => 'ok', \App\Enums\ObjectiveStatus::Watch => 'warn', \App\Enums\ObjectiveStatus::Late => 'bad', default => 'neutral' }; @endphp

{{ trim($obj->title) !== '' ? $obj->title : __('objectives.untitled') }}

{{ $row['status']->label() }}
{{ $row['progress'] === null ? '-' : round($row['progress'] * 100).' %' }}
@if ($obj->due_on)

{{ __('dashboard.col_due') }} : {{ App\Support\Dates::format($obj->due_on) }}

@endif
@empty

{{ __('dashboard.no_objectives') }}

@endforelse
@if ($full) {{-- Quarterly table (template 12) --}}

{{ __('dashboard.quarters_title') }}

@foreach ($data['quarters'] as $q)@endforeach @php $pct = fn ($v) => $v === null ? '' : App\Support\Percent::whole($v).' %'; $lines = [ ['q_due', array_column($data['quarters'], 'due'), $data['totals']['due']], ['q_done', array_column($data['quarters'], 'done'), $data['totals']['done']], ['q_rate', array_map($pct, array_column($data['quarters'], 'rate')), $pct($data['totals']['rate'])], ['q_respected', array_column($data['quarters'], 'respected'), $data['totals']['respected']], ]; @endphp @foreach ($lines as [$label, $cells, $total]) @foreach ($cells as $cell)@endforeach @endforeach @foreach ([['q_outputs_planned', 'outputs_planned'], ['q_outputs_done', 'outputs_actual'], ['q_savings', 'savings']] as [$label, $field]) @foreach ($data['quarters'] as $q)@endforeach @endforeach
{{ __('dashboard.q_label', ['n' => $q['n']]) }}{{ __('dashboard.total') }}
{{ __('dashboard.'.$label) }}{{ $cell }}{{ $total }}
{{ __('dashboard.'.$label) }}{{ App\Support\Money::format($q[$field]) }}{{ App\Support\Money::format(array_sum(array_column($data['quarters'], $field))) }}
{{-- Blockers and corrective actions --}}

{{ __('dashboard.open_corrective') }}

@foreach ($rows['corrective'] ?? [] as $id => $row)
@endforeach {{ __('dashboard.corrective_add') }}
@endif

{{ __('dashboard.history_link') }}