Forráskód Böngészése

微信小程序登录逻辑梳理_v12

John-Hong 2 éve
szülő
commit
f769e5c07e
2 módosított fájl, 10 hozzáadás és 2 törlés
  1. 8 1
      nginx_parking.conf
  2. 2 1
      src/pages/login/openWx.vue

+ 8 - 1
nginx_parking.conf

@@ -31,11 +31,18 @@ server {
     location /profileApi {
         proxy_pass https://qa-apim.kerryplus.com/c/api;
     }
-    
+
     location /profileApiProd {
         proxy_pass https://apim.kerryplus.com/c/api;
     }
 
+    location /qaApi {
+        proxy_pass https://qa-crm-kpl.kerryprops.com.cn/xcrm-api;
+    }
+    location /api {
+        proxy_pass https://crm.kerryplus.com/xcrm-api;
+    }
+
     location /sns {
         proxy_pass https://api.weixin.qq.com/sns;
     }

+ 2 - 1
src/pages/login/openWx.vue

@@ -16,7 +16,8 @@ export default {
   mounted() {
     console.log(17171717171717);
     const kipAccessToken = uni.getStorageSync('kipAccessToken');
-    if (!kipAccessToken) {
+    const openid = uni.getStorageSync('openid');
+    if (openid && !kipAccessToken) {
       /* if (!openid) {
             // 当进入其他页面时,需要先打开路由展示
             this.isInit = true;