|
|
@ -500,17 +500,17 @@ |
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
traversal: function (array, callback) { |
|
|
|
traversal: function (array, callback, pNode) { |
|
|
|
if (BI.isNull(array)) { |
|
|
|
if (BI.isNull(array)) { |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
var self = this; |
|
|
|
var self = this; |
|
|
|
BI.some(array, function (i, item) { |
|
|
|
BI.some(array, function (i, item) { |
|
|
|
if (callback(i, item) === false) { |
|
|
|
if (callback(i, item, pNode) === false) { |
|
|
|
return true; |
|
|
|
return true; |
|
|
|
} |
|
|
|
} |
|
|
|
self.traversal(item.children, callback); |
|
|
|
self.traversal(item.children, callback, item); |
|
|
|
}); |
|
|
|
}); |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|
}); |
|
|
|
})(); |
|
|
|
})(); |
|
|
|