34 lines
536 B
Vue
34 lines
536 B
Vue
<template>
|
|
<view id="app">
|
|
<!-- 代理端应用入口 -->
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
onLaunch: function() {
|
|
console.log('Agent App Launch')
|
|
this.checkLogin()
|
|
},
|
|
onShow: function() {
|
|
console.log('Agent App Show')
|
|
},
|
|
onHide: function() {
|
|
console.log('Agent App Hide')
|
|
},
|
|
methods: {
|
|
checkLogin() {
|
|
const token = uni.getStorageSync('token')
|
|
if (!token) {
|
|
uni.reLaunch({
|
|
url: '/pages/login/login'
|
|
})
|
|
}
|
|
}
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style>
|
|
@import url("./static/css/common.css");
|
|
</style> |