多租户商城-商户端
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

14 lines
312 B

/**
* 删除类别中的空 Child
* @param {className} class名称
* @param {tagName} 标签名称
*/
export function checkEmptyChild (arr) {
for (let i = 0; i < arr.length; i++) {
if (arr[i].childs.length === 0) {
arr[i].childs = ''
} else {
checkEmptyChild(arr[i].childs)
}
}
}