34 lines
639 B
Vue
34 lines
639 B
Vue
<script>
|
|
export default {
|
|
globalData: {
|
|
im: {}
|
|
},
|
|
onLaunch: function() {
|
|
getApp().globalData.im = this.imService
|
|
console.log('App Launch');
|
|
// 缓存token
|
|
uni.getStorage({
|
|
key: "token",
|
|
success: (res) => {
|
|
uni.switchTab({
|
|
url: "/pages/index/index"
|
|
})
|
|
}
|
|
})
|
|
},
|
|
onShow: function() {
|
|
console.log('App Show');
|
|
},
|
|
onHide: function() {
|
|
console.log('App Hide');
|
|
}
|
|
};
|
|
</script>
|
|
|
|
<style lang="scss">
|
|
/*每个页面公共css */
|
|
/* #ifndef APP-PLUS-NVUE */
|
|
@import 'uview-ui/index.scss';
|
|
/* #endif*/
|
|
</style>
|