Bladeren bron

Merge branch 'iteration-20250225-use-code' into jenkins-test

lex-xin 5 maanden geleden
bovenliggende
commit
aad0ee85a9
2 gewijzigde bestanden met toevoegingen van 7 en 6 verwijderingen
  1. 5 5
      src/state.ts
  2. 2 1
      src/views/fill-questionnaire/index.tsx

+ 5 - 5
src/state.ts

@@ -110,15 +110,15 @@ export const goAliAuth = (alipayAppId: string, urlString?: string) => {
   const urlNow = encodeURIComponent(urlString || window.location.href);
   const appid = alipayAppId || '2021004100630808';
   // 开发环境
-  if (import.meta.env.DEV) {
+  // if (import.meta.env.DEV) {
     let url = `https://kt.colexiu.com/getAliCode?app_id=${appid}&state=STATE&redirect_uri=${urlNow}`;
     window.location.replace(url);
-  }
+  // }
 
   // 生产环境
-  if (import.meta.env.PROD) {
-    alipayAuth(alipayAppId, urlString);
-  }
+  // if (import.meta.env.PROD) {
+  //   alipayAuth(alipayAppId, urlString);
+  // }
 };
 
 const alipayAuth = (alipayAppId: string, urlString?: string) => {

+ 2 - 1
src/views/fill-questionnaire/index.tsx

@@ -207,7 +207,8 @@ export default defineComponent({
     });
 
     // 如果没有openId,跳转到第一个页面
-    if (!authCode.onWeChatCatchOpenId("GET")) {
+    forms.openId = authCode.onWeChatCatchOpenId("GET");
+    if (!forms.openId) {
       router.push({
         path: '/intention-questionnaire',
         query: {