|
@@ -12,6 +12,7 @@ import { getQrCodeParams } from '@utils/qrcode'
|
12
|
12
|
import { getCardDetail } from '@services/card'
|
13
|
13
|
import { ROLE_CODE } from '@constants/user'
|
14
|
14
|
import Consultant from '@components/consultant'
|
|
15
|
+import AuthorizationComponent from '@components/authorizationComponent'
|
15
|
16
|
import {
|
16
|
17
|
addActivityShareNum,
|
17
|
18
|
signupActivity,
|
|
@@ -87,9 +88,29 @@ export default class Detail extends Component {
|
87
|
88
|
const consultant = this.$router.params.consultant || router.query.consultant
|
88
|
89
|
const consultantId = this.$router.params.consultantId || router.query.consultantId || ""
|
89
|
90
|
const recommender = this.$router.params.recommender || router.query.recommender || ""
|
|
91
|
+
|
90
|
92
|
queryActivityDetail(id).then(res => {
|
91
|
93
|
Taro.hideLoading()
|
92
|
94
|
const { isSaved, isSign } = res
|
|
95
|
+
|
|
96
|
+ savePoint({
|
|
97
|
+ event: 'detail',
|
|
98
|
+ eventType: 'activity',
|
|
99
|
+ propertyName: '活动详情',
|
|
100
|
+ buildingId: res.buildingId,
|
|
101
|
+ targetId: res.dynamicId,
|
|
102
|
+ consultantId: consultantId,
|
|
103
|
+ sharePersonId: recommender,
|
|
104
|
+ data: '{}'
|
|
105
|
+ }).then(res1 => {
|
|
106
|
+ this.setState({
|
|
107
|
+ recordId: res1.recordId
|
|
108
|
+ })
|
|
109
|
+ console.log('活动详情')
|
|
110
|
+ }).catch(err => {
|
|
111
|
+ console.log(err, "err")
|
|
112
|
+ })
|
|
113
|
+
|
93
|
114
|
this.setState({
|
94
|
115
|
detail: res,
|
95
|
116
|
isSaved,
|
|
@@ -107,21 +128,7 @@ export default class Detail extends Component {
|
107
|
128
|
})
|
108
|
129
|
WxParse.wxParse('article', 'html', res.desc, this.$scope, 0)
|
109
|
130
|
|
110
|
|
- savePoint({
|
111
|
|
- event: 'detail',
|
112
|
|
- eventType: 'activity',
|
113
|
|
- propertyName: '活动详情',
|
114
|
|
- buildingId: res.buildingId,
|
115
|
|
- targetId: res.dynamicId,
|
116
|
|
- consultantId: consultantId,
|
117
|
|
- sharePersonId: recommender,
|
118
|
|
- data: '{}'
|
119
|
|
- }).then(res1 => {
|
120
|
|
- this.setState({
|
121
|
|
- recordId: res1.recordId
|
122
|
|
- })
|
123
|
|
- console.log('活动详情')
|
124
|
|
- })
|
|
131
|
+
|
125
|
132
|
})
|
126
|
133
|
|
127
|
134
|
if (consultant) {
|
|
@@ -177,6 +184,7 @@ export default class Detail extends Component {
|
177
|
184
|
})
|
178
|
185
|
const consultant = personType == ROLE_CODE['CONSULTANT'] ? personId : ""
|
179
|
186
|
const shareData = shareContents && shareContents.length ? shareContents[0] : { shareContentTitle: title, shareContentImg: imgUrl };
|
|
187
|
+ console.log(`/pages/activity/detail/index?id=${dynamicId}&from=dynamic_share&recommender=${personId}&consultant=${consultant}&consultantId=${consultantId}`)
|
180
|
188
|
return {
|
181
|
189
|
title: shareData.shareContentTitle,
|
182
|
190
|
path: `/pages/activity/detail/index?id=${dynamicId}&from=dynamic_share&recommender=${personId}&consultant=${consultant}&consultantId=${consultantId}`,//分享地址
|
|
@@ -383,6 +391,7 @@ export default class Detail extends Component {
|
383
|
391
|
const { userInfo: { person: { phone, personId, nickname, name } } } = this.props
|
384
|
392
|
return (
|
385
|
393
|
<Block>
|
|
394
|
+ <AuthorizationComponent>
|
386
|
395
|
{/* 生成海报 */}
|
387
|
396
|
{posterVisible && (<Poster data={posterData} toggle={this.togglePosterStatus}></Poster>)}
|
388
|
397
|
|
|
@@ -495,6 +504,7 @@ export default class Detail extends Component {
|
495
|
504
|
</View>
|
496
|
505
|
)
|
497
|
506
|
}
|
|
507
|
+ </AuthorizationComponent>
|
498
|
508
|
</Block>
|
499
|
509
|
)
|
500
|
510
|
}
|