From 4c61000feaf72e43a03271a4b52e4291e06d1692 Mon Sep 17 00:00:00 2001 From: Claude Date: Wed, 4 Nov 2026 14:46:13 +0000 Subject: [PATCH] =?UTF-8?q?[97][98]=20Objekt-Info:=20Aussenbauteil=20und?= =?UTF-8?q?=20tragend=20f=C3=BCr=20Wand=20und=20Decke?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01NTYBZBvLYCtugMJoKXaB67 --- TODO.md | 2 +- src-tauri/core/src/selection_info.rs | 5 +++++ src/i18n/de.ts | 2 ++ src/i18n/en.ts | 2 ++ src/panels/ObjectInfoPanel.tsx | 18 ++++++++++++++++++ src/panels/host.ts | 2 ++ src/state/selectionInfo.ts | 6 ++++++ src/state/usePanelHostBase.ts | 7 +++++++ 8 files changed, 43 insertions(+), 1 deletion(-) diff --git a/TODO.md b/TODO.md index e30b839a..c162525a 100644 --- a/TODO.md +++ b/TODO.md @@ -1924,7 +1924,7 @@ Reihenfolge = Abhängigkeiten. Neue Geometrie entsteht in Rust ([K]). `Opening.mark/fireRating/soundClass/uValue/burglaryClass/notes/isExternal`, `Wall`/`Ceiling` `isExternal`/ `loadBearing`. Anzeige editierbar in der Flächenbilanz (`OpeningScheduleSection`), Export CSV/SVG/PDF über das Berichtsmodell des Flächennachweises, CLI `schedule --openings [--format json|csv|svg|pdf]`. - Offen: Wand/Decke `isExternal`/`loadBearing` ohne UI (nur über Ops/IFC-Import setzbar; Objekt-Info fehlt); + Wand/Decke `isExternal`/`loadBearing`: 4.11. Häkchen „Aussenbauteil"/„Tragend" im Objekt-Info (ohne eigenen Test); Tabelle als Element auf dem Layout-Blatt ✅ [111]; Typ-Vorgaben (Brand/Schall/U am Tür-/Fenstertyp) fehlen — die Werte liegen je Öffnung; Nummern nicht stabil bei Umordnung (automatisch nach Dokumentreihenfolge); nicht in der Tauri-App getestet. diff --git a/src-tauri/core/src/selection_info.rs b/src-tauri/core/src/selection_info.rs index 717f4790..3fc897fa 100644 --- a/src-tauri/core/src/selection_info.rs +++ b/src-tauri/core/src/selection_info.rs @@ -491,6 +491,9 @@ fn wall_selection(root: &Map, w: &Value) -> Result { // An Dach anschliessen ([G2]): fehlt = automatisch. .v("roofAttach", Value::String(match field(w, "roofAttach").and_then(|v| v.as_bool()) { Some(true) => "on", Some(false) => "off", None => "auto" }.into())) .raw("wallTypeId", w, "wallTypeId") + // Aussenbauteil / tragend ([97]/[98]: Listen, IFC-Pset). + .v("isExternal", Value::Bool(field(w, "isExternal").and_then(Value::as_bool).unwrap_or(false))) + .v("loadBearing", Value::Bool(field(w, "loadBearing").and_then(Value::as_bool).unwrap_or(false))) .n("thickness", thickness) .v("singleLayer", Value::Bool(layers.len() <= 1)) .v("wallTypes", type_choices(root, "wallTypes")) @@ -563,6 +566,8 @@ fn ceiling_selection(root: &Map, c: &Value) -> Result .o("typeId", nn(field(c, "ceilingTypeId")).or(field(c, "wallTypeId")).cloned()) .n("thickness", thickness) .v("singleLayer", Value::Bool(arr(field(wt, "layers")).len() <= 1)) + .v("isExternal", Value::Bool(field(c, "isExternal").and_then(Value::as_bool).unwrap_or(false))) + .v("loadBearing", Value::Bool(field(c, "loadBearing").and_then(Value::as_bool).unwrap_or(false))) .n("area", area) .n("volume", area * thickness) .v("ceilingTypes", type_choices(root, "ceilingTypes")) diff --git a/src/i18n/de.ts b/src/i18n/de.ts index b04ea0f3..f87d1155 100644 --- a/src/i18n/de.ts +++ b/src/i18n/de.ts @@ -552,6 +552,8 @@ export const de = { "objinfo.wall.refLine.joint": "Fuge", "objinfo.wall.sliceTermination": "An Decke enden", "objinfo.wall.roofAttach": "An Dach anschliessen", + "objinfo.isExternal": "Aussenbauteil", + "objinfo.loadBearing": "Tragend", "objinfo.wall.roofAttach.auto": "Automatisch", "objinfo.wall.roofAttach.on": "Ja, bis unters Dach", "objinfo.wall.roofAttach.off": "Nein", diff --git a/src/i18n/en.ts b/src/i18n/en.ts index c9cec84a..85658148 100644 --- a/src/i18n/en.ts +++ b/src/i18n/en.ts @@ -550,6 +550,8 @@ export const en: Record = { "objinfo.wall.refLine.joint": "Joint", "objinfo.wall.sliceTermination": "End at ceiling", "objinfo.wall.roofAttach": "Attach to roof", + "objinfo.isExternal": "External", + "objinfo.loadBearing": "Load-bearing", "objinfo.wall.roofAttach.auto": "Automatic", "objinfo.wall.roofAttach.on": "Yes, up to the roof", "objinfo.wall.roofAttach.off": "No", diff --git a/src/panels/ObjectInfoPanel.tsx b/src/panels/ObjectInfoPanel.tsx index d67bb42c..db18d5e6 100644 --- a/src/panels/ObjectInfoPanel.tsx +++ b/src/panels/ObjectInfoPanel.tsx @@ -1858,6 +1858,22 @@ function SurfaceOpeningSection({ // ── Decken-Attribut-Abschnitt ──────────────────────────────────────────────── // Aufbau-Typ (einschichtig/mehrschichtig), Dicke/Preset, Referenzgeschoss + // OK-Bindung, Fläche. Alle Werte/Setter über den Host. +/** Aussenbauteil / tragend ([97]/[98]): wirken auf Bauteil-/Öffnungslisten und das IFC-Pset. */ +function BuildingFlags({ isExternal, loadBearing, host }: { isExternal: boolean; loadBearing: boolean; host: ReturnType }) { + return ( + <> +
+ {t("objinfo.isExternal")} + host.onSetBuildingFlags({ isExternal: e.target.checked })} /> +
+
+ {t("objinfo.loadBearing")} + host.onSetBuildingFlags({ loadBearing: e.target.checked })} /> +
+ + ); +} + export function CeilingSection({ ceiling, host, @@ -1882,6 +1898,7 @@ export function CeilingSection({ <>
{t("objinfo.ceiling.section")}
+ {/* Aufbau-Typ-Segment. */}
@@ -2099,6 +2116,7 @@ export function WallSection({ width={120} />
+ {/* Aufbau-Typ-Segment. */}
diff --git a/src/panels/host.ts b/src/panels/host.ts index c4189d37..4673f98e 100644 --- a/src/panels/host.ts +++ b/src/panels/host.ts @@ -419,6 +419,8 @@ export interface PanelHostValue { onSetWallSliceTermination: (termination: SliceTermination) => void; /** An Dach anschliessen ([G2]): "auto" = Default (Wand endet an der Dach-Unterkante). */ onSetWallRoofAttach: (attach: "auto" | "on" | "off") => void; + /** Aussenbauteil/tragend der gewählten Wand bzw. Decke ([97]/[98]); `false` = Feld weg. */ + onSetBuildingFlags: (flags: { isExternal?: boolean; loadBearing?: boolean }) => void; /** Ansichtsschraffur ([100]) an der gewählten Wand bzw. am gewählten Dach drehen/versetzen. */ onSetSurfacePatternPlacement?: (patch: { surfacePatternAngle?: number; surfacePatternOffset?: { x: number; y: number } }) => void; /** Weist der Wand einen Wandtyp-Preset (mehrschichtiger Aufbau) zu. */ diff --git a/src/state/selectionInfo.ts b/src/state/selectionInfo.ts index 532256a5..322f210a 100644 --- a/src/state/selectionInfo.ts +++ b/src/state/selectionInfo.ts @@ -126,6 +126,9 @@ export interface WallInfo { sliceTermination: SliceTermination; /** An Dach anschliessen ([G2]): "auto" (Default), "on" (bis unter das Dach verlängern), "off". */ roofAttach: "auto" | "on" | "off"; + /** Aussenbauteil / tragend ([97]/[98]). */ + isExternal: boolean; + loadBearing: boolean; wallTypeId: string; /** Aktuelle Gesamtdicke (Meter). */ thickness: number; @@ -164,6 +167,9 @@ export interface WallInfo { export interface CeilingInfo { /** Effektiv aktiver Aufbau-Typ: `ceilingTypeId`, sonst LEGACY-`wallTypeId`. */ typeId: string; + /** Aussenbauteil / tragend ([97]/[98]). */ + isExternal: boolean; + loadBearing: boolean; /** Aktuelle Gesamtdicke (Meter). */ thickness: number; /** Ob der aktuelle Aufbau-Typ einschichtig ist (1 Schicht). */ diff --git a/src/state/usePanelHostBase.ts b/src/state/usePanelHostBase.ts index b2b78a1a..ab103798 100644 --- a/src/state/usePanelHostBase.ts +++ b/src/state/usePanelHostBase.ts @@ -825,6 +825,13 @@ export function usePanelHostBase(opts: { // "auto" ist der Default ⇒ als undefined speichern. updateWall(selection.id, { roofAttach: attach === "auto" ? undefined : attach === "on" }); }, + onSetBuildingFlags: (flags) => { + const patch: { isExternal?: boolean; loadBearing?: boolean } = {}; + if (flags.isExternal !== undefined) patch.isExternal = flags.isExternal || undefined; + if (flags.loadBearing !== undefined) patch.loadBearing = flags.loadBearing || undefined; + if (selection?.kind === "wall") updateWall(selection.id, patch); + else if (selection?.kind === "ceiling") updateCeiling(selection.id, patch); + }, onSetWallType: (wallTypeId) => { if (selection?.kind === "wall") updateWall(selection.id, { wallTypeId });