持续测试优化

This commit is contained in:
2023-04-04 18:21:45 +08:00
parent a3c4468ee9
commit ae7e71da1c
5 changed files with 115 additions and 25 deletions

View File

@@ -13,6 +13,27 @@ const custom = {
}
return arr
},
get_course_category_name(data,subject_id){ // 根据id 获取名称
let name = ''
if(!data || !subject_id) {
return ''
}
for(let i = 0;i<data.length;i++) {
if(name){
return name
}
else{
if(data[i].id == subject_id ) {
name = data[i].name
break
}
else if(data[i].children){
name = custom.get_course_category_name(data[i].children,subject_id)
}
}
}
return name
},
getExercisesTypeList() {
return [
{