KPI ({{ request()->query('code') }})

@csrf @method('PUT')

KPI (Key Performance Indicators)

@forelse ($indicators as $indicator) @empty @endforelse
@forelse ($indicators as $indicator)

{{ $indicator->name }}

{{ $indicator->category->name ?? '-' }}

Target : {{ $indicator->target }} Bobot : {{ $indicator->weight }}
@empty

Tidak ada indikator KPI untuk jabatan ini.

@endforelse

KPI Potensi

@forelse ($potencies as $potency) @empty @endforelse
@forelse ($potencies as $potency)

{{ $potency->name }}

Target : {{ $potency->target }} Bobot : {{ $potency->weight }}
@empty

Tidak ada potensi untuk jabatan ini.

@endforelse

Hasil Penilaian

Nama: {{ $employee->fullname }}
Jabatan: {{ $employee->employment?->jobposition?->name ?? '-' }}
@php $totalKpiScore = 0; foreach ($existingKpiScores as $score) { $weight = $score->kpiindicator->weight ?? 0; $totalKpiScore += ($score->score ?? 0) * ($weight / 100); } $totalPotencyScore = 0; foreach ($existingPotencyScores as $score) { $weight = $score->kpipotency->weight ?? 0; $totalPotencyScore += ($score->score ?? 0) * ($weight / 100); } $performancePortion = $totalKpiScore * 0.8; $performancePortionPotency = $totalPotencyScore * 0.2; $finalScore = round((($performancePortion + $performancePortionPotency) / 5) * 100, 2); @endphp

Skor KPI (80%): {{ round($performancePortion, 2) }}

Skor Potensi (20%): {{ round($performancePortionPotency, 2) }}

Total Akhir: {{ $finalScore }}%