撤销token存在local

This commit is contained in:
fan 2023-03-07 14:26:02 +08:00
parent e5046f3fa8
commit aa4ab3ce91

View File

@ -5,13 +5,13 @@ const TokenKey = 'Admin-Token';
// 设置教学实训仿真系统token, 设置城市轨道交通设计平台token
export function getToken() {
return localStorage.getItem(TokenKey);
return SessionStorage.getItem(TokenKey);
}
export function setToken(token) {
return localStorage.setItem(TokenKey, token);
return SessionStorage.setItem(TokenKey, token);
}
export function removeToken() {
return localStorage.removeItem(TokenKey);
return SessionStorage.removeItem(TokenKey);
}
// 操作sessionStorage