Commit ada0952f authored by 李苏's avatar 李苏 💬

退出逻辑适配 hash 模式

parent fb25caaa
...@@ -82,20 +82,21 @@ const user = { ...@@ -82,20 +82,21 @@ const user = {
}, },
// 退出系统 // 退出系统
LogOut({ commit, state }) { LogOut({ commit, state }) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
// logout().then((res) => { // logout().then((res) => {
// resolve() // resolve()
// }).catch(error => { // }).catch(error => {
// reject(error) // reject(error)
// }) // })
commit('SET_TOKEN', '') commit('SET_TOKEN', '')
commit('SET_ROLES', []) commit('SET_ROLES', [])
commit('SET_PERMISSIONS', []) commit('SET_PERMISSIONS', [])
removeToken() removeToken()
location.href="login" location.href="/#login"
}) location.reload();
}, })
},
// 前端 登出 // 前端 登出
FedLogOut({ commit }) { FedLogOut({ commit }) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment