WIP owner model now records ADDED state for creating products. New feature. See #1222.

This commit is contained in:
Dion Moult
2021-01-26 13:56:38 +11:00
parent 1023c8bc1c
commit fa7353c923
7 changed files with 147 additions and 14 deletions
@@ -5,6 +5,7 @@ import ifcopenshell.util.schema
import blenderbim.bim.module.root.create_product as create_product
import blenderbim.bim.module.root.remove_product as remove_product
import blenderbim.bim.module.root.reassign_class as reassign_class
from blenderbim.bim.module.owner.api import create_owner_history
from blenderbim.bim.ifc import IfcStore
@@ -104,6 +105,7 @@ class AssignClass(bpy.types.Operator):
"ifc_class": self.ifc_class,
"predefined_type": self.predefined_type,
"name": obj.name,
"OwnerHistory": create_owner_history()
},
).execute()
obj.name = "{}/{}".format(product.is_a(), obj.name)