Function(key, value, parentNode)zTreeObj.getNodesByParamFuzzy

Overview[ depends on jquery.ztree.core js ]

According to the node data attribute, search the nodes which fuzzy matches, and get the JSON objects collection of nodes.

Please use zTree object to executing the method.

Function Parameter Descriptions

keyString

The name of attribute which need to fuzzy match

valueString

The value which need to fuzzy match.

The type of value can only be String

parentNodeJSON

The search range, you can search node from a parent node's child nodes.

If this parameter is omitted, zTree will search node from all nodes.

Return Array(JSON)

The JSON data objects collection of the nodes which be searched.

If search none node, return [ ].

Examples of function

1. Search the nodes which their 'name' attribute contains the string 'test'.

var treeObj = $.fn.zTree.getZTreeObj("tree");
var nodes = treeObj.getNodesByParamFuzzy("name", "test", null);