|
@@ -141,6 +141,7 @@
|
|
|
import {
|
|
import {
|
|
|
examUserCoursewareLearningRestart,examElLabEduRelationAcademicYearProgress,
|
|
examUserCoursewareLearningRestart,examElLabEduRelationAcademicYearProgress,
|
|
|
examUserExamStudyTaskList,examUserExamStart,examUserPracticeSummary,
|
|
examUserExamStudyTaskList,examUserExamStart,examUserPracticeSummary,
|
|
|
|
|
+ examUserExamCommitmentConfirm,
|
|
|
} from "@/api/safetyEducationExaminationNew/index";
|
|
} from "@/api/safetyEducationExaminationNew/index";
|
|
|
import richTextPdf from '@/views/safetyEducationExaminationNew/components/richTextPdf.vue';
|
|
import richTextPdf from '@/views/safetyEducationExaminationNew/components/richTextPdf.vue';
|
|
|
export default {
|
|
export default {
|
|
@@ -188,35 +189,44 @@ export default {
|
|
|
//确认承诺-并考试
|
|
//确认承诺-并考试
|
|
|
examUserExamStart(){
|
|
examUserExamStart(){
|
|
|
if(this.preData.attemptId){
|
|
if(this.preData.attemptId){
|
|
|
- this.$router.push({
|
|
|
|
|
- path: '/startTheExam',
|
|
|
|
|
- query: {
|
|
|
|
|
- attemptId: this.preData.attemptId,
|
|
|
|
|
- type: '1',
|
|
|
|
|
- examKind:this.preData.examKind,
|
|
|
|
|
- }
|
|
|
|
|
- })
|
|
|
|
|
|
|
+ this.examUserExamCommitmentConfirm(1,this.preData.attemptId);
|
|
|
}else{
|
|
}else{
|
|
|
examUserExamStart({examId:this.preData.examId,examScene:1,}).then(response => {
|
|
examUserExamStart({examId:this.preData.examId,examScene:1,}).then(response => {
|
|
|
if(response.data.attemptId){
|
|
if(response.data.attemptId){
|
|
|
- this.$router.push({
|
|
|
|
|
- path: '/startTheExam',
|
|
|
|
|
- query: {
|
|
|
|
|
- examId: this.preData.examId,
|
|
|
|
|
- attemptId: response.data.attemptId,
|
|
|
|
|
- type: '1',
|
|
|
|
|
- examKind:this.preData.examKind,
|
|
|
|
|
- }
|
|
|
|
|
- })
|
|
|
|
|
|
|
+ this.examUserExamCommitmentConfirm(2,response.data.attemptId);
|
|
|
}else{
|
|
}else{
|
|
|
this.msgError(response.message)
|
|
this.msgError(response.message)
|
|
|
}
|
|
}
|
|
|
})
|
|
})
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
|
|
+ examUserExamCommitmentConfirm(type,attemptId){
|
|
|
|
|
+ examUserExamCommitmentConfirm({attemptId:attemptId}).then(response => {
|
|
|
|
|
+ if(type == 1){
|
|
|
|
|
+ this.$router.push({
|
|
|
|
|
+ path: '/startTheExam',
|
|
|
|
|
+ query: {
|
|
|
|
|
+ attemptId: attemptId,
|
|
|
|
|
+ type: '1',
|
|
|
|
|
+ examKind:this.preData.examKind,
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ }else if(type == 2){
|
|
|
|
|
+ this.$router.push({
|
|
|
|
|
+ path: '/startTheExam',
|
|
|
|
|
+ query: {
|
|
|
|
|
+ examId: this.preData.examId,
|
|
|
|
|
+ attemptId: attemptId,
|
|
|
|
|
+ type: '1',
|
|
|
|
|
+ examKind:this.preData.examKind,
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
//开始考试判断是否有承诺书
|
|
//开始考试判断是否有承诺书
|
|
|
setRichExamData(item){
|
|
setRichExamData(item){
|
|
|
- if(item.commitmentEnabled == 1){
|
|
|
|
|
|
|
+ if(item.commitmentEnabled == 1 && !item.commitmentConfirmed){
|
|
|
this.$set(this,'preButtonType',item.commitmentPrintEnabled == 1?true:false);
|
|
this.$set(this,'preButtonType',item.commitmentPrintEnabled == 1?true:false);
|
|
|
this.$set(this,'richTextHtml',item.commitmentContent);
|
|
this.$set(this,'richTextHtml',item.commitmentContent);
|
|
|
this.$set(this,'preData',item);
|
|
this.$set(this,'preData',item);
|