feat(sdk): vendor-compliance cross-module integration — VVT, obligations, TOM, loeschfristen
Integrate the vendor-compliance module with four DSGVO modules to eliminate data silos and resolve the VVT processor tab's ephemeral state problem. - Reposition vendor-compliance sidebar from seq 4200 to 2500 (after VVT) - VVT: replace ephemeral ProcessorRecord state with Vendor-API fetch (read-only) - Obligations: add linked_vendor_ids (JSONB) + compliance check #12 MISSING_VENDOR_LINK - TOM: add vendor TOM-controls cross-reference table in overview tab - Loeschfristen: add linked_vendor_ids (JSONB) + vendor picker + document section - Migrations: 069_obligations_vendor_link.sql, 070_loeschfristen_vendor_link.sql - Tests: 12 new backend tests (125 total pass) - Docs: update obligations.md + vendors.md with cross-module integration Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -291,17 +291,60 @@ POST /sdk/v1/ucca/obligations/gap-analysis
|
||||
|
||||
---
|
||||
|
||||
## Frontend
|
||||
## Frontend — 5-Tab-Aufbau
|
||||
|
||||
**URL:** `https://macmini:3007/sdk/obligations`
|
||||
|
||||
Die Obligations-Seite zeigt:
|
||||
Die Obligations-Seite ist in 5 Tabs gegliedert:
|
||||
|
||||
- **Überblick-Kacheln:** Gesamtanzahl, nach Priorität, nach Regulierung
|
||||
- **Regulierungs-Tabs:** Pflichten gefiltert nach DSGVO, AI Act, NIS2, etc.
|
||||
- **Gap-Analyse-View:** Fehlende TOM-Controls visualisiert als Heatmap
|
||||
- **TOM-Control-Panel:** Mapping von Pflichten → Controls mit Status
|
||||
- **Export:** C-Level-Memo (Markdown) direkt aus dem Frontend
|
||||
| Tab | Inhalt |
|
||||
|-----|--------|
|
||||
| **Uebersicht** | Statistik-Kacheln, Compliance-Score, Regulierungs-Filter, Pflichten-Liste (Cards), Compliance-Befunde |
|
||||
| **Detail-Editor** | Pflichtenliste mit Bearbeitungsfunktion, Status-/Prioritaets-Badges |
|
||||
| **Profiling** | Auto-Profiling aus CompanyProfile + Compliance-Scope, anwendbare Regulierungen |
|
||||
| **Gap-Analyse** | GapAnalysisView + TOMControlPanel (UCCA-Integration) |
|
||||
| **Pflichtenregister** | Druckbares HTML-Dokument (12 Sektionen), Org-Header, Revisionen |
|
||||
|
||||
### 12 Compliance-Checks
|
||||
|
||||
Der Compliance-Checker (`obligations-compliance.ts`) prueft automatisch:
|
||||
|
||||
| # | Check | Severity | Ausloeser |
|
||||
|---|-------|----------|-----------|
|
||||
| 1 | `MISSING_RESPONSIBLE` | MEDIUM | Pflicht ohne Verantwortlichen |
|
||||
| 2 | `OVERDUE_DEADLINE` | HIGH | Frist ueberschritten, Status != completed |
|
||||
| 3 | `MISSING_EVIDENCE` | HIGH | Abgeschlossene Pflicht ohne Nachweis |
|
||||
| 4 | `MISSING_DESCRIPTION` | MEDIUM | Pflicht ohne Beschreibung |
|
||||
| 5 | `NO_LEGAL_REFERENCE` | HIGH | Pflicht ohne Artikel-Referenz |
|
||||
| 6 | `INCOMPLETE_REGULATION` | HIGH | Regulierung mit allen Pflichten pending/overdue |
|
||||
| 7 | `HIGH_PRIORITY_NOT_STARTED` | CRITICAL | Critical/High-Pflicht seit >30d pending |
|
||||
| 8 | `STALE_PENDING` | LOW | Pflicht seit >90d pending |
|
||||
| 9 | `MISSING_LINKED_SYSTEMS` | MEDIUM | Pflicht ohne Systemzuordnung |
|
||||
| 10 | `NO_REVIEW_PROCESS` | MEDIUM | Keine Pflicht hat review_date |
|
||||
| 11 | `CRITICAL_WITHOUT_EVIDENCE` | CRITICAL | Kritische Pflicht ohne Nachweis |
|
||||
| 12 | `MISSING_VENDOR_LINK` | MEDIUM | Art.-28-Pflicht ohne verknuepften Auftragsverarbeiter |
|
||||
|
||||
**Score:** `100 - (CRITICAL*15 + HIGH*10 + MEDIUM*5 + LOW*2)`, min 0.
|
||||
|
||||
### Pflichtenregister-Dokument (12 Sektionen)
|
||||
|
||||
Das druckbare HTML-Dokument (`obligations-document.ts`) umfasst:
|
||||
|
||||
| # | Sektion | Datenquelle |
|
||||
|---|---------|-------------|
|
||||
| 0 | Deckblatt | orgHeader |
|
||||
| — | Inhaltsverzeichnis | statisch |
|
||||
| 1 | Ziel und Zweck | statisch |
|
||||
| 2 | Geltungsbereich | orgHeader, obligations (distinct sources) |
|
||||
| 3 | Methodik | statisch |
|
||||
| 4 | Regulatorische Grundlagen | obligations gruppiert nach source |
|
||||
| 5 | Pflichtenuebersicht | obligations nach Status |
|
||||
| 6 | Detaillierte Pflichten | Pro Regulierung: Detail-Karten |
|
||||
| 7 | Verantwortlichkeiten | Rollenmatrix |
|
||||
| 8 | Fristen und Termine | Ueberfaellige + anstehende Deadlines |
|
||||
| 9 | Nachweisverzeichnis | Evidence pro Pflicht |
|
||||
| 10 | Compliance-Status | Score + Issues |
|
||||
| 11 | Aenderungshistorie | Revisionstabelle |
|
||||
|
||||
---
|
||||
|
||||
@@ -333,3 +376,45 @@ cd ai-compliance-sdk && go test ./internal/ucca/... -v -run TestObligationCondit
|
||||
**Weitere Tests:**
|
||||
- `tom_mapper_test.go` — TOM-Mapping Tests
|
||||
- `v2_loader_test.go` — JSON-Loader für Regulierungs-Dateien
|
||||
- `backend-compliance/tests/test_obligation_routes.py` — 39 Backend-API-Tests
|
||||
|
||||
---
|
||||
|
||||
## Cross-Modul-Integration
|
||||
|
||||
| Modul | Integration |
|
||||
|-------|------------|
|
||||
| **VVT** | Pflichten referenzieren Verarbeitungstaetigkeiten ueber `linked_systems` |
|
||||
| **TOM** | TOM-Control-Mapping (UCCA) zeigt erforderliche Massnahmen pro Pflicht |
|
||||
| **Loeschfristen** | Loeschpflichten (Art. 17 DSGVO) im Pflichtenregister referenziert |
|
||||
| **Vendor Compliance** | Art.-28-Pflichten verknuepfbar mit Auftragsverarbeitern ueber `linked_vendor_ids` (DB: JSONB). Compliance-Check #12 (`MISSING_VENDOR_LINK`) prueft fehlende Verknuepfung. |
|
||||
| **UCCA** | Condition Engine bewertet Pflichten gegen UnifiedFacts |
|
||||
| **Compliance-Scope** | Auto-Profiling nutzt Scope-Antworten fuer Regulierungs-Ableitung |
|
||||
|
||||
---
|
||||
|
||||
## Audit-Faehigkeit
|
||||
|
||||
Das Pflichtenregister ist auditfaehig durch:
|
||||
|
||||
1. **Druckbares HTML-Dokument** mit 12 Sektionen, A4-Layout, `@media print`
|
||||
2. **11 automatische Compliance-Checks** mit Score (0-100) und Befunden nach Schweregrad
|
||||
3. **Nachweisverzeichnis** (Sektion 9) dokumentiert Evidence pro Pflicht
|
||||
4. **Aenderungshistorie** (Sektion 11) mit Version, Datum, Autor, Beschreibung
|
||||
5. **Fristen-Tracking** (Sektion 8) mit ueberfaelligen und anstehenden Terminen
|
||||
|
||||
---
|
||||
|
||||
## Datei-Uebersicht
|
||||
|
||||
| Datei | Beschreibung |
|
||||
|-------|-------------|
|
||||
| `admin-compliance/app/sdk/obligations/page.tsx` | Haupt-Seite (5-Tab-Layout) |
|
||||
| `admin-compliance/lib/sdk/obligations-compliance.ts` | 11 Compliance-Checks + Obligation-Type |
|
||||
| `admin-compliance/lib/sdk/obligations-document.ts` | HTML-Dokument-Generator (12 Sektionen) |
|
||||
| `admin-compliance/components/sdk/obligations/ObligationDocumentTab.tsx` | Pflichtenregister-Tab-Komponente |
|
||||
| `admin-compliance/components/sdk/obligations/GapAnalysisView.tsx` | Gap-Analyse-Komponente |
|
||||
| `admin-compliance/components/sdk/obligations/TOMControlPanel.tsx` | TOM-Control-Panel |
|
||||
| `backend-compliance/compliance/api/obligation_routes.py` | 7 Backend-API-Endpoints |
|
||||
| `backend-compliance/migrations/013_obligations.sql` | DB-Schema |
|
||||
| `ai-compliance-sdk/policies/obligations/v2/` | 325 Pflichten, 9 Regulierungen |
|
||||
|
||||
@@ -32,3 +32,28 @@ Seite unter `/sdk/vendor-compliance` mit Vendor-Tabelle, Risiko-Matrix und Vertr
|
||||
## Datenbank
|
||||
|
||||
Migration in der AI Compliance SDK erstellt Tabellen fuer Vendors, Risikobewertungen, Vertraege und AVV-Klauseln.
|
||||
|
||||
- `vendor_vendors` — Stammdaten, Rolle, Risiko-Scores, Kontakte
|
||||
- `vendor_contracts` — AVV-Dokumente, Pruefstatus
|
||||
- `vendor_findings` — Findings aus Pruefungen
|
||||
- `vendor_control_instances` — Control-Instanzen pro Vendor (inkl. 6 TOM-Controls VND-TOM-01..06)
|
||||
- `compliance_templates` — Shared Templates
|
||||
|
||||
## Cross-Modul-Integration
|
||||
|
||||
Seit der Vendor-Compliance Cross-Modul-Integration (2026-03-19) ist das Modul mit vier DSGVO-Modulen verknuepft:
|
||||
|
||||
| Modul | Integration | Richtung |
|
||||
|-------|------------|----------|
|
||||
| **VVT** | Processor-Tab (Art. 30 Abs. 2) liest Vendors mit `role=PROCESSOR/SUB_PROCESSOR` aus Vendor-API. Kein eigener State mehr — Single Source of Truth. | Read |
|
||||
| **Obligations** | Art.-28-Pflichten verknuepfbar via `linked_vendor_ids` (JSONB). Compliance-Check `MISSING_VENDOR_LINK` prueft fehlende Verknuepfung. | Read/Write |
|
||||
| **TOM** | Uebersicht-Tab zeigt Vendor-TOM-Controls (VND-TOM-01..06) als Querverweis-Tabelle. | Read |
|
||||
| **Loeschfristen** | Loeschfrist-Policies verknuepfbar via `linked_vendor_ids` (JSONB). Loeschkonzept-Dokument listet verknuepfte Auftragsverarbeiter. | Read/Write |
|
||||
|
||||
### Sidebar-Position
|
||||
|
||||
Das Vendor-Compliance-Modul steht in der SDK-Sidebar bei **seq 2500** (Paket "dokumentation"), direkt nach VVT (seq 2400):
|
||||
|
||||
```
|
||||
obligations (2000) → dsfa (2100) → tom (2200) → loeschfristen (2300) → vvt (2400) → vendor-compliance (2500)
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user