root.remove_product to remove IfcRelFlowControlElements

This commit is contained in:
Andrej730
2023-11-10 12:10:22 +05:00
parent 46e70c92c5
commit c26988b292
2 changed files with 47 additions and 0 deletions
@@ -167,4 +167,9 @@ class Usecase:
self.file.remove(inverse)
elif len(inverse.RelatedObjects) == 1:
self.file.remove(inverse)
elif inverse.is_a("IfcRelFlowControlElements"):
if inverse.RelatingFlowElement == self.settings["product"]:
self.file.remove(inverse)
elif inverse.RelatedControlElements == (self.settings["product"],):
self.file.remove(inverse)
self.file.remove(self.settings["product"])