Browse Source

codeparams

xujing 5 years ago
parent
commit
31acc984dd
1 changed files with 3 additions and 3 deletions
  1. 3
    3
      src/pages/project/h5Page.js

+ 3
- 3
src/pages/project/h5Page.js View File

27
     webViewVisible: false,
27
     webViewVisible: false,
28
     // pageHide: true,
28
     // pageHide: true,
29
     pageInfo: {},
29
     pageInfo: {},
30
-    codeParams: '', // 解析二维码参数
30
+    codeParams: {}, // 解析二维码参数
31
     h5Id: undefined,
31
     h5Id: undefined,
32
     reportedCustomer: false,
32
     reportedCustomer: false,
33
   }
33
   }
39
         getQrCodeParams(this.$router.params.scene).then((res) => {
39
         getQrCodeParams(this.$router.params.scene).then((res) => {
40
           console.log(res, "解析二维码返回值")
40
           console.log(res, "解析二维码返回值")
41
           this.setState({
41
           this.setState({
42
-            codeParams: res || '',
42
+            codeParams: res || {},
43
             h5Id: res.id
43
             h5Id: res.id
44
           }, () => {
44
           }, () => {
45
             if (isEmpty(res.id)) {
45
             if (isEmpty(res.id)) {
392
       `h5id=${h5Id}`,
392
       `h5id=${h5Id}`,
393
       `consultant=${consultant}`,
393
       `consultant=${consultant}`,
394
       `firstShare=${firstShare}`,
394
       `firstShare=${firstShare}`,
395
-      `codeParams=${encodeURIComponent(codeParams)}`,
395
+      `codeParams=${encodeURIComponent(codeParams['__raw'])}`,
396
     ].join('&')
396
     ].join('&')
397
 
397
 
398
     const showH5 = !isEmpty(h5Id) && pageInfo.h5Address && pageInfo.h5Address !== 'about' && pageInfo.h5Address !== 'http://about' && pageInfo.h5Address !== 'https://about'
398
     const showH5 = !isEmpty(h5Id) && pageInfo.h5Address && pageInfo.h5Address !== 'about' && pageInfo.h5Address !== 'http://about' && pageInfo.h5Address !== 'https://about'