事件上报登录
This commit is contained in:
@@ -127,15 +127,13 @@ export default {
|
||||
},
|
||||
|
||||
onLoad() {
|
||||
this.autoLogin()
|
||||
},
|
||||
onShow() {
|
||||
this.$nextTick(() => {
|
||||
this.token && this.getUserInfo()
|
||||
this.getDict()
|
||||
this.form.phone = this.user.phone
|
||||
this.form.name = this.user.realName || ''
|
||||
})
|
||||
if (!this.token) {
|
||||
this.autoLogin().then(() => {
|
||||
this.getUser()
|
||||
})
|
||||
} else {
|
||||
this.getUser()
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
@@ -230,6 +228,15 @@ export default {
|
||||
},
|
||||
handleSelectGrid(v) {
|
||||
this.form.girdName = v.girdName
|
||||
},
|
||||
getUser() {
|
||||
this.getUserInfo().then(() => {
|
||||
this.getDict()
|
||||
this.form.phone = this.user.phone
|
||||
this.form.name = this.user.realName || ''
|
||||
}).catch(() => {
|
||||
this.$refs.login.show()
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user