You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

54 lines
1.0 KiB

1 year ago
<template>
1 year ago
<view class="content">
11 months ago
1 year ago
</view>
1 year ago
</template>
<script>
1 year ago
export default {
data() {
return {
11 months ago
src: '',
isFlag: true
1 year ago
}
},
11 months ago
onHide() {
uni.setStorageSync('isFlag', false)
},
1 year ago
onShow() {
11 months ago
this.gotoMap()
1 year ago
},
10 months ago
// 导航栏点击事件
onTabItemTap() {
this.qdTracker('navButtonClick', {buttonName: '导览', buttonSort: '2'})
},
1 year ago
methods: {
11 months ago
gotoMap() {
// 必须登录
let userInfo = (uni.getStorageSync('userInfo') && JSON.parse(uni.getStorageSync('userInfo'))) || this.$store.state.user.userInfo || {}
if(userInfo.token) {
this.isFlag = uni.getStorageSync('isFlag')
if(this.isFlag) {
this.gotoPath('plugin://guide/index')
}else {
uni.switchTab({
url: '/pages/index/index'
})
}
11 months ago
}else {
11 months ago
this.$store.commit('changeLoginPath')
11 months ago
}
}
1 year ago
}
}
1 year ago
</script>
1 year ago
<style lang="scss" scoped>
.content {
width: 100vw;
height: 100vh;
12 months ago
padding-bottom: env(safe-area-inset-bottom);
padding-top: 100rpx;
text-align: center;
1 year ago
}
1 year ago
</style>