fix: keep Smart Packages compatible with roof material (#30)
Some checks are pending
CI - Test & Build / Lint & Type Check (push) Waiting to run
CI - Test & Build / Backend Unit Tests (push) Waiting to run
CI - Test & Build / Frontend Build (push) Waiting to run
CI - Test & Build / E2E Tests (Playwright) (push) Blocked by required conditions
CI - Test & Build / Security Scan (push) Waiting to run
CI - Test & Build / CI Summary (push) Blocked by required conditions

Co-authored-by: alexpolo1 <alexpolo1@users.noreply.github.com>
This commit is contained in:
Alex
2026-09-02 07:19:39 +02:00
committed by GitHub
parent adb7e8a17a
commit 8b16d35287
17 changed files with 308 additions and 34 deletions

View File

@@ -0,0 +1,10 @@
-- Persist the roof covering selected in Enhanced Geometry so Smart Package
-- recommendations cannot fall back to an incompatible historical roof type.
ALTER TABLE roof_geometry
ADD COLUMN IF NOT EXISTS roof_material ENUM('tegl','tagpap','eternit','betontag','staal','andet') NULL
AFTER roof_type;
CREATE INDEX IF NOT EXISTS idx_roof_geometry_material ON roof_geometry (roof_material);
ALTER TABLE roof_geometry
ADD UNIQUE INDEX IF NOT EXISTS unique_project (project_id);