xujing 5 år sedan
förälder
incheckning
ae6451ffc3
4 ändrade filer med 47 tillägg och 14 borttagningar
  1. 4
    4
      config/dev.js
  2. 4
    2
      config/prod.js
  3. 31
    8
      src/onlineSelling/pages/houseList/index.js
  4. 8
    0
      src/onlineSelling/pages/live/index.js

+ 4
- 4
config/dev.js Visa fil

@@ -3,10 +3,10 @@ module.exports = {
3 3
     NODE_ENV: '"development"'
4 4
   },
5 5
   defineConstants: {
6
-    // HOST: '"https://dev.fangdeal.cn"',//测试
7
-    // WSS_HOST: '"wss://dev.fangdeal.cn"',
8
-    HOST: '"http://192.168.2.41:8080"',
9
-    WSS_HOST: '"ws://192.168.2.41:8080"',
6
+    HOST: '"https://dev.fangdeal.cn"',//测试
7
+    WSS_HOST: '"wss://dev.fangdeal.cn"',
8
+    // HOST: '"http://192.168.2.41:8080"',
9
+    // WSS_HOST: '"ws://192.168.2.41:8080"',
10 10
     OSS_PATH: 'https://njcj.oss-cn-shanghai.aliyuncs.com/',
11 11
     OSS_FAST_PATH: 'https://njcj.oss-accelerate.aliyuncs.com/',
12 12
     Version: 'V3.5.22'

+ 4
- 2
config/prod.js Visa fil

@@ -3,8 +3,10 @@ module.exports = {
3 3
     NODE_ENV: '"production"'
4 4
   },
5 5
   defineConstants: {
6
-    HOST: '"https://wx.fangdeal.cn"',//正式
7
-    WSS_HOST: '"wss://wx.fangdeal.cn"',
6
+    HOST: '"https://dev.fangdeal.cn"',//正式
7
+    WSS_HOST: '"wss://dev.fangdeal.cn"',
8
+    // HOST: '"https://wx.fangdeal.cn"',//正式
9
+    // WSS_HOST: '"wss://wx.fangdeal.cn"',
8 10
     OSS_PATH: 'https://njcj.oss-cn-shanghai.aliyuncs.com/',
9 11
     OSS_FAST_PATH: 'https://njcj.oss-accelerate.aliyuncs.com/',
10 12
     Version: 'V3.5.22'

+ 31
- 8
src/onlineSelling/pages/houseList/index.js Visa fil

@@ -26,14 +26,14 @@ import { Loading } from '@/components/Loading'
26 26
 import * as houseActions from '@/actions/house'
27 27
 
28 28
 @connect(s => s.user, { ...houseActions })
29
-@withDetail({
30
-  track: {
31
-    event: 'house_list',
32
-    eventType: 'house',
33
-    propertyName: '查看房源列表',
34
-    data: '{}',
35
-  }
36
-})
29
+// @withDetail({
30
+//   track: {
31
+//     event: 'house_list',
32
+//     eventType: 'house',
33
+//     propertyName: '查看房源列表',
34
+//     data: '{}',
35
+//   }
36
+// })
37 37
 export default class HouseList extends Component {
38 38
   config = {
39 39
     navigationBarTitleText: '房源',
@@ -62,6 +62,7 @@ export default class HouseList extends Component {
62 62
     noRecord: false,
63 63
     loading: true,
64 64
     dataType: 1,
65
+    recordId: undefined, // 埋点ID
65 66
   }
66 67
 
67 68
 
@@ -75,6 +76,10 @@ export default class HouseList extends Component {
75 76
     this.props.dispatchFlush2Cart([])
76 77
   }
77 78
 
79
+  componentWillUnmount() {
80
+    const { recordId } = this.state
81
+    recordId && updatePoint(recordId)
82
+  }
78 83
 
79 84
   componentWillReceiveProps() {
80 85
     this.reportClientFn()
@@ -172,6 +177,8 @@ export default class HouseList extends Component {
172 177
     this.reportClientFn()
173 178
     let { qrcodeParams } = this.state
174 179
     const consultant = this.$router.params.consultant || qrcodeParams.consultant
180
+    const consultantId = this.$router.params.consultantId || qrcodeParams.consultantId || ""
181
+    const recommender = this.$router.params.recommender || qrcodeParams.recommender || ""
175 182
 
176 183
     if (consultant) {
177 184
       getCardDetail(consultant).then(res => {
@@ -188,6 +195,22 @@ export default class HouseList extends Component {
188 195
         salesBatchDetail: res || {},
189 196
         noRecord: res.status == '1' ? false : true
190 197
       })
198
+      savePoint({
199
+        event: 'house_list',
200
+        eventType: 'house',
201
+        propertyName: '查看房源列表',
202
+        targetId: res.salesBatchId || '',
203
+        buildingId: res.buildingId || '',
204
+        consultantId: consultantId,
205
+        sharePersonId: recommender,
206
+        data: '{}',
207
+
208
+      }).then(res => {
209
+        this.setState({
210
+          recordId: res.recordId
211
+        })
212
+        console.log('查看房源列表')
213
+      })
191 214
       const { templates = [], posterImg = '' } = (res.posters || [])[0] || {}
192 215
 
193 216
       this.setState({

+ 8
- 0
src/onlineSelling/pages/live/index.js Visa fil

@@ -129,13 +129,21 @@ export default class livePage extends Component {
129 129
         liveDetail: res || {},
130 130
         noRecord: res.status == '1' ? false : true
131 131
       })
132
+      const { qrcodeParams } = this.state
133
+      const consultantId = this.$router.params.consultantId || qrcodeParams.consultantId || ""
134
+      const recommender = this.$router.params.recommender || qrcodeParams.recommender || ""
132 135
       savePoint({
133 136
         event: 'detail',
134 137
         eventType: 'activity',
135 138
         targetType: 'live',
136 139
         targetId: id,
137 140
         propertyName: '查看直播详情页',
141
+        buildingId: res.buildingId || '',
142
+        consultantId: consultantId,
143
+        sharePersonId: recommender,
138 144
         data: '{}',
145
+
146
+
139 147
       }).then(res => {
140 148
         this.setState({
141 149
           recordId: res.recordId