Bladeren bron

fix(SCRM-4320): [DE][C端]临时停车,扫描纸质优惠券以后,缴费页面会直接刷新

john 2 jaren geleden
bovenliggende
commit
c9d5819842
2 gewijzigde bestanden met toevoegingen van 11 en 3 verwijderingen
  1. 10 2
      src/App.vue
  2. 1 1
      src/utils/index.js

+ 10 - 2
src/App.vue

@@ -77,7 +77,15 @@ export default {
         // 如果刷新之后没有与微信小程序建立链接则提示用户,关闭小程序重新进入
         const isReloadLoop = await isReloadBefore();
         if (isReloadLoop) {
-          const isReload = await theCommunicationBetweenWechatAndH5IsNormal();
+          uni.removeStorageSync('isReload');
+            const { theme } = getsTheCurrentTopic();
+            this.$dialog({
+              title: '温馨提示',
+              message: '当前网络异常,请重新进入小程序',
+              confirmButtonColor: this.$theme[theme].primaryColor,
+            });
+            return;
+          /* const isReload = await theCommunicationBetweenWechatAndH5IsNormal();
           if (isReload) {
             uni.removeStorageSync('isReload');
             const { theme } = getsTheCurrentTopic();
@@ -87,7 +95,7 @@ export default {
               confirmButtonColor: this.$theme[theme].primaryColor,
             });
             return;
-          }
+          } */
         }
         if (window.location.href.indexOf('cryptojs') > -1) {
           return;

+ 1 - 1
src/utils/index.js

@@ -302,7 +302,7 @@ export function wssInit() {
     try {
       const socket = new SockJS(`${ getUrl() }/hafengWebsocket?token=${ window.token }`);
       window.stompClient = Stomp.over(socket);
-      // window.stompClient.debug = false;
+      window.stompClient.debug = false;
       windowSendInit();
       window.stompClient.connect({},( frame ) => {
         // 请求 projectId