实训调整

This commit is contained in:
fan 2022-09-02 09:45:51 +08:00
parent 663e19e870
commit 0b32f34af2
3 changed files with 10 additions and 2 deletions

View File

@ -440,4 +440,7 @@ export default class SignalButton extends Group {
}
}
getAnchorPoint() {}
getShapeTipPoint() {
return this.computedPosition;
}
}

View File

@ -130,7 +130,7 @@ const training = {
flag = (trainingOperate.userOperationType === stepOperation.userOperationType) && flag;
}
for (const param in stepOperation.params) {
flag = (trainingOperate.params[param] === stepOperation.params[param]) && flag;
flag = (trainingOperate.param[param] === stepOperation.params[param]) && flag;
}
if (flag && step.operations.length === (operateIndex + 1 )) {
commit('stepOverCountChange');
@ -139,7 +139,11 @@ const training = {
commit('operateOrderIncrease');
resolve();
} else {
console.error('校验失败;');
const stepList = JSON.parse(state.trainingDetail.stepJson);
const step = stepList.find(item => item.id == state.stepOrder );
const operateIndex = step.operations.findIndex(item => item.id == state.operateOrder);
const stepOperation = step.operations[operateIndex];
console.error('校验失败;', trainingOperate, stepOperation);
reject('校验失败');
}
});

View File

@ -60,6 +60,7 @@ export default {
const trainingDetail = this.$store.state.trainingNew.trainingDetail;
const stepOrder = this.$store.state.trainingNew.stepOrder;
const steps = JSON.parse(trainingDetail.stepJson);
console.log(stepOrder, '-----------');
if (steps && steps.length) {
const step = steps[stepOrder - 1];
const distance = 5;