切换考试时实训模式弹窗关闭

(cherry picked from commit d0a6b8e951)
This commit is contained in:
dong 2023-05-06 16:17:38 +08:00 committed by fan
parent 1afb68818f
commit 06cab3d7fe

View File

@ -86,6 +86,13 @@ export default {
}); });
}, },
start(row) { start(row) {
if (this.$store.state.trainingNew.trainingSwitch) {
this.$message.error('请先结束当前实训后再加载新的考试!');
return;
}
if (this.$store.state.trainingNew.trainingDetail) {
this.$store.dispatch('trainingNew/setTrainingDetail', null);
}
generateExam(row.id) generateExam(row.id)
.then(resp => { .then(resp => {
getUserExamInfo(resp.data.id).then(res => { getUserExamInfo(resp.data.id).then(res => {