This commit is contained in:
zyl
2025-12-17 18:14:54 +08:00
parent 9be0b68537
commit fc7c6e1c02
13 changed files with 78 additions and 29 deletions

View File

@ -50,6 +50,7 @@ window.newFuzzySearch = function (
allNodes = res
return allNodes
}
/*let allNodes = zTreeObj.transformToArray(nodes);
let nodeChildren = getCustomNodes(allNodes)*/
// console.log("nodeChildren", nodeChildren)
@ -84,7 +85,7 @@ window.newFuzzySearch = function (
zTreeObj.updateNode(item)
}
if (contrast) {
if (((item.sourceName || '')+'').indexOf(contrast) > -1) {
if (((item.sourceName || '') + '').indexOf(contrast) > -1) {
console.log('sourceName包含关键字')
console.log(item)
console.log(item.sourceName)
@ -97,6 +98,7 @@ window.newFuzzySearch = function (
return str
})
item.title = item.oldname.replace(F, function (h) {
// console.log("h", F, h)
let str = h
return str
})
@ -130,9 +132,9 @@ window.newFuzzySearch = function (
function showNodePath(node) {
let parrentNodes = node.getPath()
parrentNodes &&
parrentNodes.forEach(function (node) {
zTreeObj.showNode(node)
})
parrentNodes.forEach(function (node) {
zTreeObj.showNode(node)
})
}
window.treeSearchCb = (value = undefined) => {