优化BasicSelectTree
parent
20f3ff46a9
commit
25371cab89
|
|
@ -51,8 +51,8 @@ function BasicSelectTree(props) {
|
|||
}
|
||||
onGetNodePaths?.(arrayObjectDeduplication(parentNodes, idKey));
|
||||
onGetLabel?.(label);
|
||||
return;
|
||||
}
|
||||
else {
|
||||
const parentNodes = getTreeNodePaths({
|
||||
data: treeData,
|
||||
targetId: value,
|
||||
|
|
@ -63,6 +63,7 @@ function BasicSelectTree(props) {
|
|||
onGetNodePaths?.(parentNodes);
|
||||
onGetLabel?.(parentNodes[parentNodes.length - 1][nameKey]);
|
||||
}
|
||||
}
|
||||
else {
|
||||
onGetNodePaths?.([]);
|
||||
onGetLabel?.("");
|
||||
|
|
|
|||
Loading…
Reference in New Issue