mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-26 10:11:46 +00:00
Fix #3403. Templates must be specific to the version you are creating.
This commit is contained in:
@@ -31,6 +31,8 @@ class Project(blenderbim.core.tool.Project):
|
|||||||
# TODO refactor
|
# TODO refactor
|
||||||
filepath = os.path.join(bpy.context.scene.BIMProperties.data_dir, "libraries", template)
|
filepath = os.path.join(bpy.context.scene.BIMProperties.data_dir, "libraries", template)
|
||||||
bpy.ops.bim.select_library_file(filepath=filepath)
|
bpy.ops.bim.select_library_file(filepath=filepath)
|
||||||
|
if IfcStore.library_file.schema != tool.Ifc.get().schema:
|
||||||
|
return
|
||||||
for element in IfcStore.library_file.by_type("IfcTypeProduct"):
|
for element in IfcStore.library_file.by_type("IfcTypeProduct"):
|
||||||
bpy.ops.bim.append_library_element(definition=element.id())
|
bpy.ops.bim.append_library_element(definition=element.id())
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user