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.

51 lines
1010 B

<script>
import config from './config'
import store from '@/store'
import {
getToken
} from '@/utils/auth'
export default {
onLaunch: function() {
this.initApp()
},
methods: {
// 初始化应用
initApp() {
// 初始化应用配置
this.initConfig()
// 检查用户登录状态
//#ifdef H5
this.checkLogin()
//#endif
},
initConfig() {
this.globalData.config = config
},
checkLogin() {
if (!getToken()) {
// this.$tab.reLaunch('/pages/login')
}
}
}
}
</script>
<style lang="scss">
/* uni.scss */
@import "@/uni_modules/uview-ui/index.scss";
@import '@/static/scss/index.scss';
//导航栏背景图
.u-navbar__content {
background-image: url('./static/images/contimg/top-bg.png');
background-repeat: no-repeat;
background-size: 100% 100%;
color: #ffffff;
/* 或者 background-size: 100% 100%; */
}
.u-navbar__content__left{
font-weight: bold;
}
</style>