mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-09 17:31:45 +00:00
Fix #7331: derive cost item quantities from IfcSpace base quantities
assign_cost_item_quantity skipped every IfcSpatialElement, which also
swallowed IfcSpace. Spaces are legitimate quantifiable objects, so their
Qto_SpaceBaseQuantities (for example GrossFloorArea) were never picked up
and count based cost items fell back to 0. Keep skipping spatial
containers (site, building, storey) but allow IfcSpace.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
(cherry picked from commit e23142d01a)
This commit is contained in:
committed by
Dion Moult
parent
3f42e02cb4
commit
0bac7f5542
@@ -137,7 +137,7 @@ class Usecase:
|
||||
if self.prop_name or formula:
|
||||
self.quantities = set(cost_item.CostQuantities or [])
|
||||
for product in products:
|
||||
if product.is_a("IfcSpatialElement"):
|
||||
if product.is_a("IfcSpatialElement") and not product.is_a("IfcSpace"):
|
||||
continue
|
||||
ifcopenshell.api.control.assign_control(
|
||||
self.file,
|
||||
|
||||
Reference in New Issue
Block a user