forked from angelo/web-retail-h5
48 lines
1.1 KiB
Vue
48 lines
1.1 KiB
Vue
<script>
|
|
import { setToken, removeToken } from '@/config/auth.js'
|
|
export default {
|
|
onLaunch: function (options) {
|
|
if (options.query?.token) {
|
|
setToken(options.query?.token)
|
|
console.log('🌈ad', options.query?.token)
|
|
}
|
|
const whiteList = [
|
|
'pages/shareRegist/index',
|
|
// 'pages/shareRegist/success',
|
|
'pages/login/index',
|
|
// 'pages/wechatPay/bfPay/',
|
|
// 'pages/wechatPay/hfPay/',
|
|
'pages/shareArea/hiList',
|
|
'pages/shareArea/hiOrder',
|
|
'pages/pay/hiPay',
|
|
'pages/pay/success',
|
|
]
|
|
if (whiteList.indexOf(options.path) !== -1) return
|
|
const isRegiestLogin = uni.getStorageSync('regiest-login')
|
|
if (isRegiestLogin) {
|
|
uni.removeStorageSync('regiest-login')
|
|
removeToken()
|
|
}
|
|
this.$store.dispatch('GetInfo')
|
|
this.$store.dispatch('getCarLength')
|
|
uni.hideTabBar({})
|
|
},
|
|
onShow: function () {
|
|
uni.hideTabBar({})
|
|
},
|
|
onHide: function () {},
|
|
}
|
|
</script>
|
|
|
|
<style lang="scss">
|
|
body {
|
|
background-color: #f2f2f2;
|
|
}
|
|
/*每个页面公共css */
|
|
@import '@/uni_modules/uview-ui/index.scss';
|
|
|
|
::v-deep .uni-picker-container {
|
|
z-index: 100000 !important;
|
|
}
|
|
</style>
|