function getSubMenu(menuid, param, subTree) {
var arrg = [];
for (var i = 0; i < param.length; i++) {
if (param[i].parentid = menuid) {
arrg.push(param[i]);
subTree.add(param[i].MenuID, param[i].ParentID, param[i].MenuName, "javaScript:onClickTreeNode('" + param[i].MenuUrl + "','" + param[i].MenuName + "','" + param[i].PhotoPath + "');", param[i].MenuName);
param.remove(i);
getSubMenu(param[i].menuid, param)
}
else {
break;
}
}
return subTree;
}