mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-08-17 10:59:17 +00:00
profile.add_parameterized_profile - add profile_type arg
To create more valid profiles by default. Noticed then Bonsai creates new profiles, it doesn't set ProfileType, leading to validation errors.
This commit is contained in:
@@ -223,6 +223,7 @@ class Profile(bonsai.core.tool.Profile):
|
||||
"""Set default profile attributes to keep profile valid."""
|
||||
class_match = False
|
||||
si_conversion = ifcopenshell.util.unit.calculate_unit_scale(tool.Ifc.get())
|
||||
# We're using for-loop as classes may not match exactly.
|
||||
for ifc_class, params in cls.DEFAULT_PROFILE_ATTRS.items():
|
||||
if profile.is_a(ifc_class):
|
||||
class_match = True
|
||||
|
||||
Reference in New Issue
Block a user