BIM: Fixed copy-paste bug in nativeifc psets - Fixes #18293

This commit is contained in:
Yorik van Havre
2024-12-05 12:37:36 +01:00
committed by Yorik van Havre
parent ba1b3b1cb7
commit 29ea971777

View File

@@ -172,17 +172,17 @@ def edit_pset(obj, prop, value=None, force=False):
ptype = ptype.split(":", 1)[0]
else:
ptype = obj.getTypeIdOfProperty(prop)
if ifcprop == "App::PropertyDistance":
if ptype == "App::PropertyDistance":
ptype = "IfcLengthMeasure"
elif ifcprop == "App::PropertyLength":
elif ptype == "App::PropertyLength":
ptype = "IfcPositiveLengthMeasure"
elif ifcprop == "App::PropertyBool":
elif ptype == "App::PropertyBool":
ptype = "IfcBoolean"
elif ifcprop == "App::PropertyInteger":
elif ptype == "App::PropertyInteger":
ptype = "IfcInteger"
elif ifcprop == "App::PropertyFloat":
elif ptype == "App::PropertyFloat":
ptype = "IfcReal"
elif ifcprop == "App::PropertyArea":
elif ptype == "App::PropertyArea":
ptype = "IfcAreaMeasure"
else:
# default