feat(auth): 重构统一认证并支持平级服务无感登录
This commit is contained in:
1 parent
d79def5519
commit
ca312ea751
64 files changed
+3713
-449
No files matched your search
@@ -3,7 +3,7 @@
|
||||
* 全局路由 path 常量与公开路径判定。
|
||||
*/
|
||||
/** 无需登录即可访问的路由 path */
|
||||
export const PUBLIC_PATHS = ['/', '/login', '/casdoor-callback', '/reset-password'] as const;
|
||||
export const PUBLIC_PATHS = ['/', '/login', '/casdoor-callback', '/reset-password', '/sso/authorize'] as const;
|
||||
|
||||
/** 登录后首页默认跳转的 Agent ID */
|
||||
export const DEFAULT_CHAT_AGENT_ID = 16;
|
||||
|
||||
@@ -1,15 +1,17 @@
|
||||
<script setup lang="ts">
|
||||
/**
|
||||
* shared/layouts/AppHeaderTools.vue
|
||||
* 顶栏工具区:主题与语言切换。
|
||||
* 顶栏工具区:第三方系统、主题与语言切换。
|
||||
*/
|
||||
|
||||
import ThemeToggleButton from '@/shared/components/ThemeToggleButton.vue';
|
||||
import LocaleToggleButton from '@/shared/components/LocaleToggleButton.vue';
|
||||
import { ExternalSystemLinks } from '@/features/sso';
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="flex items-center gap-2">
|
||||
<ExternalSystemLinks />
|
||||
<ThemeToggleButton />
|
||||
<LocaleToggleButton />
|
||||
</div>
|
||||
|
||||
@@ -148,6 +148,7 @@ const clearAuthStorage = (): void => {
|
||||
sessionStorage.removeItem(AUTH_USER_KEY);
|
||||
sessionStorage.removeItem('hxops_wecom_state');
|
||||
sessionStorage.removeItem('hxops_casdoor_state');
|
||||
sessionStorage.removeItem('hxops_sso_continuation');
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
Reference in new issue
Block a user