heyang преди 3 години
родител
ревизия
950a951a5e
променени са 3 файла, в които са добавени 13 реда и са изтрити 1 реда
  1. 1 1
      microserviceUserH5/static/css/anniversaryCelebrate.css
  2. 6 0
      screenAndroid/WXdraw.js
  3. 6 0
      screenIos/WXdraw.js

+ 1 - 1
microserviceUserH5/static/css/anniversaryCelebrate.css

@@ -23,7 +23,7 @@ ul, li {
   width: 7.5rem;
   min-height: 100vh;
   background-color: rgba(22, 12, 31, 1);
-  padding-bottom: 0.34rem;
+  padding-bottom: 1rem;
   background-image: url('../img/anniversaryCelebrate/all-bg.png');
   background-repeat: repeat-y;
   background-size: cover;

+ 6 - 0
screenAndroid/WXdraw.js

@@ -72,7 +72,9 @@ function doConnect() {
     }
   };
   wsss.onmessage = function (res) {
+    console.log('res', res)
     var result = typeof res.data === 'string' ? JSON.parse(res.data) : res.data
+    console.log('result.type', result.type)
     if (result.type === 'cutting') {
       if (result.data.status === 0) {
         $.toast('复制成功', "text");
@@ -112,6 +114,10 @@ function doConnect() {
       }
       return
     }
+    if (result.type === 'payInitiateEvent') {
+      window.location.href = result.data.payUrl
+      return
+    }
   }
 }
 

+ 6 - 0
screenIos/WXdraw.js

@@ -81,7 +81,9 @@ function doConnect() {
     }
   };
   wsss.onmessage = function (res) {
+    console.log('res', res)
     var result = typeof res.data === 'string' ? JSON.parse(res.data) : res.data
+    console.log('result.type', result.type)
     if (result.type === 'cutting') {
       if (result.data.status === 0) {
         $.toast('复制成功', "text");
@@ -121,6 +123,10 @@ function doConnect() {
       }
       return
     }
+    if (result.type === 'payInitiateEvent') {
+      window.location.href = result.data.payUrl
+      return
+    }
   }
 }
 $('body').on("click", function () {