mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-16 10:34:31 +00:00
Minor fix
This commit is contained in:
@@ -270,6 +270,8 @@ class CreateDrawing(bpy.types.Operator):
|
||||
if obj == self.camera:
|
||||
continue
|
||||
element = self.file.by_id(obj.BIMObjectProperties.ifc_definition_id)
|
||||
if element.is_a("IfcTypeProduct"):
|
||||
continue
|
||||
representation = ifcopenshell.util.representation.get_representation(
|
||||
element, "Plan", "Annotation", self.camera.data.BIMCameraProperties.target_view
|
||||
)
|
||||
|
||||
@@ -154,13 +154,14 @@ class AddRepresentation(bpy.types.Operator):
|
||||
obj.data = mesh
|
||||
Data.load(IfcStore.get_file(), obj.BIMObjectProperties.ifc_definition_id)
|
||||
|
||||
if self.file.schema == "IFC2X3":
|
||||
types = product.ObjectTypeOf
|
||||
else:
|
||||
types = product.Types
|
||||
if product.is_a("IfcTypeProduct") and types:
|
||||
for element in types[0].RelatedObjects:
|
||||
Data.load(IfcStore.get_file(), element.id())
|
||||
if product.is_a("IfcTypeProduct"):
|
||||
if self.file.schema == "IFC2X3":
|
||||
types = product.ObjectTypeOf
|
||||
else:
|
||||
types = product.Types
|
||||
if types:
|
||||
for element in types[0].RelatedObjects:
|
||||
Data.load(IfcStore.get_file(), element.id())
|
||||
return {"FINISHED"}
|
||||
|
||||
|
||||
|
||||
@@ -116,7 +116,7 @@ class VIEW3D_MT_PIE_bim(bpy.types.Menu):
|
||||
def draw(self, context):
|
||||
pie = self.layout.menu_pie()
|
||||
pie.operator("bim.edit_object_placement")
|
||||
pie.operator("bim.update_mesh_representation")
|
||||
pie.operator("bim.update_representation")
|
||||
pie.operator("bim.pie_add_opening")
|
||||
pie.operator("bim.pie_update_container")
|
||||
pie.operator("bim.open_pie_class", text="Assign IFC Class")
|
||||
|
||||
Reference in New Issue
Block a user