
<script>
	export default {
		onLaunch: function() {
			console.log('App Launch')
			let token = sessionStorage.getItem('token');
			token = typeof(token) != 'undefined' && token != null? token : ''
			//this.$store.commit('setToken',{access_token: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJqd3Rfd3giLCJleHAiOjE2MjYzMzkxNDEsInN1YiI6IllIIiwiYXVkIjoiZXZlcnkiLCJuYmYiOjE2MjYwNzk5NDEsImlhdCI6MTYyNjA3OTk0MSwianRpIjoxMDAwMSwidWlkIjo1OH0.5m6nZ-F8gJVHu1_5d1l1GSxtKGL8xLWvCJgVCEQQ2QM'})
			if((token=='') && this.$router.history.current.path != '/pages/entry/auth'){
				
			}else if(this.$store.state.token){
				uni.setTabBarItem({
					index: 4,
					text: '我的'
				})
			}
		},
		onShow: function() {
			console.log('App Show')
		},
		onHide: function() {
			console.log('App Hide')
		},
	}
</script>

<!-- <style>
	/*每个页面公共css */
</style> -->
<style lang="scss">
	/* 注意要写在第一行，同时给style标签加入lang="scss"属性 */
	@import "uview-ui/index.scss";
</style>
