|
@@ -58,7 +58,7 @@ export default class Index extends Component {
|
58
|
58
|
videoPlayShow: 'flex',
|
59
|
59
|
}
|
60
|
60
|
|
61
|
|
- componentWillMount() {
|
|
61
|
+ componentWillMount () {
|
62
|
62
|
// const { id = '78c3dd489791dc1d29472fa344b08c45' } = this.$router.params
|
63
|
63
|
|
64
|
64
|
ready.queue(() => {
|
|
@@ -92,12 +92,12 @@ export default class Index extends Component {
|
92
|
92
|
})
|
93
|
93
|
}
|
94
|
94
|
|
95
|
|
- componentWillUnmount() {
|
|
95
|
+ componentWillUnmount () {
|
96
|
96
|
const { recordId } = this.state
|
97
|
97
|
recordId && updatePoint(recordId)
|
98
|
98
|
}
|
99
|
99
|
|
100
|
|
- loadHelpGroupList() {
|
|
100
|
+ loadHelpGroupList () {
|
101
|
101
|
const { buildingId } = this.state
|
102
|
102
|
|
103
|
103
|
queryHelpGroup({ buildingId: buildingId }).then(res => {
|
|
@@ -119,7 +119,7 @@ export default class Index extends Component {
|
119
|
119
|
)
|
120
|
120
|
}
|
121
|
121
|
|
122
|
|
- loadDetail() {
|
|
122
|
+ loadDetail () {
|
123
|
123
|
const { buildingId } = this.state
|
124
|
124
|
const { dispatchProjectDetail } = this.props
|
125
|
125
|
this.setState({
|
|
@@ -147,7 +147,7 @@ export default class Index extends Component {
|
147
|
147
|
})
|
148
|
148
|
}
|
149
|
149
|
|
150
|
|
- loadActivityData() {
|
|
150
|
+ loadActivityData () {
|
151
|
151
|
const { buildingId } = this.state
|
152
|
152
|
const payload = { pageSize: 999, pageNumber: 1, buildingId }
|
153
|
153
|
queryActivityList(payload).then(res => {
|
|
@@ -157,7 +157,7 @@ export default class Index extends Component {
|
157
|
157
|
})
|
158
|
158
|
}
|
159
|
159
|
|
160
|
|
- loadNewsData() {
|
|
160
|
+ loadNewsData () {
|
161
|
161
|
const { buildingId } = this.state
|
162
|
162
|
const payload = { pageSize: 2, pageNumber: 1, buildingId }
|
163
|
163
|
queryNewsList(payload).then(res => {
|
|
@@ -167,11 +167,11 @@ export default class Index extends Component {
|
167
|
167
|
})
|
168
|
168
|
}
|
169
|
169
|
|
170
|
|
- navigateTo(url) {
|
|
170
|
+ navigateTo (url) {
|
171
|
171
|
Taro.navigateTo({ url: url })
|
172
|
172
|
}
|
173
|
173
|
// 海报预览图
|
174
|
|
- previewImage(arr) {
|
|
174
|
+ previewImage (arr) {
|
175
|
175
|
// console.log('arr:' + arr)
|
176
|
176
|
if (arr[0].length > 1) {
|
177
|
177
|
Taro.previewImage({
|
|
@@ -198,7 +198,7 @@ export default class Index extends Component {
|
198
|
198
|
})
|
199
|
199
|
}
|
200
|
200
|
|
201
|
|
- openMap() {
|
|
201
|
+ openMap () {
|
202
|
202
|
const {
|
203
|
203
|
buildingName,
|
204
|
204
|
address,
|
|
@@ -225,12 +225,12 @@ export default class Index extends Component {
|
225
|
225
|
})
|
226
|
226
|
}
|
227
|
227
|
|
228
|
|
- toViewAlbum() {
|
|
228
|
+ toViewAlbum () {
|
229
|
229
|
const { buildingId } = this.state
|
230
|
230
|
this.navigateTo(`/pages/project/album/index?id=${buildingId}`)
|
231
|
231
|
}
|
232
|
232
|
|
233
|
|
- onViewFans() {
|
|
233
|
+ onViewFans () {
|
234
|
234
|
const { buildingId } = this.state
|
235
|
235
|
this.navigateTo('/pages/card/fans/index?type=item&id=' + buildingId)
|
236
|
236
|
}
|
|
@@ -259,7 +259,7 @@ export default class Index extends Component {
|
259
|
259
|
}
|
260
|
260
|
}
|
261
|
261
|
|
262
|
|
- getPhoneNumber(e, item) {
|
|
262
|
+ getPhoneNumber (e, item) {
|
263
|
263
|
getUserPhone(e, (phoneNumber) => {
|
264
|
264
|
const { userInfo: { person: { personId, nickname, name } } } = this.props
|
265
|
265
|
Taro.navigateTo({
|
|
@@ -268,7 +268,7 @@ export default class Index extends Component {
|
268
|
268
|
})
|
269
|
269
|
}
|
270
|
270
|
|
271
|
|
- getPosterData() {
|
|
271
|
+ getPosterData () {
|
272
|
272
|
return new Promise(resolve => {
|
273
|
273
|
const { posterData } = this.state
|
274
|
274
|
if (posterData.qrcode) {
|
|
@@ -339,14 +339,14 @@ export default class Index extends Component {
|
339
|
339
|
})
|
340
|
340
|
}
|
341
|
341
|
|
342
|
|
- handleTelClick(item, e) {
|
|
342
|
+ handleTelClick (item, e) {
|
343
|
343
|
e.stopPropagation()
|
344
|
344
|
Taro.makePhoneCall({
|
345
|
345
|
phoneNumber: item.phone
|
346
|
346
|
})
|
347
|
347
|
}
|
348
|
348
|
|
349
|
|
- handleChatClick(item, e) {
|
|
349
|
+ handleChatClick (item, e) {
|
350
|
350
|
e.stopPropagation()
|
351
|
351
|
const { userInfo: { person: { personId, nickname, name } } } = this.props
|
352
|
352
|
Taro.navigateTo({
|
|
@@ -354,24 +354,24 @@ export default class Index extends Component {
|
354
|
354
|
})
|
355
|
355
|
}
|
356
|
356
|
|
357
|
|
- handleConsuItemClick(item) {
|
|
357
|
+ handleConsuItemClick (item) {
|
358
|
358
|
Taro.navigateTo({
|
359
|
359
|
url: `/pages/card/index?id=${item.id}`
|
360
|
360
|
})
|
361
|
361
|
}
|
362
|
362
|
|
363
|
|
- handleMoreClick() {
|
|
363
|
+ handleMoreClick () {
|
364
|
364
|
// App.zhuge.track('查看置业顾问列表')
|
365
|
365
|
Taro.navigateTo({
|
366
|
366
|
url: `/pages/card/list/index?buildingId=${this.state.buildingId}`
|
367
|
367
|
})
|
368
|
368
|
}
|
369
|
369
|
|
370
|
|
- handleStopPropagation(e) {
|
|
370
|
+ handleStopPropagation (e) {
|
371
|
371
|
e.stopPropagation()
|
372
|
372
|
}
|
373
|
373
|
|
374
|
|
- toRecomonedPage() {
|
|
374
|
+ toRecomonedPage () {
|
375
|
375
|
const {
|
376
|
376
|
userInfo: { person: { personType } }
|
377
|
377
|
} = this.props
|
|
@@ -387,50 +387,50 @@ export default class Index extends Component {
|
387
|
387
|
}
|
388
|
388
|
}
|
389
|
389
|
|
390
|
|
- toHome() {
|
|
390
|
+ toHome () {
|
391
|
391
|
Taro.switchTab({
|
392
|
392
|
url: `/pages/project/index`
|
393
|
393
|
})
|
394
|
394
|
}
|
395
|
395
|
|
396
|
|
- HandleCircumTabClick(id) {
|
|
396
|
+ HandleCircumTabClick (id) {
|
397
|
397
|
this.setState({
|
398
|
398
|
curTab: id
|
399
|
399
|
})
|
400
|
400
|
}
|
401
|
401
|
|
402
|
|
- handleNewsMoreClick() {
|
|
402
|
+ handleNewsMoreClick () {
|
403
|
403
|
Taro.navigateTo({
|
404
|
404
|
url: `/pages/news/index?buildingId=` + this.state.buildingId
|
405
|
405
|
})
|
406
|
406
|
}
|
407
|
407
|
|
408
|
|
- handNewsItemClick(id) {
|
|
408
|
+ handNewsItemClick (id) {
|
409
|
409
|
Taro.navigateTo({
|
410
|
410
|
url: '/pages/news/detail/index?id=' + id
|
411
|
411
|
})
|
412
|
412
|
}
|
413
|
413
|
|
414
|
|
- handleActivityMoreClick() {
|
|
414
|
+ handleActivityMoreClick () {
|
415
|
415
|
Taro.navigateTo({
|
416
|
416
|
url: `/pages/activity/index?buildingId=` + this.state.buildingId
|
417
|
417
|
})
|
418
|
418
|
}
|
419
|
419
|
|
420
|
|
- handActivityItemClick(id) {
|
|
420
|
+ handActivityItemClick (id) {
|
421
|
421
|
Taro.navigateTo({
|
422
|
422
|
url: '/pages/activity/detail/index?id=' + id
|
423
|
423
|
})
|
424
|
424
|
}
|
425
|
425
|
|
426
|
|
- handlePreviewHxImage(current, urls) {
|
|
426
|
+ handlePreviewHxImage (current, urls) {
|
427
|
427
|
Taro.previewImage({
|
428
|
428
|
current,
|
429
|
429
|
urls
|
430
|
430
|
})
|
431
|
431
|
}
|
432
|
432
|
|
433
|
|
- handleFavor() {
|
|
433
|
+ handleFavor () {
|
434
|
434
|
const { buildingId, isSaved } = this.state
|
435
|
435
|
if (isSaved) {
|
436
|
436
|
cancelFavorProject(buildingId).then(res => {
|
|
@@ -460,18 +460,18 @@ export default class Index extends Component {
|
460
|
460
|
console.log('活动项目收藏')
|
461
|
461
|
})
|
462
|
462
|
}
|
463
|
|
- handleToolsClick() {
|
|
463
|
+ handleToolsClick () {
|
464
|
464
|
Taro.navigateTo({
|
465
|
465
|
url: `/pages/toolKit/index`
|
466
|
466
|
})
|
467
|
467
|
}
|
468
|
|
- moreFloor() {
|
|
468
|
+ moreFloor () {
|
469
|
469
|
Taro.navigateTo({
|
470
|
470
|
url: `/pages/project/floor/index`
|
471
|
471
|
})
|
472
|
472
|
}
|
473
|
473
|
|
474
|
|
- renderBottomMenu() {
|
|
474
|
+ renderBottomMenu () {
|
475
|
475
|
const { userInfo: { person: { personType } } } = this.props
|
476
|
476
|
const { posterShow } = this.state
|
477
|
477
|
return (
|
|
@@ -506,14 +506,14 @@ export default class Index extends Component {
|
506
|
506
|
)
|
507
|
507
|
}
|
508
|
508
|
|
509
|
|
- previewHouseImage(current, urls) {
|
|
509
|
+ previewHouseImage (current, urls) {
|
510
|
510
|
Taro.previewImage({
|
511
|
511
|
current,
|
512
|
512
|
urls
|
513
|
513
|
})
|
514
|
514
|
}
|
515
|
515
|
|
516
|
|
- renderBuildingProjectTypeList() {
|
|
516
|
+ renderBuildingProjectTypeList () {
|
517
|
517
|
const { statusOpts } = this.state
|
518
|
518
|
const { projectDetail: { buildingProjectType = [], status, marketStatus } } = this.props
|
519
|
519
|
return (
|
|
@@ -572,22 +572,22 @@ export default class Index extends Component {
|
572
|
572
|
}
|
573
|
573
|
|
574
|
574
|
|
575
|
|
- renderPhotoAlbum() {
|
|
575
|
+ renderPhotoAlbum () {
|
576
|
576
|
const { projectDetail: { buildingApartment } } = this.props
|
577
|
577
|
const list = buildingApartment.filter(item => item.apartmentType === 'photo')
|
578
|
|
- const imgList = list.reduce((prev, cur) => {
|
579
|
|
- prev = prev.concat(cur.buildingImgList)
|
580
|
|
- return prev
|
581
|
|
- }, [])
|
|
578
|
+ // const imgList = list.reduce((prev, cur) => {
|
|
579
|
+ // prev = prev.concat(cur.buildingImgList)
|
|
580
|
+ // return prev
|
|
581
|
+ // }, [])
|
|
582
|
+
|
582
|
583
|
|
583
|
|
- const { albumCurrent } = this.state
|
584
|
584
|
|
585
|
585
|
|
586
|
586
|
|
587
|
587
|
return (
|
588
|
588
|
|
589
|
589
|
|
590
|
|
- <Block>
|
|
590
|
+ <Block> {console.log(list, 'list')}
|
591
|
591
|
{list.length > 0 &&
|
592
|
592
|
(
|
593
|
593
|
<View className='photos__type'>
|
|
@@ -597,22 +597,32 @@ export default class Index extends Component {
|
597
|
597
|
|
598
|
598
|
<View className="around-tab">
|
599
|
599
|
{list.map((item, index) => {
|
600
|
|
- const { apartmentName } = item || {}
|
601
|
|
- const buildingImgList = item.buildingImgList
|
602
|
|
-
|
603
|
|
-
|
604
|
|
- return (
|
605
|
|
- <View
|
606
|
|
- style={{ marginRight: '8px' }}
|
607
|
|
- >
|
608
|
|
- {/* {`${label}(${num})`} */}
|
609
|
|
- <View>
|
610
|
|
- <Image className='albumimg' src={getThumbnail(buildingImgList[0].url)} ></Image>
|
611
|
|
- <View style={{ textAlign: 'center' }}> {`${apartmentName}(${buildingImgList.length})`} </View>
|
612
|
|
- </View>
|
613
|
|
- </View>
|
614
|
|
- )
|
615
|
|
- })}
|
|
600
|
+ const { apartmentName } = item
|
|
601
|
+ const buildingImgList = item.buildingImgList
|
|
602
|
+ const buildingImgUrl = buildingImgList.length > 0 ? buildingImgList[0].url : null
|
|
603
|
+
|
|
604
|
+ console.log(buildingImgUrl, 'buildingImgUrl')
|
|
605
|
+
|
|
606
|
+ // if (buildingImgUrl != null) {
|
|
607
|
+ return (<View>
|
|
608
|
+ {buildingImgUrl != null&& (<View
|
|
609
|
+ style={{ marginRight: '8px' }}
|
|
610
|
+ >
|
|
611
|
+
|
|
612
|
+ <View>
|
|
613
|
+ <Image className='albumimg' src={getThumbnail(buildingImgList[0].url)} ></Image>
|
|
614
|
+ <View style={{ textAlign: 'center', width: '218rpx', display: 'flex' }}>
|
|
615
|
+ <View style={{ textAlign: 'center', overflow: 'hidden', textOverflow: 'ellipsis', whiteSpace: 'nowrap' }}> {apartmentName} </View>
|
|
616
|
+
|
|
617
|
+ <View>({buildingImgList.length})</View>
|
|
618
|
+ </View>
|
|
619
|
+ </View>
|
|
620
|
+ </View>)}</View>
|
|
621
|
+ )
|
|
622
|
+ // }
|
|
623
|
+
|
|
624
|
+ })
|
|
625
|
+ }
|
616
|
626
|
</View>
|
617
|
627
|
</View>
|
618
|
628
|
</ScrollView>
|
|
@@ -622,7 +632,7 @@ export default class Index extends Component {
|
622
|
632
|
</Block>
|
623
|
633
|
)
|
624
|
634
|
}
|
625
|
|
- rendercircum() {
|
|
635
|
+ rendercircum () {
|
626
|
636
|
const building = {
|
627
|
637
|
...this.props.projectDetail
|
628
|
638
|
}
|
|
@@ -639,7 +649,7 @@ export default class Index extends Component {
|
639
|
649
|
)
|
640
|
650
|
}
|
641
|
651
|
|
642
|
|
- renderConsuler() {
|
|
652
|
+ renderConsuler () {
|
643
|
653
|
const { userInfo: { person: { phone } } } = this.props
|
644
|
654
|
const { projectDetail: { consultants = [] } } = this.props
|
645
|
655
|
return (
|
|
@@ -693,7 +703,7 @@ export default class Index extends Component {
|
693
|
703
|
)
|
694
|
704
|
}
|
695
|
705
|
|
696
|
|
- renderStatement() {
|
|
706
|
+ renderStatement () {
|
697
|
707
|
return (
|
698
|
708
|
<View className='statement'>
|
699
|
709
|
免责条款:以上价格仅供参考,具体一房一价的信息以售楼处展示为准。本网显示房屋位置、交通、医疗、教育、商业等配套信息,来源于第三方网络数据,不作为要约,仅供参考,双方具体权利义务应以法律规定及买卖合同约定为准。<br></br>本平台对项目周边文化教育的介绍旨在提供相关信息,并不意味着信息发布方对就学安排作出承诺。相关教育资源就学信息存在调整的可能,应以政府教育主管部门及办学颁布的政策规定为准。
|
|
@@ -702,7 +712,7 @@ export default class Index extends Component {
|
702
|
712
|
}
|
703
|
713
|
|
704
|
714
|
|
705
|
|
- renderHelp() {
|
|
715
|
+ renderHelp () {
|
706
|
716
|
const { helpList } = this.state
|
707
|
717
|
return (
|
708
|
718
|
<Block>
|
|
@@ -723,17 +733,17 @@ export default class Index extends Component {
|
723
|
733
|
)
|
724
|
734
|
}
|
725
|
735
|
|
726
|
|
- handleHelpClick(item) {
|
|
736
|
+ handleHelpClick (item) {
|
727
|
737
|
Taro.navigateTo({
|
728
|
738
|
url: '/pages/activity/detail/assistance?id=' + item.activityId
|
729
|
739
|
})
|
730
|
740
|
}
|
731
|
|
- handleGroupClick(item) {
|
|
741
|
+ handleGroupClick (item) {
|
732
|
742
|
Taro.navigateTo({
|
733
|
743
|
url: '/pages/activity/detail/assemble?id=' + item.activityId
|
734
|
744
|
})
|
735
|
745
|
}
|
736
|
|
- renderGroup() {
|
|
746
|
+ renderGroup () {
|
737
|
747
|
const { groupList } = this.state
|
738
|
748
|
return (
|
739
|
749
|
<Block>
|
|
@@ -756,7 +766,7 @@ export default class Index extends Component {
|
756
|
766
|
)
|
757
|
767
|
}
|
758
|
768
|
|
759
|
|
- renderHouseTypeList() {
|
|
769
|
+ renderHouseTypeList () {
|
760
|
770
|
const { statusOpts } = this.state
|
761
|
771
|
const { projectDetail: { buildingApartment } } = this.props
|
762
|
772
|
const list = buildingApartment.filter(item => item.apartmentType === 'apart')
|
|
@@ -873,7 +883,7 @@ export default class Index extends Component {
|
873
|
883
|
</Block>
|
874
|
884
|
)
|
875
|
885
|
}
|
876
|
|
- renderNews() {
|
|
886
|
+ renderNews () {
|
877
|
887
|
const { newsList } = this.state
|
878
|
888
|
return (
|
879
|
889
|
<Block>
|
|
@@ -915,7 +925,7 @@ export default class Index extends Component {
|
915
|
925
|
}
|
916
|
926
|
|
917
|
927
|
onPlay () {
|
918
|
|
- console.log()
|
|
928
|
+ console.log()
|
919
|
929
|
this.setState({
|
920
|
930
|
videoPlayShow: 'none'
|
921
|
931
|
})
|
|
@@ -929,7 +939,7 @@ export default class Index extends Component {
|
929
|
939
|
|
930
|
940
|
|
931
|
941
|
renderVideo () {
|
932
|
|
- const {videoPlayShow} = this.state
|
|
942
|
+ const { videoPlayShow } = this.state
|
933
|
943
|
const { projectDetail } = this.props
|
934
|
944
|
const { videoImage } = projectDetail
|
935
|
945
|
const imgSrc = videoImage[0].url
|
|
@@ -954,12 +964,12 @@ export default class Index extends Component {
|
954
|
964
|
// initialTime='0'
|
955
|
965
|
// loop={false}
|
956
|
966
|
// muted={false}
|
957
|
|
-
|
|
967
|
+
|
958
|
968
|
show-mute-btn='true'
|
959
|
|
- // onPlay={this.onPlay}
|
960
|
|
- // show-center-play-btn='false'
|
961
|
|
- // onPause= {this.onPause}
|
962
|
|
-
|
|
969
|
+ // onPlay={this.onPlay}
|
|
970
|
+ // show-center-play-btn='false'
|
|
971
|
+ // onPause= {this.onPause}
|
|
972
|
+
|
963
|
973
|
></Video>
|
964
|
974
|
{/* <Button className='pro__banner-btn' onClick={this.plagVideo} style={{ display: videoPlayShow }}>
|
965
|
975
|
<Image src={require('@assets/play.png')} mode='scaleToFill' className='pro__banner-btn-img'></Image>
|
|
@@ -968,22 +978,22 @@ export default class Index extends Component {
|
968
|
978
|
{/* <View className='pro__banner-voice' onClick={this.plagVideo} >
|
969
|
979
|
<Image src={require('@assets/voice.png')} mode='scaleToFill ' className='pro__banner-voice-img'></Image>
|
970
|
980
|
</View> */}
|
971
|
|
-{/*
|
|
981
|
+ {/*
|
972
|
982
|
<View className='pro__banner-extend' onClick={this.fullScreen} >
|
973
|
983
|
<Image src={require('@assets/extend.png')} mode='scaleToFill ' className='pro__banner-extend-img'></Image>
|
974
|
984
|
</View> */}
|
975
|
|
-
|
|
985
|
+
|
976
|
986
|
</View>
|
977
|
987
|
)
|
978
|
988
|
}
|
979
|
989
|
|
980
|
|
- changeCurrent(current) {
|
|
990
|
+ changeCurrent (current) {
|
981
|
991
|
this.setState({
|
982
|
992
|
current: current + 1
|
983
|
993
|
})
|
984
|
994
|
}
|
985
|
995
|
|
986
|
|
- render() {
|
|
996
|
+ render () {
|
987
|
997
|
const { posterStatus, posterData, loaded, btnstate } = this.state
|
988
|
998
|
const { projectDetail } = this.props
|
989
|
999
|
const { uvList = {} } = projectDetail
|