mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-mobile.git
synced 2025-12-09 02:46:46 +08:00
提交修改
This commit is contained in:
@@ -94,9 +94,11 @@
|
||||
this.loadRecord();
|
||||
},
|
||||
watch:{
|
||||
studyId(newVal){
|
||||
content(newObj){
|
||||
this.loadExamInfo();
|
||||
this.loadRecord();
|
||||
}
|
||||
},
|
||||
deep:true
|
||||
},
|
||||
methods: {
|
||||
loadExamInfo(){
|
||||
@@ -125,24 +127,25 @@
|
||||
if(this.studyId==''){
|
||||
return;
|
||||
}
|
||||
this.loadExamContent();
|
||||
if(this.records.length==0){
|
||||
let params={
|
||||
studyId:this.studyId,
|
||||
contentId:this.content.id
|
||||
}
|
||||
apiStudy.myExamList2(params).then(examRs=>{
|
||||
if(examRs.status==200){
|
||||
this.records=examRs.result;
|
||||
let len=examRs.result.length;
|
||||
if(this.info.times>len){
|
||||
this.allowSubmit=true;
|
||||
}else{
|
||||
this.allowSubmit=false;
|
||||
this.records=[];
|
||||
this.loadExamContent();
|
||||
//if(this.records.length==0){
|
||||
let params={
|
||||
studyId:this.studyId,
|
||||
contentId:this.content.id
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
apiStudy.myExamList2(params).then(examRs=>{
|
||||
if(examRs.status==200){
|
||||
this.records=examRs.result;
|
||||
let len=examRs.result.length;
|
||||
if(this.info.times>len){
|
||||
this.allowSubmit=true;
|
||||
}else{
|
||||
this.allowSubmit=false;
|
||||
}
|
||||
}
|
||||
})
|
||||
//}
|
||||
},
|
||||
startTest(){
|
||||
//转向详细页面
|
||||
|
||||
@@ -92,14 +92,12 @@
|
||||
this.loadHomeworkInfo();
|
||||
},
|
||||
watch:{
|
||||
studyId(newVal){
|
||||
this.loadHomeworkInfo();
|
||||
},
|
||||
content(newVal,oldVal){
|
||||
if(newVal.id!=oldVal.id){
|
||||
this.loadHomeworkInfo();
|
||||
}
|
||||
}
|
||||
},
|
||||
deep:true
|
||||
},
|
||||
methods: {
|
||||
loadHomeworkInfo(){
|
||||
|
||||
Reference in New Issue
Block a user