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

This commit is contained in:
dong 2023-05-06 16:17:38 +08:00
parent dd45877e1c
commit d0a6b8e951

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 => {