Commit Graph
7 Commits
Author SHA1 Message Date
Bro a867b3a267 fix: anti-duplikat violation di input manual presensi
Sama seperti fix di sync controller:
- Cek existing violation (student_id + type + date + recorded_by)
- Ada alpha → update atau create
- Tidak alpha → hapus violation lama
- Berlaku untuk alpha dan terlambat
- Mencegah duplikat tiap kali admin submit ulang form
2026-07-24 17:32:22 +07:00
Bro 91b7f1e591 fix: rekap alpha proporsional berdasarkan max 10 jam/hari
Sebelum: alpha = alphaCount / totalRecord (jika jadwal 1 jam,
  1 alpha = 1 hari — tidak akurat)
Sesudah: alpha = alphaCount / 10 (max jam sekolah per hari)
  1 alpha = 0.1 hari, 10 alpha = 1 hari
- Berlaku untuk rekap mingguan dan bulanan
2026-07-24 13:12:55 +07:00
Novy San87 fb5e349ae6 feat: add Open Graph meta tags for social preview 2026-07-23 11:59:12 +07:00
Novy San87 9e1b5c34e5 feat: rekap presensi harian, mingguan, bulanan + export excel
- Add 3 jenis rekap presensi (harian/mingguan/bulanan) per kelas
- Weekly recap: tabel H,S,I,A per hari + kolom TOTAL
- Alpha proporsional: A = jam_alpha / total_jam
- Pemisah border antar hari dan kolom TOTAL
- Export Excel rekap mingguan (.xlsx)
- Fix max_input_vars PHP limit (1000→5000)
- Fix Carbon date object issue di groupBy
2026-07-23 11:11:28 +07:00
Bro 5eb3830895 feat: replace attendance history list with interactive calendar
- Calendar shows per-date student count badge (green=all hadir, red=ada alpha)
- Click badge to go to attendance input for that date
- Prev/next month navigation with API fetch
- Controller passes initial month data inline (no flash on load)
2026-07-23 00:00:21 +07:00
Bro e4fef817b0 fix: attendance stats count based on unique students, not records per lesson-hour 2026-07-22 23:56:57 +07:00
Bro 31ef9c0b0b system-locked violation types (alpha & terlambat) + proporsional poin alpha per jam
- Migration: add is_system column to violation_types, mark alpha & terlambat
- DestroyType guard: system types cannot be deleted
- UpdateType guard: slug tetap walau nama diubah untuk system types
- UI: delete button hidden, badge lock untuk system types
- Seeder: ViolationTypeDefaultsSeeder untuk fresh deploy
- AttendanceController: lookup by slug (alpha/terlambat) instead of fuzzy match
- Alpha auto-violation: poin proporsional per jam (round((points/10)*count), min 1)
- Terlambat auto-violation: poin fix sesuai jenis (2 poin)
- Also handles both A (alpha) and T (terlambat) statuses for auto-violations
2026-07-22 23:55:27 +07:00