|
@@ -1070,7 +1070,8 @@ export default {
|
|
|
}
|
|
|
this.examData = res.data.data;
|
|
|
this.allTimes = this.examData.answerTime * 60;
|
|
|
- this.lastTime = this.examData.answerTime && this.examData.answerTime * 60;
|
|
|
+ this.lastTime =
|
|
|
+ this.examData.answerTime && this.examData.answerTime * 60;
|
|
|
if (this.bankType == 2) {
|
|
|
this.needBack = true;
|
|
|
}
|
|
@@ -1622,8 +1623,6 @@ export default {
|
|
|
* @param {Object} 多选确认
|
|
|
*/
|
|
|
checkboxSubmit(bindex) {
|
|
|
- // console.log('')
|
|
|
- // if (this.questionList[bindex].ques) return;
|
|
|
if (this.questionList[bindex].ques && this.bankType == 1) {
|
|
|
return;
|
|
|
}
|
|
@@ -1646,36 +1645,16 @@ export default {
|
|
|
this.$set(this.questionList[bindex], "ques", arr);
|
|
|
this.$u.toast("已确认答案");
|
|
|
this.isDoOver();
|
|
|
-
|
|
|
- // let isWrong = this.questionList[bindex].ques.some((item, i) => {
|
|
|
- // return this.questionList[bindex].ans.indexOf(item) == -1;
|
|
|
- // })
|
|
|
- // // 回答错误
|
|
|
- // if (isWrong) {
|
|
|
- // this.$api
|
|
|
- // .examWrongRecord({
|
|
|
- // orderGoodsId: this.orderGoodsId,
|
|
|
- // examId: this.id,
|
|
|
- // goodsId: this.goodsId,
|
|
|
- // moduleExamId: this.moduleId || 0,
|
|
|
- // chapterExamId: this.chapterId || 0,
|
|
|
- // questionIds: [this.questionList[bindex].questionId],
|
|
|
- // recordId: this.recordId,
|
|
|
- // })
|
|
|
- // .then((res) => {});
|
|
|
- // } else {
|
|
|
- // // let question = this.wrongList.find(item => item.questionId == this.questionList[bindex].questionId);
|
|
|
- // // if(question) {
|
|
|
- // // this.$api.wrongRecordDelete({
|
|
|
- // // "examId": +this.id,
|
|
|
- // // "goodsId": +this.goodsId,
|
|
|
- // // "questionId": this.questionList[bindex].questionId,
|
|
|
- // // }).then(res => {
|
|
|
- // // })
|
|
|
- // // }
|
|
|
- // }
|
|
|
+ // 切换下一题
|
|
|
+ if (
|
|
|
+ this.bankType != 1 &&
|
|
|
+ this.cgType != 9 &&
|
|
|
+ bindex != this.questionList.length - 1
|
|
|
+ ) {
|
|
|
+ this.current = bindex + 1;
|
|
|
+ this.getCollectInfo(this.current);
|
|
|
+ }
|
|
|
},
|
|
|
-
|
|
|
/**
|
|
|
* @param {Object} 案例多选确认
|
|
|
*/
|
|
@@ -1705,6 +1684,14 @@ export default {
|
|
|
this.$set(this.questionList[bindex].ques, ansIndex, arr);
|
|
|
this.$u.toast("已确认答案");
|
|
|
this.isDoOver();
|
|
|
+ // 切换下一题
|
|
|
+ if (
|
|
|
+ this.bankType != 1 &&
|
|
|
+ this.cgType != 9 &&
|
|
|
+ ansIndex != this.questionList[bindex].ques.length - 1
|
|
|
+ ) {
|
|
|
+ this.questionList[bindex].current += 1;
|
|
|
+ }
|
|
|
},
|
|
|
|
|
|
/**
|
|
@@ -2205,7 +2192,12 @@ export default {
|
|
|
this.isDoOver();
|
|
|
},
|
|
|
isCheck(item, index) {
|
|
|
- if (this.questionList[index].ques) {
|
|
|
+ // 案例题处理
|
|
|
+ let { ques, type, ans } = item;
|
|
|
+ if (type == 4) {
|
|
|
+ return ans.length == ques.length;
|
|
|
+ }
|
|
|
+ if (ques) {
|
|
|
return true;
|
|
|
}
|
|
|
},
|