bonsai bcf - fix bim snippet ui issue

schema is optional field in bcf v2 and it was unreliable to use it to detect whether bim snippet is present or not
This commit is contained in:
Andrej730
2024-08-19 17:07:05 +05:00
parent 8a55f18c95
commit 1de51ecf77
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -203,7 +203,7 @@ class BCFProperties(PropertyGroup):
label: StringProperty(
default="", name="Label", search=lambda s, c, t: get_extensions_items(s, c, t, extensions_attr="topic_labels")
)
bim_snippet_reference: StringProperty(default="", name="Reference")
bim_snippet_reference: StringProperty(default="", name="Reference", description="URI or filepath to BimSnippet")
bim_snippet_type: StringProperty(
default="", name="Type", search=lambda s, c, t: get_extensions_items(s, c, t, extensions_attr="snippet_types")
)
+1 -1
View File
@@ -203,7 +203,7 @@ class BIM_PT_bcf_metadata(Panel):
row.operator("bim.add_bcf_label")
layout.label(text="BIM Snippet:")
if topic.bim_snippet.schema:
if topic.bim_snippet.reference:
row = layout.row(align=True)
row.prop(topic.bim_snippet, "type", emboss=False)
if topic.bim_snippet.schema: