用户信息更新方法

This commit is contained in:
pixel
2019-10-17 22:15:22 +08:00
parent c2085011fb
commit da4bd9387c
2 changed files with 9 additions and 4 deletions
+5 -1
View File
@@ -30,8 +30,12 @@ export const user = {
state.token = ""
state.expiresAt = ""
router.push({ name: 'login', replace: true })
},
ResetUserInfo(state, userInfo = {}) {
state.userInfo = {...state.userInfo,
...userInfo
}
}
},
actions: {
async LoginIn({ commit }, loginInfo) {