@extends('simaju.layouts.main') @section('title', 'Detail Rapor') @section('page-title', 'Detail Rapor') @section('page-subtitle', 'Lihat detail rapor siswa') @section('content')
Kembali ke Daftar Rapor
{{ strtoupper(substr($rapor->siswa->nama, 0, 2)) }}

{{ $rapor->siswa->nama }}

NIS: {{ $rapor->siswa->nis }}
{{ $rapor->siswa->kelas->nama_kelas }} - {{ $rapor->siswa->kelas->jurusan->nama_jurusan }}
Tahun Ajaran: {{ $rapor->tahun_ajaran }}
Semester: {{ ucfirst($rapor->semester) }}
{{ number_format($rapor->rata_rata, 2) }}
Rata-rata Nilai

Status Rapor

{{ $rapor->status_label }}
@csrf @method('PUT')

Daftar Nilai

@php $no = 1; function getPredikat($nilai) { if ($nilai >= 90) return ['A', 'text-green-600', 'bg-green-50']; if ($nilai >= 80) return ['B', 'text-blue-600', 'bg-blue-50']; if ($nilai >= 70) return ['C', 'text-yellow-600', 'bg-yellow-50']; if ($nilai >= 60) return ['D', 'text-orange-600', 'bg-orange-50']; return ['E', 'text-red-600', 'bg-red-50']; } @endphp @forelse($rapor->nilai_data as $nilai) @php [$predikat, $textColor, $bgColor] = getPredikat($nilai['nilai_akhir']); @endphp @empty @endforelse @if(count($rapor->nilai_data) > 0) @endif
No Mata Pelajaran Tugas UTS UAS Nilai Akhir Predikat
{{ $no++ }} {{ $nilai['mata_pelajaran'] }} {{ $nilai['nilai_tugas'] }} {{ $nilai['nilai_uts'] }} {{ $nilai['nilai_uas'] }} {{ number_format($nilai['nilai_akhir'], 2) }} {{ $predikat }}

Tidak ada data nilai

Rata-rata: {{ number_format($rapor->rata_rata, 2) }} @php [$predikat, $textColor, $bgColor] = getPredikat($rapor->rata_rata); @endphp {{ $predikat }}

Keterangan Predikat

A
90 - 100
B
80 - 89
C
70 - 79
D
60 - 69
E
< 60
@endsection