点线标注
This commit is contained in:
@ -23,7 +23,7 @@ window.newFuzzySearch = function(
|
||||
let notSearchTypeNodesIds = [];
|
||||
if (notSearchType.length) {
|
||||
allNodes.forEach((allNodeItem) => {
|
||||
if (notSearchType.includes(allNodeItem.source_type)) {
|
||||
if (notSearchType.includes(allNodeItem.sourceType)) {
|
||||
notSearchTypeNodesIds.push(allNodeItem[idKey]);
|
||||
}
|
||||
});
|
||||
@ -81,19 +81,19 @@ window.newFuzzySearch = function(
|
||||
hideAllNode(allNodes);
|
||||
nodeChildren.forEach((item) => {
|
||||
if (item.oldname) {
|
||||
item.source_name = item.oldname;
|
||||
item.sourceName = item.oldname;
|
||||
zTreeObj.updateNode(item);
|
||||
}
|
||||
if (contrast) {
|
||||
if ((item.source_name || "").indexOf(contrast) > -1) {
|
||||
console.log("source_name包含关键字");
|
||||
if ((item.sourceName || "").indexOf(contrast) > -1) {
|
||||
console.log("sourceName包含关键字");
|
||||
console.log(item);
|
||||
console.log(item.source_name);
|
||||
console.log(item.sourceName);
|
||||
|
||||
item.oldname = item.source_name;
|
||||
item.oldname = item.sourceName;
|
||||
item.highlight = true;
|
||||
let F = new RegExp(contrast, "gi");
|
||||
item.source_name = item.oldname.replace(F, function(h) {
|
||||
item.sourceName = item.oldname.replace(F, function(h) {
|
||||
let str =
|
||||
'<span style="color: whitesmoke;background-color: darkred;">' +
|
||||
h +
|
||||
|
||||
Reference in New Issue
Block a user