mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-19 22:50:21 +00:00
Fix #5839. Appending an asset now also considers shape aspects.
This commit is contained in:
@@ -261,7 +261,10 @@ class Usecase:
|
|||||||
self.base_material_class: ["HasExternalReferences", "HasProperties", "HasRepresentation"],
|
self.base_material_class: ["HasExternalReferences", "HasProperties", "HasRepresentation"],
|
||||||
"IfcRepresentationItem": ["StyledByItem", "LayerAssignment"],
|
"IfcRepresentationItem": ["StyledByItem", "LayerAssignment"],
|
||||||
"IfcRepresentation": ["LayerAssignments"],
|
"IfcRepresentation": ["LayerAssignments"],
|
||||||
|
"IfcProductDefinitionShape": ["HasShapeAspects"],
|
||||||
|
"IfcRepresentationMap": ["HasShapeAspects"],
|
||||||
}
|
}
|
||||||
|
print('appending type product!')
|
||||||
self.existing_contexts = self.file.by_type("IfcGeometricRepresentationContext")
|
self.existing_contexts = self.file.by_type("IfcGeometricRepresentationContext")
|
||||||
element = self.add_element(self.settings["element"])
|
element = self.add_element(self.settings["element"])
|
||||||
self.reuse_existing_contexts()
|
self.reuse_existing_contexts()
|
||||||
@@ -278,6 +281,8 @@ class Usecase:
|
|||||||
"LayerAssignments" if self.file.schema == "IFC2X3" else "LayerAssignment",
|
"LayerAssignments" if self.file.schema == "IFC2X3" else "LayerAssignment",
|
||||||
],
|
],
|
||||||
"IfcRepresentation": ["LayerAssignments"],
|
"IfcRepresentation": ["LayerAssignments"],
|
||||||
|
"IfcProductDefinitionShape": ["HasShapeAspects"],
|
||||||
|
"IfcRepresentationMap": ["HasShapeAspects"],
|
||||||
}
|
}
|
||||||
self.existing_contexts = self.file.by_type("IfcGeometricRepresentationContext")
|
self.existing_contexts = self.file.by_type("IfcGeometricRepresentationContext")
|
||||||
element = self.add_element(self.settings["element"])
|
element = self.add_element(self.settings["element"])
|
||||||
|
|||||||
Reference in New Issue
Block a user