暂存
This commit is contained in:
@@ -133,6 +133,7 @@
|
||||
|
||||
<script>
|
||||
import $http from '@/config/requestConfig.js';
|
||||
import debounce from "@/common/debounce.js";
|
||||
import {
|
||||
mapState,mapMutations
|
||||
} from "vuex";
|
||||
@@ -207,17 +208,19 @@
|
||||
})
|
||||
},
|
||||
onHandleClickBuy(){ // 确定开始考试
|
||||
this.protocolShow = false
|
||||
if (this.testPaper.length <= 0) {
|
||||
this.pagetitle = '获取试卷'
|
||||
this.getTestPage()
|
||||
}else{
|
||||
uni.showToast({
|
||||
title:'页面发生错误,请退出后重新进入页面或联系客服人员',
|
||||
icon:'none',
|
||||
duration:3000
|
||||
})
|
||||
}
|
||||
debounce(async () => {
|
||||
this.protocolShow = false
|
||||
if (this.testPaper.length <= 0) {
|
||||
this.pagetitle = '获取试卷'
|
||||
this.getTestPage()
|
||||
}else{
|
||||
uni.showToast({
|
||||
title:'页面发生错误,请退出后重新进入页面或联系客服人员',
|
||||
icon:'none',
|
||||
duration:3000
|
||||
})
|
||||
}
|
||||
},300)
|
||||
},
|
||||
// 获取服务器时间
|
||||
async getServerTime() {
|
||||
@@ -327,6 +330,7 @@
|
||||
},
|
||||
// 获取交卷数据
|
||||
sumitAnswer() {
|
||||
debounce(async () => {
|
||||
let that = this
|
||||
// this.noAnswerList = await this.getNoAnswerList()
|
||||
if(this.noAnswerList.length > 0){
|
||||
@@ -345,10 +349,13 @@
|
||||
}else{
|
||||
that.sumbitPaper()
|
||||
}
|
||||
|
||||
},300)
|
||||
},
|
||||
// q请求提交试卷
|
||||
sumbitPaper(ids) {
|
||||
uni.showLoading({
|
||||
title:'正在交卷'
|
||||
})
|
||||
let that = this
|
||||
$http.request({
|
||||
url: "common/classExam/submitExamPaper",
|
||||
@@ -416,6 +423,7 @@
|
||||
this.haveAnswerList = this.gethaveAnswerList()
|
||||
},
|
||||
showNextQuestion() {
|
||||
debounce(async () => {
|
||||
// 下一题
|
||||
this.curIndex1++
|
||||
// this.curQuestion.answerIds = []
|
||||
@@ -426,8 +434,10 @@
|
||||
// console.log('+++++++++++++++', this.testPaper, );
|
||||
this.noAnswerList = this.getNoAnswerList()
|
||||
this.haveAnswerList = this.gethaveAnswerList()
|
||||
},300)
|
||||
},
|
||||
clickOption(item, index) {
|
||||
// debounce(async () => {
|
||||
console.log('item', item, index, this.curIndex1);
|
||||
if (this.curQuestion.type == 0) {
|
||||
this.testPaper[this.curIndex1].answerIds = [item.id]
|
||||
@@ -454,6 +464,7 @@
|
||||
console.log('this.testPaper.',this.testPaper.id);
|
||||
this.saveQuestAnswer(this.examId,this.curIndex1+1,this.curQuestion.answerIds.join(','))
|
||||
console.log('noAnswerList', this.noAnswerList)
|
||||
// },300)
|
||||
},
|
||||
setDesc() {
|
||||
const letterArr = []
|
||||
@@ -549,6 +560,9 @@
|
||||
icon: 'none',
|
||||
duration: 3000
|
||||
})
|
||||
setTimeout(()=>{
|
||||
this.goToClass()
|
||||
},1000)
|
||||
});
|
||||
},
|
||||
giveZero() {
|
||||
|
||||
Reference in New Issue
Block a user