代码调整

This commit is contained in:
dong 2022-11-02 15:48:50 +08:00
parent 34a4e92073
commit b623a0734e
2 changed files with 8 additions and 1 deletions

View File

@ -546,6 +546,9 @@ const socket = {
simulationScriptTipFinishIncrease: (state) => {
state.simulationScriptTipFinish++;
},
setTrainingStepFinishCount: (state) => {
state.trainingStepFinishCount++;
},
clearSimulationScriptTipFinish: (state) => {
state.simulationScriptTipFinish = 0;
},
@ -922,6 +925,9 @@ const socket = {
},
trainingOverCountIncrease: ({ commit }) => {
commit('trainingOverCountIncrease');
},
setTrainingStepFinishCount: ({ commit }) => {
commit('setTrainingStepFinishCount');
}
}
};

View File

@ -110,7 +110,7 @@ export default {
this.$store.dispatch('socket/setTrainingStepTip', msg);
} else {
this.$store.dispatch('socket/setTrainingStepTip', null);
// this.$store.dispatch('trainingNew/clearStepOrder');
val && this.$store.dispatch('socket/trainingOverCountIncrease');
}
// operateOrder;
}
@ -165,6 +165,7 @@ export default {
this.$store.dispatch('trainingNew/clearStepOrder');
this.$store.dispatch('trainingNew/clearOperateOrder');
this.$store.dispatch('trainingNew/setTrainingScore', resp.data);
this.$store.dispatch('socket/setTrainingStepFinishCount');
}).catch(() => {
this.$message.error('结束实训失败!');
});