Sfoglia il codice sorgente

避免人脸识别功能被大量重复点击

Michael Wang 5 anni fa
parent
commit
72610a1549
1 ha cambiato i file con 2 aggiunte e 0 eliminazioni
  1. 2 0
      src/components/FaceRecognition/FaceRecognition.vue

+ 2 - 0
src/components/FaceRecognition/FaceRecognition.vue

@@ -445,6 +445,8 @@ export default {
       } finally {
         this.videoStartPlay();
         this.msg = "开始识别";
+        // 避免人脸识别功能被大量重复点击
+        await new Promise(resolve => setTimeout(() => resolve(), 3000));
         this.disableSnap = false;
       }
     },