From 6ecab961370a19289f8e74b62ca6223b34794774 Mon Sep 17 00:00:00 2001 From: Pontoporeia Date: Wed, 8 Jul 2026 13:44:15 +0200 Subject: [PATCH] fieldset-academic: dim locked year field, remove required asterisk MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When locked_year is set, render the Année label+input inline with opacity:0.55 instead of via text-field.php. No asterisk since editing is disabled. The hidden input still ensures the value is submitted. --- .../partials/form/fieldset-academic.php | 21 ++++++++++++------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/app/templates/partials/form/fieldset-academic.php b/app/templates/partials/form/fieldset-academic.php index fbee1f0..bf6fb52 100644 --- a/app/templates/partials/form/fieldset-academic.php +++ b/app/templates/partials/form/fieldset-academic.php @@ -22,24 +22,29 @@ $lockedYear = $lockedYear ?? null; 2000, 'max' => date('Y') + 1]); if ($lockedYear !== null): - // Link specifies a locked academic year: pre-fill, disable editing. - $value = (string)$lockedYear; - $attrs['disabled'] = true; - $attrs['readonly'] = true; - // Include a hidden input so the value is still submitted when the field is disabled. + // Link specifies a locked academic year: render a dimmed, non-editable + // field with no required indicator, plus a hidden input for submission. ?> +
+ + +
2000, 'max' => date('Y') + 1]); + include APP_ROOT . '/templates/partials/form/text-field.php'; endif; - include APP_ROOT . '/templates/partials/form/text-field.php'; ?>