Penambahan Akses Laman Dosen dab perbaikan fix
This commit is contained in:
@@ -0,0 +1,67 @@
|
||||
{{-- Detail kelas asli dari DB lama: peserta (KRS disetujui) dengan komponen nilai. --}}
|
||||
@php
|
||||
$judul = "{$kelas['matkul']} ({$kelas['kelas']})";
|
||||
$angka = fn (?float $n): string => $n === null ? '-' : number_format($n, fmod($n, 1.0) === 0.0 ? 0 : 2, ',', '.');
|
||||
@endphp
|
||||
|
||||
<x-layouts.app :title="$judul">
|
||||
<x-ui.page-header
|
||||
:title="$judul"
|
||||
:description="$kelas['kode'].', '.$kelas['sks'].' SKS, '.$kelas['jadwal'].', ruang '.$kelas['ruang']"
|
||||
:breadcrumbs="['Kelas saya' => route('dosen.kelas.index'), $judul => null]"
|
||||
>
|
||||
<x-slot:actions>
|
||||
<x-ui.button variant="secondary" :href="route('dosen.presensi', ['kelas' => $kelas['id']])" icon="clipboard-document-check">Presensi</x-ui.button>
|
||||
<x-ui.button :href="route('dosen.penilaian', ['kelas' => $kelas['id']])" icon="pencil-square">Input nilai</x-ui.button>
|
||||
</x-slot:actions>
|
||||
</x-ui.page-header>
|
||||
|
||||
<div class="stack">
|
||||
<x-ui.stats>
|
||||
<x-ui.stat label="Peserta terdaftar" :value="$kelas['peserta']" icon="users" :hint="$kelas['kapasitas'] ? 'Kapasitas '.$kelas['kapasitas'] : 'Kapasitas tidak dibatasi'" />
|
||||
<x-ui.stat label="Jumlah pertemuan" :value="$kelas['pertemuan'] ?? '-'" icon="calendar-days" />
|
||||
<x-ui.stat label="Rata-rata kehadiran" :value="$rataHadir === null ? '-' : $rataHadir.'%'" icon="clipboard-document-check" :hint="'Batas minimal '.$batas.'%'" />
|
||||
</x-ui.stats>
|
||||
|
||||
@if ($kelas['dikunci'])
|
||||
<x-ui.alert tone="info" title="Nilai sudah dikunci">Nilai kelas ini sudah diterbitkan ke mahasiswa dan tidak dapat diubah dari sini.</x-ui.alert>
|
||||
@endif
|
||||
|
||||
<x-satu.datatable label="Daftar peserta kelas" placeholder="Cari NIM atau nama">
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col">NIM</th>
|
||||
<th scope="col">Nama</th>
|
||||
<th scope="col" class="num">Hadir</th>
|
||||
<th scope="col" class="num">Tugas</th>
|
||||
<th scope="col" class="num">UTS</th>
|
||||
<th scope="col" class="num">UAS</th>
|
||||
<th scope="col">Nilai</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@forelse ($peserta as $p)
|
||||
<tr>
|
||||
<td class="table__title">{{ $p['nim'] }}</td>
|
||||
<td>{{ $p['nama'] }}</td>
|
||||
<td class="num">{{ $p['hadir'] ?? '-' }}@if ($kelas['pertemuan'] && $p['hadir'] !== null) / {{ $kelas['pertemuan'] }}@endif</td>
|
||||
<td class="num">{{ $angka($p['tugas']) }}</td>
|
||||
<td class="num">{{ $angka($p['uts']) }}</td>
|
||||
<td class="num">{{ $angka($p['uas']) }}</td>
|
||||
<td>
|
||||
@if ($p['huruf'])
|
||||
<x-ui.badge tone="accent">{{ $p['huruf'] }}</x-ui.badge>
|
||||
@else
|
||||
<span class="text-muted">-</span>
|
||||
@endif
|
||||
</td>
|
||||
</tr>
|
||||
@empty
|
||||
<tr><td colspan="7"><x-ui.empty icon="users" title="Belum ada peserta" description="Peserta tampil setelah KRS mahasiswa disetujui dosen pembimbing akademik." /></td></tr>
|
||||
@endforelse
|
||||
</tbody>
|
||||
</table>
|
||||
</x-satu.datatable>
|
||||
</div>
|
||||
</x-layouts.app>
|
||||
Reference in New Issue
Block a user