PR #256 · pramaan-io/pramaan-functions · merged 2026-06-04
sequenceDiagram autonumber participant mig as Migration participant sch as Schema participant svc as Service participant rt as Router mig->>mig: Rebuild RLS mig->>mig: Seed system forums mig->>sch: Entity gains fields sch->>svc: List DTO ready svc->>rt: GET /app/forums rt->>rt: Write routes removed
| Method | in → out | what it does |
|---|---|---|
Forum | (type) | system-or-firm venue row with source check constraint |
_seed_system_forums | () → None | inserts the platform-owned forum venues |
_create_forum_reference_trigger | () → None | guards Matter and Proceeding forum references |
Alembic migration that rebuilds forum row-level security, seeds system venues, and creates a database trigger guarding Matter and Proceeding references.
| new method | signature |
|---|---|
_drop_forum_rls | () → None |
_disable_forum_rls | () → None |
_enable_forum_rls | () → None |
_create_forum_rls | () → None |
_create_legacy_forum_rls | () → None |
_seed_system_forums | () → None |
_create_forum_reference_trigger | () → None |
_drop_forum_reference_trigger | () → None |
upgrade | () → None |
downgrade | () → None |
revision : strdown_revision : str | Sequence[str] | Nonebranch_labels : str | Sequence[str] | Nonedepends_on : str | Sequence[str] | NoneForum entity — gained source, key, category, location and firm identifier fields, plus a check constraint pinning source to system or firm.
| new class | signature |
|---|---|
Forum | (type) |
firm_id : UUID | Nonesource : strkey : strcategory : strlocation : strForum DTOs — added a list-ready shape carrying category, location, and source; dropped write-side DTOs because writes are gone from the app.
| new class | signature |
|---|---|
ForumSource | (class) |
ForumCategory | (class) |
ForumListItem | (class) |
name : strcategory : ForumCategorycategory_label : strlocation : strsource : ForumSourcesrc/domains/forum/service.py+29 −142Forum service — trimmed to a read-side list helper that maps a forum row into the list item DTO; write paths removed.
| new method | signature |
|---|---|
_list_item | (forum) → ForumListItem |