diff --git a/entry/src/main/ets/pages/judgeSDK/judge.ts b/entry/src/main/ets/pages/judgeSDK/judge.ts index 93752c60..72ca9206 100644 --- a/entry/src/main/ets/pages/judgeSDK/judge.ts +++ b/entry/src/main/ets/pages/judgeSDK/judge.ts @@ -329,12 +329,12 @@ export default class Judge { private isEndTip: boolean = false; private deductedPopShowTimer: number = 0; // 校验考试是否结束 + // 校验考试是否结束 checkExamIsEnd = async (isManual?: boolean) => { - const { judgeUI, avPlayer, isExamEnd, isEndTip, ksjs } = this; - const { isAllProjectsEnd, examSubject, singlePlay, totalScore, judgeConfigObj, passingScore, examMileage, jl } = - judgeUI; - + const {judgeUI,avPlayer,isExamEnd,isEndTip,ksjs} = this; + const {isAllProjectsEnd,examSubject,singlePlay,totalScore,judgeConfigObj,passingScore,examMileage,jl} = judgeUI; + const param302 = judgeConfigObj['302']; if (isExamEnd) { return } @@ -346,24 +346,21 @@ export default class Judge { this.isExamEnd = true this.isManual = true } else { - const param302 = judgeConfigObj['302']; const param342 = judgeConfigObj['342']; const param512 = (judgeConfigObj['512'] || '').split(','); - //单机模式 if (singlePlay) { console.info(judgeTag + ' isAllProjectsEnd => ', isAllProjectsEnd) if (isAllProjectsEnd && jl >= examMileage) { //成绩合格 if (totalScore >= passingGrade && !isEndTip) { - if (examSubject == 3 && (param342 == 0 || param342 == 2) && - (param302 != 6 || param302 != 7 || param302 != 8)) { + if (examSubject == 3 && (param342 == 0 || param342 == 2) && (param302 != 6 || param302 != 7 || param302 != 8)) { if (param512[7] != 0) { - clearTimeout(this.deductedPopShowTimer) - avPlayer.playAudio(['voice/综合评判.mp3']) - this.judgeUI.isDeductedPopShow = true - this.judgeUI.defaultTabIndex = 1 - this.isEndTip = true + // clearTimeout(this.deductedPopShowTimer) + // avPlayer.playAudio(['voice/综合评判.mp3']) + // this.judgeUI.isDeductedPopShow = true + // this.judgeUI.defaultTabIndex = 1 + // this.isEndTip = true return } } else { @@ -385,15 +382,17 @@ export default class Judge { //成绩不合格 if (totalScore < passingGrade) { //科目三不合格报靠边停车 - if (examSubject == 3 && param302 == 1) { - avPlayer.playAudio([`voice/考试结束.mp3`]); - return + if (examSubject == 3 ) { + if( param302 == 1){ + avPlayer.playAudio([`voice/考试结束.mp3`]); + }else if(param302 == 0){ + return + } } await examJudgeEndExam() this.isExamEnd = true return } - //成绩合格 if (isAllProjectsEnd && totalScore >= passingGrade && !isEndTip) { if (examSubject == 2) { @@ -414,8 +413,7 @@ export default class Judge { return } - if (examSubject == 3 && (param342 == 0 || param342 == 2) && - (param302 != 6 || param302 != 7 || param302 != 8)) { + if (examSubject == 3 && (param342 == 0 || param342 == 2) && (param302 != 6 || param302 != 7 || param302 != 8)) { if (param512[7] != 0) { clearTimeout(this.deductedPopShowTimer) this.judgeUI.isDeductedPopShow = false @@ -1224,6 +1222,13 @@ export default class Judge { }) }) } else { + //收到综合评判语音时,显示综合评判弹窗 + if(code[0] == 'zhpp'){ + clearTimeout(this.deductedPopShowTimer) + this.judgeUI.isDeductedPopShow = true + this.judgeUI.defaultTabIndex = 1 + this.isEndTip = true + } avPlayer.playAudio([`voice/${code[0]}.mp3`]) } } @@ -1246,8 +1251,8 @@ export default class Judge { totalScore < passingScore) { avPlayer.playAudio([`voice/考试结束.mp3`]) } - //联网模式下手动结束的直接退出 - if (!singlePlay && isManual && !isAllProjectsEnd) { + //联网模式下:项目没有做完、当前分数大于及格分;手动结束直接退出 + if (!singlePlay && isManual && !isAllProjectsEnd && totalScore >= passingScore) { avPlayer.playAudio(['voice/empty.mp3'], true, () => { this.isUdpEnd = true; closeAllFiles() diff --git a/entry/src/main/resources/rawfile/voice/end_tip.mp3 b/entry/src/main/resources/rawfile/voice/end_tip.mp3 new file mode 100644 index 00000000..3e1aac02 Binary files /dev/null and b/entry/src/main/resources/rawfile/voice/end_tip.mp3 differ diff --git a/entry/src/main/resources/rawfile/voice/zhpp.mp3 b/entry/src/main/resources/rawfile/voice/zhpp.mp3 new file mode 100644 index 00000000..f49a6c82 Binary files /dev/null and b/entry/src/main/resources/rawfile/voice/zhpp.mp3 differ