xujing 5 年前
父节点
当前提交
ac8ab1236a
共有 1 个文件被更改,包括 4 次插入9 次删除
  1. 4
    9
      src/pages/project/index.js

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

8
 import ready from '@/utils/ready'
8
 import ready from '@/utils/ready'
9
 import { savePoint, updatePoint, queryExtContents, queryIndexIcons } from '@/services/common'
9
 import { savePoint, updatePoint, queryExtContents, queryIndexIcons } from '@/services/common'
10
 import { queryHelpGroup } from '@/services/news'
10
 import { queryHelpGroup } from '@/services/news'
11
-import { getIndexShare, queryUserInfo } from '@/services/user'
11
+import { getIndexShare } from '@/services/user'
12
 import { dispatchCitySelected } from '@/actions/city'
12
 import { dispatchCitySelected } from '@/actions/city'
13
 import { SET_SCREEN_SHOWED } from '@/constants/project'
13
 import { SET_SCREEN_SHOWED } from '@/constants/project'
14
 import { getStore, connect } from '@tarojs/redux'
14
 import { getStore, connect } from '@tarojs/redux'
48
     newsShow: false,
48
     newsShow: false,
49
     city: null,
49
     city: null,
50
     iconList: [],
50
     iconList: [],
51
-    users: {},
52
   }
51
   }
53
 
52
 
54
   componentWillMount() {
53
   componentWillMount() {
110
   }
109
   }
111
   componentDidShow() {
110
   componentDidShow() {
112
     // this.getIndexShareInfo()
111
     // this.getIndexShareInfo()
113
-    queryUserInfo().then(users => {
114
-      this.setState({
115
-        users,
116
-      })
117
-    })
112
+
118
     const city = this.state.city || this.props.curCity
113
     const city = this.state.city || this.props.curCity
119
     if (city && city.id) {
114
     if (city && city.id) {
120
       ready.queue(() => {
115
       ready.queue(() => {
513
   }
508
   }
514
 
509
 
515
   render() {
510
   render() {
516
-    const { achieve, helpGroupList, propagandaBanner, newsShow, iconList, newImg, users } = this.state
511
+    const { achieve, helpGroupList, propagandaBanner, newsShow, iconList, newImg } = this.state
517
     const { curCity, unReadNum, userInfo: { person: { personType } } } = this.props
512
     const { curCity, unReadNum, userInfo: { person: { personType } } } = this.props
518
     console.log(personType, "personTypepersonTypepersonTypepersonType")
513
     console.log(personType, "personTypepersonTypepersonTypepersonType")
519
 
514
 
560
                 </View>
555
                 </View>
561
               </View>
556
               </View>
562
               {/* 菜单栏 */}
557
               {/* 菜单栏 */}
563
-              <NavIcons city={curCity} personType={users.personType || personType} iconList={iconList} ></NavIcons>
558
+              <NavIcons city={curCity} personType={personType} iconList={iconList} ></NavIcons>
564
               {/* <View style={propagandaBanner.length > 0 ? "border-bottom:20rpx solid #f5f5f5" : ''}> */}
559
               {/* <View style={propagandaBanner.length > 0 ? "border-bottom:20rpx solid #f5f5f5" : ''}> */}
565
               <View style={(newsShow || propagandaBanner.length > 0) ? "border-bottom:20rpx solid #f5f5f5" : ''}>
560
               <View style={(newsShow || propagandaBanner.length > 0) ? "border-bottom:20rpx solid #f5f5f5" : ''}>
566
                 {/* 展示位轮播图 */}
561
                 {/* 展示位轮播图 */}