|
@@ -1,5 +1,5 @@
|
|
|
import { login, loginUp, getInfo } from '@/api/login'
|
|
|
-import { getToken, setToken, removeToken, setUserId, TokenKey } from '@/utils/auth'
|
|
|
+import { getToken, setToken, removeToken, setUserId, TokenKey, setLogId, removeLogId } from '@/utils/auth'
|
|
|
import { resetRouter } from '@/router'
|
|
|
import { wsSocketClose } from '@/utils/socket'
|
|
|
const getDefaultState = () => {
|
|
@@ -63,6 +63,7 @@ const actions = {
|
|
|
sessionStorage.setItem("token", returnData.Token);
|
|
|
setToken(TokenKey, returnData.Token);
|
|
|
setToken('FirstLogin', returnData.FirstLogin);
|
|
|
+ setLogId(returnData.LogId)
|
|
|
setUserId(returnData.UserId)
|
|
|
let nowDate = new Date();
|
|
|
let oldDate = new Date(returnData.ValidTime);
|
|
@@ -118,6 +119,7 @@ const actions = {
|
|
|
removeToken('systemSet');
|
|
|
removeToken('FirstLogin');
|
|
|
removeToken('userAuthList');
|
|
|
+ removeLogId()
|
|
|
resetRouter();
|
|
|
commit('RESET_STATE');
|
|
|
commit('SET_ROLES', []);
|