fix: When the workflow session variable is not added, the dropdown option does not display the session variable attribute (#3816)

This commit is contained in:
shaohuzhang1 2025-08-05 15:17:32 +08:00 committed by GitHub
parent f668daa902
commit 6ba6ed065e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -53,8 +53,16 @@ function visibleChange(bool: boolean) {
options.value = props.global
? props.nodeModel
.get_up_node_field_list(false, true)
.filter((v: any) => ['global', 'chat'].includes(v.value))
: props.nodeModel.get_up_node_field_list(false, true)
.map((v: any) => {
console.log(v)
return v
})
.filter(
(v: any) => ['global', 'chat'].includes(v.value) && v.children && v.children.length > 0,
)
: props.nodeModel
.get_up_node_field_list(false, true)
.filter((v: any) => v.children && v.children.length > 0)
}
}