|
|
|
@@ -1,6 +1,8 @@ |
|
|
|
import { clearSessionToken } from '@/access'; |
|
|
|
import { setRemoteMenu } from '@/services/session'; |
|
|
|
import { logout } from '@/services/system/auth'; |
|
|
|
import { ClientInfo } from '@/types'; |
|
|
|
import SessionStorage from '@/utils/sessionStorage'; |
|
|
|
import { gotoLoginPage } from '@/utils/ui'; |
|
|
|
import { LogoutOutlined, UserOutlined } from '@ant-design/icons'; |
|
|
|
import { setAlpha } from '@ant-design/pro-components'; |
|
|
|
@@ -64,11 +66,11 @@ const AvatarDropdown: React.FC<GlobalHeaderRightProps> = ({ menu }) => { |
|
|
|
clearSessionToken(); |
|
|
|
setRemoteMenu(null); |
|
|
|
gotoLoginPage(); |
|
|
|
// const clientInfo: ClientInfo = SessionStorage.getItem(SessionStorage.clientInfoKey, true); |
|
|
|
// if (clientInfo) { |
|
|
|
// const { logoutUri } = clientInfo; |
|
|
|
// location.replace(logoutUri); |
|
|
|
// } |
|
|
|
const clientInfo: ClientInfo = SessionStorage.getItem(SessionStorage.clientInfoKey, true); |
|
|
|
if (clientInfo) { |
|
|
|
const { logoutUri } = clientInfo; |
|
|
|
location.replace(logoutUri); |
|
|
|
} |
|
|
|
}; |
|
|
|
const actionClassName = useEmotionCss(({ token }) => { |
|
|
|
return { |
|
|
|
|