fix is_active student flag and apply it in all pages
Deploy to Shared Hosting / Shared hosting deploy (push) Failing after 48s
Tests / PHPUnit (push) Successful in 1m17s

This commit is contained in:
root
2026-08-20 12:59:59 -04:00
parent 0a31aa1393
commit bfa343b69f
57 changed files with 820 additions and 240 deletions
+5 -2
View File
@@ -55,14 +55,17 @@ $lockAttr = $scoresLocked ? 'disabled' : '';
<?php
$studentId = $student['id'];
$scores = $homeworkScores[$studentId]['scores'] ?? [];
$rowLocked = student_is_non_active_for_editing($student, $schoolYear ?? null);
$rowLockAttr = $scoresLocked ? $lockAttr : ($rowLocked ? 'readonly aria-disabled="true"' : '');
?>
<tr>
<tr class="<?= $rowLocked ? 'table-secondary text-muted' : '' ?>">
<td><?= $row++ ?></td>
<td><?= esc($student['school_id']) ?></td>
<td>
<a href="#" class="text-decoration-none" data-family-student-id="<?= (int)$studentId ?>">
<?= esc($student['firstname']) ?>
</a>
<?= student_enrollment_status_button($student, $schoolYear ?? null) ?>
</td>
<td>
<a href="#" class="text-decoration-none" data-family-student-id="<?= (int)$studentId ?>">
@@ -78,7 +81,7 @@ $lockAttr = $scoresLocked ? 'disabled' : '';
name="scores[<?= $studentId ?>][<?= $index ?>]"
value="<?= esc(is_array($scoreValue) ? '' : $scoreValue) ?>"
class="form-control text-center"
min="0" max="100" step="0.01" <?= $lockAttr ?>>
min="0" max="100" step="0.01" <?= $rowLockAttr ?>>
</td>
<?php endforeach; ?>
</tr>