Sacha Al Himdani
553901e4ad
Add risk publish to document system
...
Replace the old snapshot-based system for risks with the publish
document system, mirroring the prior vendor / processing activity / DPIA
/ TIA migration. Includes the GraphQL mutation, MCP tool, CLI command,
n8n operation, frontend publish dialog, e2e tests, and a prosemirror
register template covering name, description, category, treatment,
owner, inherent and residual scoring, and notes.
The risk register lives as a generated DocumentTypeRegister document on
the organization, reused across publishes (the major version bumps on
every republish). Approvers can be passed in to create a draft pending
approval; otherwise the version is published immediately. The frontend
Risks page exposes a Publish button and a Document link button when the
document exists, and pre-fills the previous default approvers.
Risks was the last remaining snapshot type, so this commit also removes
the entire snapshot system: drop snapshotId from the Risk GraphQL type
and RiskFilter; remove RiskSnapshotter, Risks.Snapshot,
InsertRiskSnapshots, and the SnapshotID/SourceID fields on Risk; delete
Snapshot, ControlSnapshot, SnapshotsType, SnapshotOrderField,
Snapshottable, the SnapshotService, the Snapshot console resolvers and
GraphQL schema, the Snapshot MCP types and operations
(list/get/take/listControlSnapshots), the snapshot CLI (prb snapshot),
the snapshot frontend pages, routes, banner, LinkedSnapshotsCard,
SnapshotGraph, snapshot helpers, and the snapshot n8n resource and
control link/unlink snapshot operations. The snapshot_id columns remain
in the database but are now filtered out with snapshot_id IS NULL.
Add Get/Upsert/Clear GeneratedDocumentID methods on Risk backed by a new
risks_document_id column on generated_documents, matching the
ProcessingActivity/Finding/Vendor pattern. The migration command
migrate-risk-snapshots-to-documents uses raw SQL queries instead of the
Go snapshot types, since those are gone.
Signed-off-by: Sacha Al Himdani <sacha@getprobo.com >
2026-05-04 14:13:42 +02:00
..
2026-05-04 14:13:42 +02:00
2026-04-02 14:49:13 +02:00
2026-04-02 14:37:29 +02:00
2026-04-03 11:56:06 +02:00
2026-04-02 14:49:13 +02:00
2026-04-02 14:37:29 +02:00
2026-04-02 14:37:29 +02:00
2026-04-02 14:49:13 +02:00
2026-04-02 14:37:29 +02:00
2026-04-02 14:49:13 +02:00
2026-04-02 14:37:29 +02:00
2026-04-02 14:37:29 +02:00
2026-04-03 11:56:06 +02:00
2026-04-22 11:15:48 +02:00
2026-04-22 11:15:48 +02:00
2026-04-02 14:37:29 +02:00
2026-04-03 11:56:06 +02:00
2026-04-02 14:37:29 +02:00
2026-04-02 14:37:29 +02:00
2026-04-03 11:56:06 +02:00
2026-04-02 14:49:13 +02:00
2026-04-02 14:37:29 +02:00
2026-04-03 11:56:06 +02:00
2026-04-02 14:49:13 +02:00
2026-04-02 14:37:29 +02:00
2026-04-02 14:37:29 +02:00
2026-04-16 16:27:30 +02:00
2026-04-26 22:58:21 +02:00
2026-04-26 22:58:22 +02:00
2026-03-25 17:38:32 +01:00
2026-04-16 00:01:13 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-21 19:36:17 +02:00
2026-04-21 19:36:17 +02:00
2026-03-25 17:38:32 +01:00
2026-03-21 19:16:19 +01:00
2026-03-21 19:16:19 +01:00
2026-03-21 19:16:19 +01:00
2026-04-03 11:56:06 +02:00
2026-05-04 14:13:42 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-04-02 14:37:29 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-02 14:37:29 +02:00
2026-04-02 14:37:29 +02:00
2026-04-02 14:37:29 +02:00
2026-04-13 19:24:46 +02:00
2026-04-13 19:24:46 +02:00
2026-04-03 11:56:06 +02:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-21 11:06:36 +02:00
2026-04-21 11:06:36 +02:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-16 00:01:13 +02:00
2026-03-25 17:38:32 +01:00
2026-05-04 14:13:42 +02:00
2026-04-13 14:50:42 +04:00
2026-04-13 14:50:41 +04:00
2026-04-13 14:52:20 +04:00
2026-04-24 12:18:09 +04:00
2026-04-13 14:52:20 +04:00
2026-04-13 14:52:20 +04:00
2026-05-02 18:10:18 +04:00
2026-04-30 11:46:12 +04:00
2026-04-21 11:40:21 +04:00
2026-04-13 14:50:41 +04:00
2026-04-30 11:46:11 +04:00
2026-04-13 14:50:41 +04:00
2026-04-13 14:50:41 +04:00
2026-04-28 15:28:17 +04:00
2026-04-13 14:50:41 +04:00
2026-04-28 15:28:17 +04:00
2026-05-01 16:39:32 +04:00
2026-04-30 11:46:10 +04:00
2026-04-30 11:46:10 +04:00
2026-05-01 16:39:32 +04:00
2026-04-30 11:46:10 +04:00
2026-04-30 11:46:12 +04:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-24 16:05:11 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-28 18:07:46 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-20 14:44:00 +02:00
2026-04-21 19:36:17 +02:00
2026-03-25 17:38:32 +01:00
2026-04-09 18:18:30 +02:00
2026-04-16 00:01:13 +02:00
2026-04-03 17:38:28 +02:00
2026-03-25 17:38:32 +01:00
2026-04-16 00:01:13 +02:00
2026-03-31 13:31:30 +02:00
2026-03-31 13:31:30 +02:00
2026-04-09 18:18:30 +02:00
2026-04-09 18:18:30 +02:00
2026-03-31 13:31:30 +02:00
2026-04-09 18:18:30 +02:00
2026-04-03 11:56:06 +02:00
2026-04-03 17:38:28 +02:00
2026-03-25 17:38:32 +01:00
2026-04-16 00:01:13 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-04-09 18:18:30 +02:00
2026-04-23 20:50:25 +02:00
2026-04-16 00:01:13 +02:00
2026-04-16 00:01:13 +02:00
2026-04-16 00:01:13 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-19 12:00:53 +02:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-05-04 14:13:42 +02:00
2026-04-23 20:50:25 +02:00
2026-03-31 13:31:30 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-18 19:19:04 +01:00
2026-04-03 11:56:06 +02:00
2026-04-03 11:56:06 +02:00
2026-04-28 13:12:58 +02:00
2026-03-19 10:02:28 +01:00
2026-03-19 16:37:51 +01:00
2026-03-17 15:05:31 +01:00
2026-03-17 15:05:31 +01:00
2026-04-28 13:12:58 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-04-03 11:56:06 +02:00
2026-04-03 17:51:31 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-27 16:06:44 +04:00
2026-03-25 17:38:32 +01:00
2026-04-23 10:45:48 +02:00
2026-04-23 10:45:48 +02:00
2026-03-25 17:38:32 +01:00
2026-04-02 10:59:25 +02:00
2026-04-02 14:37:29 +02:00
2026-03-25 17:38:32 +01:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-04-19 12:00:53 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-28 13:12:58 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-04-26 22:58:22 +02:00
2026-04-28 18:07:46 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-28 18:07:46 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-04-03 11:56:06 +02:00
2026-05-04 14:13:42 +02:00
2026-04-03 11:56:06 +02:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-05-04 14:13:42 +02:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-24 15:55:31 +01:00
2026-03-25 17:38:32 +01:00
2026-04-29 17:57:19 +04:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-04-09 13:06:06 +02:00
2026-04-21 19:36:17 +02:00
2026-04-02 13:35:39 +02:00
2026-04-02 13:35:39 +02:00
2026-04-03 08:33:37 +02:00
2026-04-03 11:56:06 +02:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-28 18:07:46 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-29 16:24:29 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-29 16:24:29 +02:00
2026-03-25 17:38:32 +01:00
2026-04-29 16:24:29 +02:00
2026-03-25 17:38:32 +01:00
2026-04-29 16:24:29 +02:00
2026-04-29 16:24:29 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-29 16:24:29 +02:00
2026-03-25 17:38:32 +01:00
2026-04-29 16:24:29 +02:00
2026-04-29 16:24:29 +02:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-03-25 17:38:32 +01:00
2026-04-20 15:37:39 +02:00
2026-04-03 11:56:06 +02:00
2026-03-25 17:38:32 +01:00
2026-04-19 12:00:53 +02:00