Code Format
parent
86de5aafa2
commit
e36cc99976
|
@ -456,7 +456,7 @@ export default {
|
||||||
nodeMap[node.key] = node;
|
nodeMap[node.key] = node;
|
||||||
|
|
||||||
if (node.children?.length) {
|
if (node.children?.length) {
|
||||||
node.children.forEach(children => this.fillNodeMap(children, nodeMap))
|
node.children.forEach((children) => this.fillNodeMap(children, nodeMap));
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
isSelected(node, keys) {
|
isSelected(node, keys) {
|
||||||
|
@ -512,7 +512,7 @@ export default {
|
||||||
nodeMap() {
|
nodeMap() {
|
||||||
const nodeMap = {};
|
const nodeMap = {};
|
||||||
|
|
||||||
this.options?.forEach(node => this.fillNodeMap(node, nodeMap))
|
this.options?.forEach((node) => this.fillNodeMap(node, nodeMap));
|
||||||
|
|
||||||
return nodeMap;
|
return nodeMap;
|
||||||
},
|
},
|
||||||
|
@ -520,13 +520,13 @@ export default {
|
||||||
let selectedNodes = [];
|
let selectedNodes = [];
|
||||||
|
|
||||||
if (this.d_value && this.options) {
|
if (this.d_value && this.options) {
|
||||||
Object.keys(this.d_value).forEach(key => {
|
Object.keys(this.d_value).forEach((key) => {
|
||||||
const node = this.nodeMap[key];
|
const node = this.nodeMap[key];
|
||||||
|
|
||||||
if (this.isSelected(node, this.d_value)) {
|
if (this.isSelected(node, this.d_value)) {
|
||||||
selectedNodes.push(node)
|
selectedNodes.push(node);
|
||||||
}
|
}
|
||||||
})
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
return selectedNodes;
|
return selectedNodes;
|
||||||
|
|
1099
pnpm-lock.yaml
1099
pnpm-lock.yaml
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue