Просмотр исходного кода

Merge branch 'v3.5.1' into dev

张延森 5 лет назад
Родитель
Сommit
b34d41c75b

+ 3
- 0
.vscode/settings.json Просмотреть файл

@@ -0,0 +1,3 @@
1
+{
2
+  "editor.fontFamily": "'Cascadia Code', Consolas, 'Courier New', monospace"
3
+}

+ 7
- 2
config/dev.js Просмотреть файл

@@ -5,12 +5,17 @@ module.exports = {
5 5
   defineConstants: {
6 6
     // HOST: '"http://47.101.36.130:8085"',//测试
7 7
     // WSS_HOST: '"wss://47.101.36.130:8085"',
8
-    HOST:  '"https://dev.jinchengjiaye.com"',//测试
9
-    WSS_HOST: '"wss://dev.jinchengjiaye.com"',
8
+    // HOST:  '"https://dev.jinchengjiaye.com"',//测试
9
+    // WSS_HOST: '"wss://dev.jinchengjiaye.com"',
10 10
     // HOST: '"https://lt.pawoma.cn"',
11 11
     // WSS_HOST: '"wss://lt.pawoma.cn"',
12
+<<<<<<< HEAD
12 13
     // HOST: '"http://192.168.2.52:8080"',
13 14
     // WSS_HOST: '"ws://192.168.2.52:8080"',
15
+=======
16
+    HOST: '"http://127.0.0.1:8080"',
17
+    WSS_HOST: '"ws://127.0.0.1:8080"',
18
+>>>>>>> v3.5.1
14 19
   },
15 20
   weapp: {},
16 21
   h5: {}

+ 4
- 4
config/prod.js Просмотреть файл

@@ -5,10 +5,10 @@ module.exports = {
5 5
   defineConstants: {
6 6
     // HOST: '"http://192.168.0.218:8080"',
7 7
     // WSS_HOST: '"ws://192.168.0.218:8080"',
8
-    HOST: '"https://dev.jinchengjiaye.com"',
9
-    WSS_HOST: '"wss://dev.jinchengjiaye.com"',
10
-    // HOST: '"https://lt.pawoma.cn"',
11
-    // WSS_HOST: '"wss://lt.pawoma.cn"',
8
+    // HOST: '"https://dev.jinchengjiaye.com"',
9
+    // WSS_HOST: '"wss://dev.jinchengjiaye.com"',
10
+    HOST: '"https://lt.pawoma.cn"',
11
+    WSS_HOST: '"wss://lt.pawoma.cn"',
12 12
   },
13 13
   weapp: {},
14 14
   h5: {}

+ 2
- 2
project.config.json Просмотреть файл

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

+ 1
- 1
src/app.js Просмотреть файл

@@ -182,7 +182,7 @@ class App extends Component {
182 182
   }
183 183
 
184 184
   initData () {
185
-    console.info('app componentDidShow')
185
+    // console.info('app componentDidShow')
186 186
     console.info('router1', this.$router.params)
187 187
     console.info('ready status1', ready)
188 188
 

+ 106
- 44
src/components/TimeTicker/index.jsx Просмотреть файл

@@ -1,16 +1,18 @@
1 1
 import Taro from '@tarojs/taro'
2 2
 import dayjs from 'dayjs'
3
-
4
-// 未开始
5
-const STATUS_READY = -1
6
-
7
-// 进行中
8
-const STATUS_PROCESSING = 0
9
-
10
-// 已结束
11
-const STATUS_OVER = 1
3
+import {
4
+  STATUS_READY,
5
+  STATUS_PROCESSING,
6
+  STATUS_OVER,
7
+  getPreText,
8
+  getTkText,
9
+  isFunction,
10
+} from './utils'
12 11
 
13 12
 export default class TimeTicker extends Taro.Component {
13
+  static options = {
14
+    addGlobalClass: true
15
+  }
14 16
 
15 17
   state = {
16 18
     status: STATUS_READY,
@@ -23,8 +25,17 @@ export default class TimeTicker extends Taro.Component {
23 25
   timer = null
24 26
 
25 27
   componentWillMount() {
28
+    this.computeProps(this.props)
29
+  }
26 30
 
31
+  componentWillReceiveProps(nextProps) {
32
+    this.computeProps(nextProps)
33
+  }
27 34
 
35
+  componentWillUnmount() {
36
+    if (this.timer) {
37
+      clearInterval(this.timer)
38
+    }
28 39
   }
29 40
 
30 41
   computeProps(props) {
@@ -44,62 +55,113 @@ export default class TimeTicker extends Taro.Component {
44 55
 
45 56
     if (!t1 || !t2) {
46 57
       // 只设置了一个时间
47
-      targetTime = t1 ? dayjs(t1).valueOf() : dayjs(t2).valueOf()
48
-
49
-      if (now > targetTime) {
50
-        status = STATUS_OVER
51
-      } else if (now === targetTime) {
52
-        status = STATUS_PROCESSING
53
-      } else {
54
-        status = STATUS_READY
55
-      }
58
+      tmEnd = tmStart = t1 ? dayjs(t1).valueOf() : dayjs(t2).valueOf()
56 59
     } else {
57 60
       // 设置了时间区间
58
-      const dtStart = dayjs(t1).valueOf()
59
-      const dtEnd = dayjs(t2).valueOf()
60
-
61
-      if (dtStart > now) {
62
-        status = STATUS_READY
63
-        targetTime = dtStart
64
-      } else if (dtStart <= now && now < dtEnd) {
65
-        status = STATUS_PROCESSING
66
-        targetTime = dtEnd
67
-      } else {
68
-        status = STATUS_OVER
69
-        targetTime = dtEnd
70
-      }
61
+      tmStart = dayjs(t1).valueOf()
62
+      tmEnd = dayjs(t2).valueOf()
71 63
     }
72 64
 
73
-    this.setState({ status, targetTime }, this.startTimer.bind(this))
65
+    if (tmStart > now) {
66
+      status = STATUS_READY
67
+    } else if (tmStart <= now && now < tmEnd) {
68
+      status = STATUS_PROCESSING
69
+    } else {
70
+      status = STATUS_OVER
71
+    }
72
+
73
+    this.setState({ status, tmStart, tmEnd }, () => this.startTimer(props))
74 74
   }
75 75
 
76
-  startTimer = (props) => {
76
+  computeStatus(props) {
77 77
     const {
78
-      status,
79
-      targetTime,
80
-      interval = 1000,
81 78
       onStart,
82 79
       onProcess,
83 80
       onEnd,
84 81
     } = props || {}
85 82
 
86
-    if (this.timer) {
87
-      clearInterval(this.timer)
83
+    let {
84
+      status,
85
+      tmStart,
86
+      tmEnd,
87
+      preText,
88
+      tkText,
89
+    } = this.state
90
+
91
+    const now = dayjs().valueOf()
92
+    const diff = status === STATUS_READY ? tmStart - now : tmEnd - now
93
+
94
+    if (diff <= 0) {
95
+      if (status === STATUS_READY) {
96
+        status = tmStart === tmEnd ? STATUS_OVER : STATUS_PROCESSING
97
+        
98
+        if (isFunction(onStart)) {
99
+          [preText, tkText] = onStart()
100
+        }
101
+      } else {
102
+        status = STATUS_OVER
103
+        if (this.timer) {
104
+          clearInterval(this.timer)
105
+        }
106
+
107
+        if (isFunction(onEnd)) {
108
+          [preText, tkText] = onEnd()
109
+        }
110
+      }
111
+    } else {
112
+      if (isFunction(onProcess)) {
113
+        [preText, tkText] = onProcess(diff, status)
114
+      }
88 115
     }
89 116
 
90
-    this.timer = setInterval(() => {
91
-      const now = dayjs().valueOf()
92
-      const diff = targetTime - now
117
+    if (preText === undefined) {
118
+      preText = getPreText(diff, status)
119
+    }
120
+    
121
+    if (tkText === undefined) {
122
+      tkText = getTkText(diff, status)
123
+    }
93 124
 
125
+    this.setState({ status, preText, tkText })
126
+  }
94 127
 
128
+  startTimer = (props) => {
129
+    const { interval = 1000 } = props || {}
95 130
 
96
-    }, interval)
131
+    if (this.timer) {
132
+      clearInterval(this.timer)
133
+    }
97 134
 
135
+    // 立即执行一次
136
+    this.computeStatus(props);
137
+    // 再循环执行
138
+    this.timer = setInterval(() => this.computeStatus(props), interval)
98 139
   }
99 140
 
100
-  render() {
101
-    
102 141
 
103 142
 
143
+  classNames = (...args) => {
144
+    return (args || []).reduce((cls, item) => {
145
+      return [].concat(cls).concat(item)
146
+    }, []).filter(x => x).join(' ')
147
+  }
148
+
149
+  render() {
150
+    const wrapperCls = this.classNames('tk-box', this.props.className)
151
+    const headerCls = this.classNames('tk-box-header', this.props.headerClass)
152
+    const bodyCls = this.classNames('tk-box-body', this.props.bodyClass)
153
+
154
+    return (
155
+      <View className={wrapperCls}>
156
+        {
157
+          this.state.preText &&
158
+          (<Text className={headerCls}>{this.state.preText}</Text>)
159
+        }        
160
+        {
161
+          this.state.tkText &&
162
+          (<Text className={bodyCls}>{this.state.tkText}</Text>)
163
+        }        
164
+      </View>
165
+    );
104 166
   }
105 167
 }

+ 23
- 0
src/components/TimeTicker/utils.js Просмотреть файл

@@ -0,0 +1,23 @@
1
+
2
+import { formateLeftTime } from '@utils/tools'
3
+
4
+// 未开始
5
+export const STATUS_READY = -1
6
+
7
+// 进行中
8
+export const STATUS_PROCESSING = 0
9
+
10
+// 已结束
11
+export const STATUS_OVER = 1
12
+
13
+export function getPreText(tk, status) {
14
+  return status === STATUS_OVER ? '已结束' : `距离 ${status === STATUS_READY ? '开始' : '结束'} 还有: `
15
+}
16
+
17
+export function getTkText(tk, status) {
18
+  return status === STATUS_OVER ? '' : formateLeftTime(tk)
19
+}
20
+
21
+export function isFunction(fn) {
22
+  return typeof fn === 'function'
23
+}

+ 19
- 10
src/pages/activity/detail/assemble.js Просмотреть файл

@@ -11,6 +11,7 @@ import dayjs from 'dayjs'
11 11
 // import getUserPhone from '@utils/getUserPhone'
12 12
 import ready from '@utils/ready'
13 13
 import { getDownloadURL, times, formateLeftTime, getCanvasConfig, transferImage } from '@utils/tools'
14
+import { getQrCodeParams } from '@utils/qrcode'
14 15
 import {
15 16
   getGroupDetail,
16 17
   createGroupActivity,
@@ -95,18 +96,26 @@ export default class Detail extends Component {
95 96
   // 初始化页面数据
96 97
   initPageData = () => {
97 98
     if (!this.state.detail.groupActivityId) {
98
-      let id = this.$router.params.id
99
-      let recordId = this.$router.params.recordId
99
+      const router = Taro.getStorageSync('router')
100
+      let id = this.$router.params.id || router.query.id
101
+      let recordId = this.$router.params.recordId || router.query.recordId
100 102
 
101 103
       if (!id) {
102
-        const router = Taro.getStorageSync('router')
103
-        id = router.query.id
104
-        recordId = router.query.recordId
104
+        getQrCodeParams(this.$router.params.scene).then(res => {
105
+          this.setState({ id: res.id, recordId: res.recordId }, () => {
106
+            this.loadDetail()
107
+          })
108
+        }).catch(err => {
109
+          Taro.showToast({
110
+            title: '没有找到活动',
111
+            icon: 'none'
112
+          })
113
+        })
114
+      } else {
115
+        this.setState({ id, recordId }, () => {
116
+          this.loadDetail()
117
+        })
105 118
       }
106
-
107
-      this.setState({ id, recordId }, () => {
108
-        this.loadDetail()
109
-      })
110 119
     }
111 120
   }
112 121
 
@@ -684,4 +693,4 @@ export default class Detail extends Component {
684 693
       </Block>
685 694
     )
686 695
   }
687
-}
696
+}

+ 19
- 9
src/pages/activity/detail/assistance.js Просмотреть файл

@@ -11,6 +11,7 @@ import dayjs from 'dayjs'
11 11
 // import getUserPhone from '@utils/getUserPhone'
12 12
 import ready from '@utils/ready'
13 13
 import { getDownloadURL, times, formateLeftTime, getCanvasConfig, transferImage } from '@utils/tools'
14
+import { getQrCodeParams } from '@utils/qrcode'
14 15
 import {
15 16
   getHelpDetail,
16 17
   createHelpActivity,
@@ -95,18 +96,27 @@ export default class Detail extends Component {
95 96
   // 初始化页面数据
96 97
   initPageData = () => {
97 98
     if (!this.state.detail.helpActivityId) {
98
-      let id = this.$router.params.id
99
-      let initiateId = this.$router.params.initiateId
99
+      const router = Taro.getStorageSync('router')
100
+      let id = this.$router.params.id || router.query.id
101
+      let initiateId = this.$router.params.initiateId || router.query.initiateId
100 102
 
101 103
       if (!id) {
102
-        const router = Taro.getStorageSync('router')
103
-        id = router.query.id
104
-        initiateId = router.query.initiateId
104
+        getQrCodeParams(this.$router.params.scene).then(res => {
105
+          this.setState({ id: res.id, initiateId: res.initiateId }, () => {
106
+            this.loadDetail()
107
+          })
108
+        }).catch(err => {
109
+          Taro.showToast({
110
+            title: '没有找到活动',
111
+            icon: 'none'
112
+          })
113
+        })
114
+      } else {
115
+        this.setState({ id, initiateId }, () => {
116
+          this.loadDetail()
117
+        })
105 118
       }
106 119
 
107
-      this.setState({ id, initiateId }, () => {
108
-        this.loadDetail()
109
-      })
110 120
     }
111 121
   }
112 122
 
@@ -650,4 +660,4 @@ export default class Detail extends Component {
650 660
       </View>
651 661
     )
652 662
   }
653
-}
663
+}

+ 20
- 4
src/pages/activity/detail/index.js Просмотреть файл

@@ -8,6 +8,7 @@ import WxParse from '@components/wxParse/wxParse'
8 8
 import getUserPhone from '@utils/getUserPhone'
9 9
 import ready from '@utils/ready'
10 10
 import { getDownloadURL, times, transferImage } from '@utils/tools'
11
+import { getQrCodeParams } from '@utils/qrcode'
11 12
 import {
12 13
   addActivityShareNum,
13 14
   signupActivity,
@@ -47,10 +48,25 @@ export default class Detail extends Component {
47 48
   componentWillMount() {
48 49
     ready.queue(() => {
49 50
       const router = Taro.getStorageSync('router')
50
-      const id = this.$router.params.id || router.query.id || '2fe920719b8b0db50011441462e647ad'
51
-      this.setState({ id }, () => {
52
-        this.loadDetail()
53
-      })
51
+      // const id = this.$router.params.id || router.query.id || '2fe920719b8b0db50011441462e647ad'
52
+
53
+      const id = this.$router.params.id || router.query.id
54
+      if (!id) {
55
+        getQrCodeParams(this.$router.params.scene).then(res => {
56
+          this.setState({ id: res.id }, () => {
57
+            this.loadDetail()
58
+          })
59
+        }).catch(err => {
60
+          Taro.showToast({
61
+            title: '没有找到活动',
62
+            icon: 'none'
63
+          })
64
+        })
65
+      } else {
66
+        this.setState({ id }, () => {
67
+          this.loadDetail()
68
+        })
69
+      }
54 70
     })
55 71
   }
56 72
   componentWillUnmount() {

+ 13
- 40
src/pages/card/index.js Просмотреть файл

@@ -36,14 +36,11 @@ export default class Index extends Component {
36 36
     recordId: null,
37 37
     isSave: false,
38 38
     bound: false,
39
-    modalStatus: false,
40 39
     grantPhoneVisible: false, // 授权手机弹框
41 40
   }
42 41
 
43 42
   componentWillMount() {
44 43
     ready.queue(() => {
45
-      // const router = Taro.getStorageSync('router')
46
-      // const id = this.$router.params.id || router.query.id || '4604a792d575eb8187711625bd88832c'
47 44
       // 分享场景需要先授权手机, 再授权头像
48 45
       const options = wx.getLaunchOptionsSync()
49 46
       if (sceneInShare(options.scene)) {
@@ -66,19 +63,20 @@ export default class Index extends Component {
66 63
     const router = Taro.getStorageSync('router')
67 64
     const id = this.$router.params.id || router.query.id
68 65
 
69
-    if (router.query.id) {
70
-      this.setState({
71
-        cardId: id,
72
-        modalStatus: true
73
-      }, this.loadCardDetail)
66
+    if (!id) {
67
+      getQrCodeParams(this.$router.params.scene).then(res => {
68
+        this.setState({ cardId: res.id }, this.loadCardDetail)
69
+        addCardUv(res.id)
70
+      }).catch(err => {
71
+        Taro.showToast({
72
+          title: '没有找到卡片',
73
+          icon: 'none'
74
+        })
75
+      })
74 76
     } else {
75
-      this.setState({
76
-        cardId: id,
77
-        modalStatus: false
78
-      }, this.loadCardDetail)
77
+      this.setState({ cardId: id }, this.loadCardDetail)
78
+      addCardUv(id)
79 79
     }
80
-
81
-    addCardUv(id)
82 80
   }
83 81
 
84 82
   componentWillReceiveProps(nextProps) {
@@ -377,7 +375,6 @@ export default class Index extends Component {
377 375
       const { cardInfo, userInfo: { person } } = this.props
378 376
       if (person.personId != cardInfo.id) {
379 377
         reportClient(payload).then(res => {
380
-          this.hideModal()
381 378
           this.setState({ bound: true })
382 379
           if (res !== 'bound') {
383 380
             Taro.showToast({
@@ -439,11 +436,6 @@ export default class Index extends Component {
439 436
     }
440 437
   }
441 438
 
442
-  hideModal() {
443
-    this.setState({
444
-      modalStatus: false
445
-    })
446
-  }
447 439
   handleAuthPhoneSuccess = (phone) => {
448 440
     const { person = {} } = this.props.userInfo || {}
449 441
     if ((person.avatarurl || '').indexOf('wx.qlogo.cn') === -1) {
@@ -463,7 +455,7 @@ export default class Index extends Component {
463 455
     })
464 456
   }
465 457
   render() {
466
-    const { makePosterStatus, posterData, modalStatus, grantPhoneVisible } = this.state
458
+    const { makePosterStatus, posterData, grantPhoneVisible } = this.state
467 459
     const { userInfo, cardInfo, projectDetail } = this.props
468 460
     const { person: { personType, personId, phone, tel } } = userInfo
469 461
     const { unReadNum, picture, visitors, id, isReport } = cardInfo
@@ -475,8 +467,6 @@ export default class Index extends Component {
475 467
     const isConsultant = personType === ROLE_CODE['CONSULTANT']
476 468
     const hadPhone = (phone || tel) ? true : false  // nb
477 469
     const visibleChatBtn = !isConsultant && !isSelf
478
-    // const visibleConfirmModal = modalStatus && !isReport && !isSelf && (personType === ROLE_CODE['DRIFT'] || personType === ROLE_CODE['CUSTOMER'])
479
-    const visibleConfirmModal = modalStatus && !isReport && !isSelf
480 470
     const showAuthPhone = grantPhoneVisible && userInfo.person.personId && !userInfo.person.phone
481 471
     return (
482 472
       <Block>
@@ -487,23 +477,6 @@ export default class Index extends Component {
487 477
           showAuthPhone &&
488 478
           <AchievePhone user={userInfo.person} onCancel={this.handeAuthPhoneFail} onSuccess={this.handleAuthPhoneSuccess}></AchievePhone>
489 479
         }
490
-        {
491
-          // !showAuthPhone && visibleConfirmModal && (
492
-          //   <View className="modal">
493
-          //     <View className="modal-mask" onClick={this.hideModal}></View>
494
-          //     <View className="modal-body">
495
-          //       <View className="modal-body__con">请确认是否成为他的客户?</View>
496
-          //       {
497
-          //         hadPhone ? (
498
-          //           <Button onClick={this.handleModalConfirm} className='modal-body__btn'>确认</Button>
499
-          //         ) : (
500
-          //             <Button open-type="getPhoneNumber" onGetphonenumber={this.handleGetPhone} className='modal-body__btn'>确认</Button>
501
-          //           )
502
-          //       }
503
-          //     </View>
504
-          //   </View>
505
-          // )
506
-        }
507 480
 
508 481
         {this.state.loaded && (
509 482
           <View className='mycard'>

+ 20
- 5
src/pages/news/detail/index.js Просмотреть файл

@@ -8,6 +8,7 @@ import BackHomeBtn from '@components/BackHomeBtn'
8 8
 import Notice from '@components/Notice'
9 9
 import { getMiniQrcode, savePoint, updatePoint } from '@services/common'
10 10
 import { getDownloadURL, transferImage } from '@utils/tools'
11
+import { getQrCodeParams } from '@utils/qrcode'
11 12
 import {
12 13
   addNewsUv,
13 14
   favorNews,
@@ -41,12 +42,26 @@ export default class NewsDetail extends Component {
41 42
       console.info('news-1:', router)
42 43
       console.info('news-2:', this.$router)
43 44
 
44
-      const newsId = this.$router.params.id || router.query.id || '16'
45
+      const newsId = this.$router.params.id || router.query.id
45 46
 
46
-      this.setState({ newsId }, () => {
47
-        this.loadDetail()
48
-        addNewsUv(newsId)
49
-      })
47
+      if (!newsId) {
48
+        getQrCodeParams(this.$router.params.scene).then(res => {
49
+          this.setState({ newsId: res.id }, () => {
50
+            this.loadDetail()
51
+            addNewsUv(res.id)
52
+          })
53
+        }).catch(err => {
54
+          Taro.showToast({
55
+            title: '没有找到资讯',
56
+            icon: 'none'
57
+          })
58
+        })
59
+      } else {
60
+        this.setState({ newsId }, () => {
61
+          this.loadDetail()
62
+          addNewsUv(newsId)
63
+        })
64
+      }
50 65
     })
51 66
   }
52 67
 

+ 22
- 5
src/pages/project/detail/index.js Просмотреть файл

@@ -22,6 +22,7 @@ import 'dayjs/locale/zh-cn' // 按需加载
22 22
 import ready from '@utils/ready'
23 23
 import Notice from '@components/Notice'
24 24
 import { getDownloadURL, transferImage, sceneInShare } from '@utils/tools'
25
+import { getQrCodeParams } from '@utils/qrcode'
25 26
 import { connect } from '@tarojs/redux'
26 27
 import { dispatchProjectDetail } from '@actions/project'
27 28
 import getUserPhone from '@utils/getUserPhone'
@@ -79,7 +80,23 @@ export default class Index extends Component {
79 80
         })
80 81
       }
81 82
 
82
-      this.initPageData()
83
+      
84
+      const router = Taro.getStorageSync('router')
85
+      const id = this.$router.params.id || router.query.id
86
+
87
+      // 没有找到 id , 再重新找一次
88
+      if (!id) {
89
+        getQrCodeParams(this.$router.params.scene).then(res => {
90
+          this.initPageData(res.id)
91
+        }).catch(err => {
92
+          Taro.showToast({
93
+            title: '没有找到项目',
94
+            icon: 'none'
95
+          })
96
+        })
97
+      } else {
98
+        this.initPageData(id)
99
+      }
83 100
     })
84 101
   }
85 102
 
@@ -88,9 +105,9 @@ export default class Index extends Component {
88 105
     recordId && updatePoint(recordId)
89 106
   }
90 107
 
91
-  initPageData () {
92
-    const router = Taro.getStorageSync('router')
93
-    const id = this.$router.params.id || router.query.id
108
+  initPageData (id) {
109
+    console.log('----项目ID---->', id)
110
+
94 111
     // const id='82b54f4a1f5b981df572253792afbfa1' 
95 112
     this.setState({
96 113
       buildingId: id
@@ -502,7 +519,7 @@ export default class Index extends Component {
502 519
       return
503 520
     }
504 521
 
505
-    this.initPageData()
522
+    this.initPageData(this.state.buildingId)
506 523
   }
507 524
 
508 525
   renderBottomMenu () {

+ 2
- 0
src/pages/project/index.js Просмотреть файл

@@ -57,6 +57,8 @@ export default class Index extends Component {
57 57
     ready.queue(() => {
58 58
       this.getLocation()
59 59
 
60
+      Taro.setNavigationBarTitle({ title: this.props.userInfo.miniApp.name })
61
+
60 62
       savePoint({
61 63
         event: 'index',
62 64
         eventType: 'main',