diff --git a/web/src/components/Auth/AuthPage.vue b/web/src/components/Auth/AuthPage.vue index 877bbb8..7f745da 100644 --- a/web/src/components/Auth/AuthPage.vue +++ b/web/src/components/Auth/AuthPage.vue @@ -35,7 +35,7 @@
-

{{ $t('接入GSEKit进程管理', [appName]) }}

+

{{ $t('接入GSEKit进程管理', [app_name]) }}

- {{ appName }} + {{ app_name }} {{ $t('帮助文档') }} @@ -77,6 +77,9 @@ export default { isEmptyPage() { return this.emptyType === 'page'; }, + app_name() { + return this.$store.state.platform.i18n.name || this.appName + }, }, methods: { handleClick(type) { diff --git a/web/src/components/Header.vue b/web/src/components/Header.vue index 6258388..607767a 100644 --- a/web/src/components/Header.vue +++ b/web/src/components/Header.vue @@ -41,7 +41,7 @@

- {{ $t('注销') }} + {{ $t('退出登录') }}
@@ -70,7 +70,7 @@ export default { }; }, computed: { - ...mapState(['username', 'appName']), + ...mapState(['username', 'appName', 'language']), showStaticRouter() { return this.$store.state.showStaticRouter; }, diff --git a/web/src/language/lang/en.js b/web/src/language/lang/en.js index e420240..d6488b0 100644 --- a/web/src/language/lang/en.js +++ b/web/src/language/lang/en.js @@ -40,7 +40,7 @@ export default { 静态文件加载失败请刷新页面重试: 'Static file loading failed, please refresh the page and try again', // 首页 首页: 'Home', - 注销: 'Logout', + 退出登录: 'Sign out', // 进程管理 进程状态: 'Process Status', 进程管理: 'Process Manage', diff --git a/web/src/language/lang/zh.js b/web/src/language/lang/zh.js index c342981..b45a578 100644 --- a/web/src/language/lang/zh.js +++ b/web/src/language/lang/zh.js @@ -40,7 +40,7 @@ export default { 静态文件加载失败请刷新页面重试: '静态文件加载失败,请刷新页面重试', // 首页 首页: '首页', - 注销: '注销', + 退出登录: '退出登录', // 进程管理 进程状态: '进程状态', 进程管理: '进程管理', diff --git a/web/src/store/modules/platform-config.js b/web/src/store/modules/platform-config.js index a9dd25a..9bae9ff 100644 --- a/web/src/store/modules/platform-config.js +++ b/web/src/store/modules/platform-config.js @@ -42,18 +42,23 @@ export default { }, actions: { async getConfig(context) { - const url = `${window.PROJECT_CONFIG?.BKPAAS_SHARED_RES_URL}/gsekit/base.js` - const config = await getPlatformConfig(url, { + const defaults = { name: 'GSEKit', nameEn: 'GSEKit', appLogo: logoSrc, - brandName: '腾讯蓝鲸智云', + brandName: '蓝鲸智云', brandNameEn: 'BlueKing', favicon: logoSrc, helperLink: window.PROJECT_CONFIG.BKAPP_NAV_HELPER_URL, helperText: window.i18n.t('联系BK助手'), - }); - + } + let config; + if (window.PROJECT_CONFIG?.BKPAAS_SHARED_RES_URL) { + const url = `${window.PROJECT_CONFIG?.BKPAAS_SHARED_RES_URL}/gsekit/base.js`; + config = await getPlatformConfig(url, defaults); + } else { + config = await getPlatformConfig(defaults); + } context.commit('updatePlatformConfig', config); } }