mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
parent
be7e28af5d
commit
44aa1f4a5e
@ -68,6 +68,8 @@
|
||||
}
|
||||
});
|
||||
var candidateNodes = RED.nodes.filterNodes({type:targetType});
|
||||
var candidateNodesCount = 0;
|
||||
|
||||
var search = $("#node-input-link-target-filter").searchBox({
|
||||
style: "compact",
|
||||
delay: 300,
|
||||
@ -80,7 +82,7 @@
|
||||
var count = treeList.treeList("filter", function(item) {
|
||||
return item.label.toLowerCase().indexOf(val) > -1 || (item.node && item.node.type.toLowerCase().indexOf(val) > -1)
|
||||
});
|
||||
search.searchBox("count",count+" / "+candidateNodes.length);
|
||||
search.searchBox("count",count+" / "+candidateNodesCount);
|
||||
}
|
||||
}
|
||||
});
|
||||
@ -113,6 +115,11 @@
|
||||
|
||||
candidateNodes.forEach(function(n) {
|
||||
if (flowMap[n.z]) {
|
||||
if (targetType === "link out" && n.mode === 'return') {
|
||||
// Link In nodes looking for Link Out nodes should not
|
||||
// include return-mode nodes.
|
||||
return
|
||||
}
|
||||
var isChecked = false;
|
||||
isChecked = (node.links.indexOf(n.id) !== -1) || (n.links||[]).indexOf(node.id) !== -1;
|
||||
if (isChecked) {
|
||||
@ -126,6 +133,7 @@
|
||||
checkbox: node.type !== "link call",
|
||||
radio: node.type === "link call"
|
||||
})
|
||||
candidateNodesCount++;
|
||||
}
|
||||
});
|
||||
flows = flows.filter(function(f) { return f.children.length > 0 })
|
||||
|
Loading…
Reference in New Issue
Block a user