# TODO ## Admin area cleanup - [x] Combine `acces-etudiante.php` + `file-access.php` into `acces.php` (two `
` blocks) - [x] Move `system.php` content into `parametres.php` (system section + logs section) - [x] Use `
` for sections, `
` only where form fields are present - [x] Redirect legacy URLs (acces-etudiante.php, file-access.php, system.php) with 301 - [x] Update action redirects to point to new pages - [x] Update admin nav header (merged 3 items → 2) ## Bug fixes - [x] Fix `$enabledAccessTypes` undefined / `array_map()` TypeError on edit page — controller was fetching `getAccessTypes()` instead of `getEnabledFormAccessTypes()` and returning it under the wrong key - [x] Fix fatal TypeError: `old()` called with wrong arity in `jury-fieldset.php` partial under partage context — removed `?: null` coercions so `$juryPresident`/`$juryPromoteur` are `''` not `null`, keeping `$addMode` false - [x] Fix `$formData` destroyed by included partials (`fieldset-academic.php`, `fieldset-metadata.php`, `fieldset-licence-explanation.php` were incorrectly unsetting `$formData`/wrong variable in caller scope) ## Form help blocks — sortable admin UI - [x] Migration 005: add `sort_order` column to `form_help_blocks` - [x] `Database::getAllFormHelpBlocks()` — ORDER BY sort_order, expose sort_order in returned data - [x] `Database::reorderFormHelpBlocks(array $keys)` — persist new order - [x] `actions/form-help-reorder.php` — HTMX POST handler (CSRF-protected, 204 response) - [x] `templates/admin/contenus.php` — replace table with two-panel layout: - Left: SortableJS + htmx drag-and-drop card list - Right: static form structure reference (fieldsets + inputs) - [x] CSS in admin.css: `.fhb-*` classes for layout, cards, ghost/chosen/drag states - [x] `schema.sql` — updated `form_help_blocks` DDL with `sort_order` - [x] Vendor SortableJS 1.15.2 into `assets/js/sortable.min.js` (remove CDN dependency) ## Bug fixes (continued) - [x] Add missing favicon tags to all three `` blocks in `partage/index.php` (error page, password gate, main form) ## CSS refactor - [x] Move semantic HTML element baseline styles into common.css - `fieldset` (background, border, padding, radius) - `legend` (font, weight, color, transform) - `small` (size, color, display, margin) - `table`, `th`, `td` (collapse, sizing, spacing) - `dialog` + `::backdrop` - `details > summary` - [x] Remove duplicated rules from admin.css, form.css, system.css, file-access.css - [x] Fix file-access.css to use real design tokens (was using undefined --border, --surface, --accent, etc.) - [x] Remove redundant @import url("./variables.css") from admin.css, system.css, file-access.css