浏览代码

bug: fix fans index

张延森 5 年前
父节点
当前提交
e62d8281f4

+ 3
- 1
config/dev.js 查看文件

7
     // WSS_HOST: '"wss://47.101.36.130:8085"',
7
     // WSS_HOST: '"wss://47.101.36.130:8085"',
8
     HOST: '"https://dev.pawoma.cn"',//测试
8
     HOST: '"https://dev.pawoma.cn"',//测试
9
     WSS_HOST: '"wss://dev.pawoma.cn"',
9
     WSS_HOST: '"wss://dev.pawoma.cn"',
10
+    // HOST: '"https://dev.jinchengjiaye.com"',//测试
11
+    // WSS_HOST: '"wss://dev.jinchengjiaye.com"',
10
     // HOST: '"https://lt.pawoma.cn"',
12
     // HOST: '"https://lt.pawoma.cn"',
11
     // WSS_HOST: '"wss://lt.pawoma.cn"',
13
     // WSS_HOST: '"wss://lt.pawoma.cn"',
12
     // HOST: '"http://127.0.0.1:8080"',
14
     // HOST: '"http://127.0.0.1:8080"',
13
     // WSS_HOST: '"ws://127.0.0.1:8080"',
15
     // WSS_HOST: '"ws://127.0.0.1:8080"',
14
-    Version: 'V3.5.7_2020-1-30'
16
+    Version: 'V3.5.7'
15
   },
17
   },
16
   weapp: {},
18
   weapp: {},
17
   h5: {}
19
   h5: {}

+ 1
- 1
config/prod.js 查看文件

11
     WSS_HOST: '"wss://dev.pawoma.cn"',
11
     WSS_HOST: '"wss://dev.pawoma.cn"',
12
     // HOST: '"https://lt.pawoma.cn"',
12
     // HOST: '"https://lt.pawoma.cn"',
13
     // WSS_HOST: '"wss://lt.pawoma.cn"',
13
     // WSS_HOST: '"wss://lt.pawoma.cn"',
14
-    Version: 'V3.5.7_2020-1-30'
14
+    Version: 'V3.5.7'
15
   },
15
   },
16
   weapp: {},
16
   weapp: {},
17
   h5: {}
17
   h5: {}

+ 1
- 1
project.config.json 查看文件

2
 	"miniprogramRoot": "dist/",
2
 	"miniprogramRoot": "dist/",
3
 	"projectname": "mini-chengjiao",
3
 	"projectname": "mini-chengjiao",
4
 	"description": "知与行联调",
4
 	"description": "知与行联调",
5
-	"appid": "wxd9ee3a9480a4e544",
5
+	"appid": "wx93ebc652a13d675f",
6
 	"setting": {
6
 	"setting": {
7
 		"urlCheck": false,
7
 		"urlCheck": false,
8
 		"es6": false,
8
 		"es6": false,

+ 11
- 10
src/pages/card/fans/index.js 查看文件

16
     isEmpty: false,
16
     isEmpty: false,
17
     recordId: null,
17
     recordId: null,
18
     pageIndex: 1,
18
     pageIndex: 1,
19
-    noReacord: false,
19
+    noRecord: false,
20
   }
20
   }
21
   componentDidMount() {
21
   componentDidMount() {
22
     // Taro.showLoading()
22
     // Taro.showLoading()
32
       type = 'card'
32
       type = 'card'
33
     } = this.$router.params
33
     } = this.$router.params
34
 
34
 
35
-    const payload = { pageSize:50, pageNumber: 1 }
35
+    const payload = { pageSize: 50, pageNumber: 1 }
36
     // const payload = { pageSize: 50, pageNumber }
36
     // const payload = { pageSize: 50, pageNumber }
37
     if (type === "card") {
37
     if (type === "card") {
38
       // 埋点
38
       // 埋点
52
 
52
 
53
         this.setState({
53
         this.setState({
54
           list: records,
54
           list: records,
55
-          noReacord: records.length ? false : true
55
+          noRecord: records.length ? false : true
56
         })
56
         })
57
         Taro.hideLoading()
57
         Taro.hideLoading()
58
       }).catch(err => {
58
       }).catch(err => {
77
         const { records } = res
77
         const { records } = res
78
         this.setState({
78
         this.setState({
79
           list: records,
79
           list: records,
80
-          noReacord: records.length ? false : true
80
+          noRecord: records.length ? false : true
81
         })
81
         })
82
         Taro.hideLoading()
82
         Taro.hideLoading()
83
       }).catch(err => {
83
       }).catch(err => {
118
   }
118
   }
119
 
119
 
120
   render() {
120
   render() {
121
-    const { hasMore, isEmpty, list, noReacord } = this.state
121
+    const { hasMore, isEmpty, list, noRecord } = this.state
122
     // const { hasMore, isEmpty, list } = this.state
122
     // const { hasMore, isEmpty, list } = this.state
123
 
123
 
124
     return (
124
     return (
133
       // >
133
       // >
134
       //   {list.map(item => <FansItem key={item.uvId} data={item} />)}
134
       //   {list.map(item => <FansItem key={item.uvId} data={item} />)}
135
       // </ListView>
135
       // </ListView>
136
-      <View>
137
-        {!noReacord ?
136
+      // <View>
137
+      <Block>
138
+        {!noRecord ?
138
           <View>
139
           <View>
139
             {list.map(item =>
140
             {list.map(item =>
140
               <FansItem key={item.uvId} data={item} />)}
141
               <FansItem key={item.uvId} data={item} />)}
141
             {list.length >= 50 && <View style="text-align:center;line-height:120rpx;font-size:24rpx;color:#999"> 仅展示最近50条围观记录</View>}
142
             {list.length >= 50 && <View style="text-align:center;line-height:120rpx;font-size:24rpx;color:#999"> 仅展示最近50条围观记录</View>}
142
           </View>
143
           </View>
143
-          : <EmptyPage text="暂无围观记录哦~" />}
144
-
145
-      </View>
144
+          : <EmptyPage text="暂无围观记录哦~" />
145
+        }
146
 
146
 
147
+      </Block>
147
     );
148
     );
148
   }
149
   }
149
 }
150
 }

+ 4
- 7
src/pages/project/detail/index.js 查看文件

800
             >
800
             >
801
               <View className="type-intro__list">
801
               <View className="type-intro__list">
802
                 {
802
                 {
803
-                  buildingProjectType.map(item => (
804
-                    <View className={buildingProjectType.length == 1 ? 'onlyone type-intro__item' : 'type-intro__item'} key={item.buildingId} style={`background: url(${transferImage(buildBg)}) no-repeat center;background-size: 100% 100%;`}>
805
-
803
+                  buildingProjectType.map((item,index) => (
804
+                    <View className={buildingProjectType.length == 1 ? 'onlyone type-intro__item' : 'type-intro__item'} key={index+'detailBuildingId'} style={`background: url(${transferImage(buildBg)}) no-repeat center;background-size: 100% 100%;`}>
806
                       <View >
805
                       <View >
807
-
808
-
809
                         {marketStatus &&
806
                         {marketStatus &&
810
                           <Text className='item__status' className={marketStatus == '在售' ? 'item__status sale' : marketStatus == '售罄' ? 'item__status soldout' : 'item__status waitsale'}>{marketStatus}</Text>
807
                           <Text className='item__status' className={marketStatus == '在售' ? 'item__status sale' : marketStatus == '售罄' ? 'item__status soldout' : 'item__status waitsale'}>{marketStatus}</Text>
811
                         }
808
                         }
966
               </View>
963
               </View>
967
               <View className="section-content">
964
               <View className="section-content">
968
                 {
965
                 {
969
-                  consultants.slice(0, 3).map(item => (
970
-                    <View className="item" key={item.id} >
966
+                  consultants.slice(0, 3).map((item,index) => (
967
+                    <View className="item" key={index+'detailId'} >
971
                       <View className="flex">
968
                       <View className="flex">
972
                         <Image className="avatar" mode="aspectFill" onClick={this.handleConsuItemClick.bind(this, item)} src={transferImage(item.photo || item.avatar)}></Image>
969
                         <Image className="avatar" mode="aspectFill" onClick={this.handleConsuItemClick.bind(this, item)} src={transferImage(item.photo || item.avatar)}></Image>
973
                         <View className='name-txt' onClick={this.handleConsuItemClick.bind(this, item)}>
970
                         <View className='name-txt' onClick={this.handleConsuItemClick.bind(this, item)}>

+ 2
- 2
src/pages/project/index.js 查看文件

476
                 </View>
476
                 </View>
477
               </View>
477
               </View>
478
               <View className="section-content">
478
               <View className="section-content">
479
-                {list.map(item => (
479
+                {list.map((item, index) => (
480
                   <ProjectItem
480
                   <ProjectItem
481
-                    key={item.buildingId}
481
+                    key={index + 'buildingId'}
482
                     onClick={this.onViewDetail.bind(this, item)}
482
                     onClick={this.onViewDetail.bind(this, item)}
483
                     data={item}
483
                     data={item}
484
                   />
484
                   />

+ 1
- 1
src/pages/project/item/index.js 查看文件

55
             <View className='item__bottom__right'>
55
             <View className='item__bottom__right'>
56
               <Text className='item__bottom__seenum'>{data.pvNum || 0}人围观</Text>
56
               <Text className='item__bottom__seenum'>{data.pvNum || 0}人围观</Text>
57
               <View className='see__img'>
57
               <View className='see__img'>
58
-                {records.slice(0, 4).map(item => <Image className='userImg' key={item.uvId} src={transferImage(item.photoOravatar)}></Image>)}
58
+                {records.slice(0, 4).map((item,index) => <Image className='userImg' key={index+'uvId'} src={transferImage(item.photoOravatar)}></Image>)}
59
                 {records.length > 4 && <Image className="dot-img" src={transferImage(dotImg)}></Image>}
59
                 {records.length > 4 && <Image className="dot-img" src={transferImage(dotImg)}></Image>}
60
               </View>
60
               </View>
61
             </View>
61
             </View>