fix is_active student flag logic and make moving with enrollment status
Deploy to Shared Hosting / Shared hosting deploy (push) Failing after 47s
Tests / PHPUnit (push) Successful in 1m16s

This commit is contained in:
root
2026-08-20 03:11:37 -04:00
parent 6f722795c5
commit 0a31aa1393
20 changed files with 588 additions and 489 deletions
+7 -2
View File
@@ -285,12 +285,17 @@ final class EnrollmentTransitionService
];
if ($original !== null) {
$this->db->table('enrollments')->where('id', (int) $original['id'])->update($payload);
$payload['id'] = (int) $original['id'];
} else {
$payload['created_at'] = date('Y-m-d H:i:s');
$this->db->table('enrollments')->insert($payload);
}
(new EnrollmentStatusService($this->db))->upsertStatus(
$payload,
$performedBy,
'initial_transition_applied'
);
if ((int) ($evaluation['assigned_class_section_id'] ?? 0) > 0) {
$this->upsertStudentClass($studentId, (int) $evaluation['assigned_class_section_id'], $targetSchoolYear, $performedBy);
}