tree组件 开启搜索 搜索不到字节点继续搜索 js会报错 导致程序都无法运行 即使删除搜索词也无法恢复树菜单
Brolly0204 opened this issue · 3 comments
Brolly0204 commented
- I have searched the issues of this repository and believe that this is not a duplicate.
Version
3.2.20
Environment
vue 3.3.x
Reproduction link
https://3x.antdv.com/components/tree-cn
Steps to reproduce
tree组件中进行搜索
What is expected?
即使搜索不到 继续输入 也不应该报错 不会导致应用无法运行, 程序也能继续运行
What is actually happening?
导致程序都无法运行 即使删除搜索词也无法恢复树菜单,更新vue到3.4.x不会报错,但是vue3.4.x中 ant desing vue modal组件会有无法关闭bug
treeUtil.js:322 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'parent')
at getTreeNodeProps (treeUtil.js:322:1)
at ReactiveEffect.eval [as fn] (TreeNode.js:49:1)
at ReactiveEffect.run (reactivity.esm-bundler.js:178:1)
at get value (reactivity.esm-bundler.js:1140:1)
at eval (TreeNode.js:62:1)
at Object.flush (eagerComputed.js:5:1)
这一行代码报错 parent: entity.parent,
var treeNodeProps = {
eventKey: key,
expanded: expandedKeysSet.has(key),
selected: selectedKeysSet.has(key),
loaded: loadedKeysSet.has(key),
loading: loadingKeysSet.has(key),
checked: checkedKeysSet.has(key),
halfChecked: halfCheckedKeysSet.has(key),
pos: String(entity ? entity.pos : ''),
parent: entity.parent, // 报错
TypeError: Cannot read properties of undefined (reading 'parent')
shiwanjun1995 commented
I have the same problem,would you fix it as soon as possible?
@selicens