document.assign_document - support batching #4474

This commit is contained in:
Andrej730
2024-04-15 16:32:54 +05:00
parent 1f605484d9
commit 097f44284f
12 changed files with 91 additions and 51 deletions
@@ -45,7 +45,7 @@ class Usecase:
reference = ifcopenshell.api.run("document.add_reference", model, information=document)
# Let's imagine storey represents an IfcBuildingStorey for the ground floor
ifcopenshell.api.run("document.assign_document", model, product=storey, document=reference)
ifcopenshell.api.run("document.assign_document", model, products=[storey], document=reference)
# Now let's change our mind and remove the association
ifcopenshell.api.run("document.unassign_document", model, product=storey, document=reference)