|
@@ -7,7 +7,7 @@ import state, { handleRessetState, resetPlaybackToStart, musicalInstrumentCodeIn
|
|
|
import { storeData } from "/src/store";
|
|
|
import { browser } from "/src/utils";
|
|
|
import { getNoteByMeasuresSlursStart } from "/src/helpers/formateMusic";
|
|
|
-import { Icon, Popup, showToast } from "vant";
|
|
|
+import { Icon, Popup, showToast, closeToast, showLoadingToast } from "vant";
|
|
|
import EvaluatResult from "./evaluat-result";
|
|
|
import EvaluatAudio from "./evaluat-audio";
|
|
|
import { api_getDeviceDelay, api_openAdjustRecording, api_proxyServiceMessage, api_videoUpdate, getEarphone, api_back } from "/src/helpers/communication";
|
|
@@ -313,12 +313,31 @@ export default defineComponent({
|
|
|
};
|
|
|
|
|
|
const startBtnHandle = async () => {
|
|
|
+ // 如果是异常状态,先等待500ms再执行后续流程
|
|
|
+ if (evaluatingData.isErrorState && !state.setting.soundEffect) {
|
|
|
+ // console.log('异常流程1')
|
|
|
+ showLoadingToast({
|
|
|
+ message: "处理中",
|
|
|
+ duration: 1000,
|
|
|
+ overlay: true,
|
|
|
+ overlayClass: styles.scoreMode,
|
|
|
+ });
|
|
|
+ await new Promise<void>((resolve) => {
|
|
|
+ setTimeout(() => {
|
|
|
+ closeToast();
|
|
|
+ evaluatingData.isErrorState =false
|
|
|
+ // console.log('异常流程2')
|
|
|
+ resolve()
|
|
|
+ }, 1000);
|
|
|
+ })
|
|
|
+ }
|
|
|
+ // console.log('异常流程3')
|
|
|
// 检测APP端socket状态
|
|
|
const res: any = await startCheckDelay();
|
|
|
if (res?.checked) {
|
|
|
handleConnect();
|
|
|
handleStartBegin(calculateInfo.firstNoteTime);
|
|
|
- if (evaluatingData.isErrorState = true) {
|
|
|
+ if (evaluatingData.isErrorState) {
|
|
|
evaluatingData.isErrorState = false;
|
|
|
evaluatingData.resulstMode = false;
|
|
|
}
|