初次进入App时进入登录页

This commit is contained in:
RuoYi 2022-08-01 20:59:12 +08:00
parent 0ca2bd20b8
commit ff1d17eb31
2 changed files with 10 additions and 11 deletions

View File

@ -13,14 +13,16 @@
//
this.initConfig()
//
//#ifdef H5
this.checkLogin()
//#endif
},
initConfig() {
this.globalData.config = config
},
checkLogin() {
if (!getToken()) {
uni.reLaunch({ url: '/pages/login' })
this.$tab.reLaunch('/pages/login')
}
}
}

View File

@ -1,5 +1,10 @@
{
"pages": [{
"path": "pages/login",
"style": {
"navigationBarTitleText": "登录"
}
}, {
"path": "pages/index",
"style": {
"navigationBarTitleText": "若依移动端框架",
@ -50,12 +55,6 @@
"style": {
"navigationBarTitleText": "关于我们"
}
}, {
"path": "pages/login",
"style": {
"navigationBarTitleText": "登录"
}
}, {
"path": "pages/common/webview/index",
"style": {
@ -77,14 +76,12 @@
"iconPath": "static/images/tabbar/home.png",
"selectedIconPath": "static/images/tabbar/home_.png",
"text": "首页"
},
{
}, {
"pagePath": "pages/work/index",
"iconPath": "static/images/tabbar/work.png",
"selectedIconPath": "static/images/tabbar/work_.png",
"text": "工作台"
},
{
}, {
"pagePath": "pages/mine/index",
"iconPath": "static/images/tabbar/mine.png",
"selectedIconPath": "static/images/tabbar/mine_.png",