material.unassign_material - support batching #4474

This commit is contained in:
Andrej730
2024-04-12 16:15:14 +05:00
parent 59cc9c0a16
commit eb46de9658
9 changed files with 181 additions and 86 deletions
@@ -126,7 +126,7 @@ class Usecase:
pset=inverse.RelatingPropertyDefinition,
)
elif inverse.is_a("IfcRelAssociatesMaterial"):
ifcopenshell.api.run("material.unassign_material", self.file, product=self.settings["product"])
ifcopenshell.api.run("material.unassign_material", self.file, products=[self.settings["product"]])
elif inverse.is_a("IfcRelDefinesByType"):
if inverse.RelatingType == self.settings["product"]:
ifcopenshell.api.run("type.unassign_type", self.file, related_objects=inverse.RelatedObjects)