|
@@ -1,5 +1,5 @@
|
|
|
import { Transition, defineComponent, onMounted, reactive, watch, defineAsyncComponent } from "vue";
|
|
|
-import { connectWebsocket, evaluatingData, handleEndBegin, handleStartBegin, handleStartEvaluat, handleViewReport, startCheckDelay, checkUseEarphone } from "/src/view/evaluating";
|
|
|
+import { connectWebsocket, evaluatingData, handleEndBegin, handleStartBegin, handleStartEvaluat, handleViewReport, startCheckDelay, checkUseEarphone, handleCancelEvaluat } from "/src/view/evaluating";
|
|
|
import Earphone from "./earphone";
|
|
|
import styles from "./index.module.less";
|
|
|
import SoundEffect from "./sound-effect";
|
|
@@ -256,7 +256,7 @@ export default defineComponent({
|
|
|
};
|
|
|
|
|
|
/** 评测结果按钮处理 */
|
|
|
- const handleEvaluatResult = (type: "practise" | "tryagain" | "look" | "share" | "update") => {
|
|
|
+ const handleEvaluatResult = (type: "practise" | "tryagain" | "look" | "share" | "update" | "selfCancel") => {
|
|
|
if (type === "update") {
|
|
|
if (state.isAppPlay) {
|
|
|
evaluatModel.evaluatUpdateAudio = true;
|
|
@@ -287,7 +287,11 @@ export default defineComponent({
|
|
|
// 去练习
|
|
|
handleStartEvaluat();
|
|
|
} else if (type === "tryagain") {
|
|
|
- // 再来一次
|
|
|
+ startBtnHandle()
|
|
|
+ } else if (type === "selfCancel") {
|
|
|
+ // 再来一次,需要手动取消评测,不生成评测记录,不显示评测结果弹窗
|
|
|
+ evaluatingData.oneselfCancleEvaluating = true;
|
|
|
+ handleCancelEvaluat();
|
|
|
startBtnHandle()
|
|
|
}
|
|
|
resetPlaybackToStart()
|
|
@@ -389,7 +393,7 @@ export default defineComponent({
|
|
|
)}
|
|
|
{evaluatingData.websocketState && evaluatingData.startBegin && (
|
|
|
<>
|
|
|
- <img class={styles.iconBtn} src={headImg("icon_reset.png")} onClick={()=>handleEvaluatResult("tryagain")} />
|
|
|
+ <img class={styles.iconBtn} src={headImg("icon_reset.png")} onClick={()=>handleEvaluatResult("selfCancel")} />
|
|
|
<img class={styles.iconBtn} src={headImg("submit.png")} onClick={() => handleEndBegin()}/>
|
|
|
</>
|
|
|
)}
|