mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-25 17:57:02 +00:00
Hide list attributes from attributes UI
As they're more internal and not very useful to users. Example of list attributes popping up before this commit - https://i.imgur.com/Nxcb10O.png
This commit is contained in:
@@ -44,8 +44,10 @@ class AttributesData:
|
|||||||
excluded_keys = ["id", "type"]
|
excluded_keys = ["id", "type"]
|
||||||
else:
|
else:
|
||||||
excluded_keys = ["type"]
|
excluded_keys = ["type"]
|
||||||
|
# Same types also filtered by `import_attribute`.
|
||||||
|
exclude_value_types = (tuple, ifcopenshell.entity_instance)
|
||||||
for key, value in data.items():
|
for key, value in data.items():
|
||||||
if value is None or isinstance(value, ifcopenshell.entity_instance) or key in excluded_keys:
|
if value is None or isinstance(value, exclude_value_types) or key in excluded_keys:
|
||||||
continue
|
continue
|
||||||
if key == "id":
|
if key == "id":
|
||||||
key = "STEP ID"
|
key = "STEP ID"
|
||||||
|
|||||||
Reference in New Issue
Block a user