Add control-policy mappings and rename control APIs
This introduces the ability to map controls to policies alongside the existing control-mitigation mappings. The feature adds bidirectional relationships with new GraphQL fields on Control and Policy types. Signed-off-by: gearnode <bryan@frimin.fr>
This commit is contained in:
7
pkg/coredata/migrations/20250408T205600Z.sql
Normal file
7
pkg/coredata/migrations/20250408T205600Z.sql
Normal file
@@ -0,0 +1,7 @@
|
||||
CREATE TABLE controls_policies (
|
||||
control_id TEXT NOT NULL REFERENCES controls(id),
|
||||
policy_id TEXT NOT NULL REFERENCES policies(id),
|
||||
tenant_id TEXT NOT NULL,
|
||||
created_at TIMESTAMP WITH TIME ZONE NOT NULL,
|
||||
PRIMARY KEY (control_id, policy_id)
|
||||
);
|
||||
Reference in New Issue
Block a user