MEGAINFRA-WEBAPP/src/app/api/sites
DEls 607de20232 feat(sites): admins can correct a site's project code
The project code was locked once set, on the belief that changing it
would break joins. Nothing joins on it: every record links to the site by
id, and the PO email intake reads codes live. A mistyped code (Nellmapius
was 001 instead of C26/27) could only be fixed in the database.

In Edit site an admin double-clicks the code to unlock it. PATCH accepts
project_code from admins only, trims it, requires 1-64 characters, answers
409 when another site already uses it, and writes nothing when unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-02 22:59:30 +02:00
..
[id] feat(sites): admins can correct a site's project code 2026-11-02 22:59:30 +02:00
route.permissions.test.ts Allow assigned-site users to perform operational actions 2026-09-29 23:58:40 +02:00
route.ts Allow assigned-site users to perform operational actions 2026-09-29 23:58:40 +02:00