Files
breakpilot-compliance/admin-compliance/app/sdk/iace/[projectId]/risikobewertung/page.tsx
T
Benjamin Admin c6ebe61162
CI / detect-changes (push) Successful in 7s
CI / branch-name (push) Has been skipped
CI / guardrail-integrity (push) Has been skipped
CI / secret-scan (push) Has been skipped
CI / sbom-scan (push) Has been skipped
CI / dep-audit (push) Has been skipped
CI / build-sha-integrity (push) Failing after 4s
CI / validate-canonical-controls (push) Successful in 11s
CI / nodejs-build (push) Successful in 2m23s
CI / test-go (push) Has been skipped
CI / test-python-backend (push) Has been skipped
CI / test-python-document-crawler (push) Has been skipped
CI / loc-budget (push) Successful in 14s
CI / go-lint (push) Has been skipped
CI / python-lint (push) Has been skipped
CI / nodejs-lint (push) Has been skipped
CI / iace-gt-coverage (push) Has been skipped
CI / test-python-dsms-gateway (push) Has been skipped
feat(iace-frontend): Risikobewertung tab with dual risk model + live formula
New tab /sdk/iace/[projectId]/risikobewertung. Per hazard it shows BOTH models
side by side — EN-62061-style (S/F/W/P) and Fine-Kinney (P/E/C) — with
BreakPilot's justified suggested values from public data, the visible formula,
and editable fields that recompute the score + risk band live. The professional
adjusts the values (e.g. from his own licensed DIN/Beuth data); we only supply
the formula + inputs, reproduce no norm table.

Consumes GET .../hazards/:hid/risk-suggestion. Registered in IACE_NAV_ITEMS.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-09 15:40:59 +02:00

42 lines
1.6 KiB
TypeScript

'use client'
import { useParams } from 'next/navigation'
import { useRiskAssessment } from './_hooks/useRiskAssessment'
import { RiskModelCard } from './_components/RiskModelCard'
export default function RisikobewertungPage() {
const params = useParams<{ projectId: string }>()
const projectId = params.projectId
const { hazards, suggestions, loading } = useRiskAssessment(projectId)
return (
<div className="space-y-6">
<div>
<h1 className="text-2xl font-bold text-gray-900 dark:text-gray-100">Risikobewertung</h1>
<p className="text-sm text-gray-500 dark:text-gray-400 max-w-3xl mt-1">
Zwei Modelle pro Gefaehrdung: <strong>EN-62061-Stil</strong> (F/W/P/S) und{' '}
<strong>Fine-Kinney</strong> (P/E/C, US-anerkannt). BreakPilot schlaegt begruendete
Werte aus oeffentlichen Datenquellen vor (ESAW/NIOSH/OSHA) passen Sie sie nach Ihrer
Erfahrung bzw. Ihren eigenen Normdaten an; das Tool rechnet die Formel live aus.
</p>
</div>
{loading && (
<div className="text-sm text-gray-500 dark:text-gray-400">Lade Gefaehrdungen</div>
)}
{!loading && hazards.length === 0 && (
<div className="rounded-xl border border-dashed border-gray-300 dark:border-gray-700 p-6 text-sm text-gray-500">
Keine Gefaehrdungen vorhanden. Bitte zuerst im <strong>Hazard Log</strong> erzeugen.
</div>
)}
<div className="space-y-4">
{hazards.map((h) => (
<RiskModelCard key={h.id} hazard={h} suggestion={suggestions[h.id]} />
))}
</div>
</div>
)
}