mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-10 19:36:43 +08:00
课程多选,查询问题
This commit is contained in:
@@ -902,6 +902,31 @@ export default {
|
|||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
getAllChecked(){ //获取全部选中的标签
|
||||||
|
let list=[];
|
||||||
|
|
||||||
|
this.ctypeList.forEach(item=>{
|
||||||
|
if(item.checked){
|
||||||
|
list.push(item);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
this.oneList.forEach(one=>{
|
||||||
|
one.children.forEach(two=>{
|
||||||
|
two.children.forEach(three=>{
|
||||||
|
if(three.checked){
|
||||||
|
list.push(three);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
if(two.checked ){
|
||||||
|
list.push(two);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
if(one.checked){
|
||||||
|
list.push(one);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
return list;
|
||||||
|
},
|
||||||
async search() {
|
async search() {
|
||||||
//测试时间格式化
|
//测试时间格式化
|
||||||
// let s=1650973801;
|
// let s=1650973801;
|
||||||
@@ -924,11 +949,8 @@ export default {
|
|||||||
this.course.sysType2 = "";
|
this.course.sysType2 = "";
|
||||||
this.course.sysType3 = "";
|
this.course.sysType3 = "";
|
||||||
this.course.keyword=this.keyword;
|
this.course.keyword=this.keyword;
|
||||||
|
let allChecked=this.getAllChecked();
|
||||||
this.stagList.forEach(item=>{
|
allChecked.forEach(item=>{
|
||||||
if(item.checked){
|
|
||||||
|
|
||||||
}
|
|
||||||
if(item.type==1){
|
if(item.type==1){
|
||||||
if(that.course.types){ that.course.types+='-'; }
|
if(that.course.types){ that.course.types+='-'; }
|
||||||
that.course.types+=item.id;
|
that.course.types+=item.id;
|
||||||
|
|||||||
Reference in New Issue
Block a user