wudebin 1 bulan lalu
induk
melakukan
2a201d9306

+ 2 - 2
Strides-SPAPP/android/app/version.properties

@@ -1,2 +1,2 @@
-#Mon Apr 27 11:04:30 CST 2026
-VERSION_CODE=932
+#Mon Apr 27 11:29:36 CST 2026
+VERSION_CODE=933

+ 8 - 5
Strides-SPAPP/app/pages/charge/QRScan.js

@@ -75,6 +75,7 @@ export default class QRScan extends Component {
   }
 
   scanResult = (codes) => {
+    console.log("scanResult", this.scaning);
     if (this.scaning) {
       return;
     }
@@ -83,9 +84,6 @@ export default class QRScan extends Component {
     this.setState({
       isResult: true
     }, () => {
-      setTimeout(() => {
-        this.scaning = false;
-      }, 500);
       const msg = codes[0]
       this.getQrMessage(msg?.value);
     });
@@ -121,11 +119,13 @@ export default class QRScan extends Component {
       message: 'It\'s not a legal QR code',
       showCancel: false,
       callback: (e) => {
+        this.scaning = false;
         this.setState({
           isResult: false
         });
       },
       onBackPress: btn => {
+        this.scaning = false;
         Dialog.dismissDialog();
         this.setState({
           isResult: false
@@ -169,8 +169,11 @@ export default class QRScan extends Component {
             isResult: false
           });
         }
-      });
-    })
+      })
+    }).finally(() => {
+      this.scaning = false;
+      console.log("this.scaning", this.scaning);
+    });
   }
 
   switchFlash() {