From 2563a5ce60efc163cd9b0813666b18428a03e6eb Mon Sep 17 00:00:00 2001 From: lhzzforever Date: Wed, 9 Oct 2024 17:38:53 +0800 Subject: [PATCH 1/5] =?UTF-8?q?feature:=20=E6=9B=B4=E6=96=B0=E6=89=80?= =?UTF-8?q?=E6=9C=89=E6=96=87=E6=A1=A3=E4=B8=AD=E5=BF=83=E8=B7=B3=E8=BD=AC?= =?UTF-8?q?=E9=93=BE=E6=8E=A5=E6=9C=80=E6=96=B0=E8=A7=84=E8=8C=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/App.vue | 3 ++- frontend/src/components/header-nav/index.vue | 3 ++- frontend/src/views/grading-admin/index.vue | 6 +++--- frontend/src/views/my-manage-space/index.vue | 7 ++++--- frontend/src/views/system-access/index.vue | 5 +++-- 5 files changed, 14 insertions(+), 10 deletions(-) diff --git a/frontend/src/App.vue b/frontend/src/App.vue index ec51dac30..e1907b858 100644 --- a/frontend/src/App.vue +++ b/frontend/src/App.vue @@ -384,12 +384,13 @@ getRouteInstanceSearch (payload = {}) { const { show, routeName } = payload; + const curLang = formatI18nKey().toLowerCase().indexOf('en') > -1 ? 'EN' : 'ZH'; const routeMap = { applyCustomPerm: () => { this.noInstanceSearchData = Object.assign({}, { show: show || false, mode: 'dialog', - url: `/IAM//1.8/UserGuide/Feature/PermissionsApply.md`, + url: `/${curLang}/IAM/1.16/UserGuide/Feature/PermissionsApply.md`, title: this.$t(`m.permApply['未启用用户组自动推荐功能']`), functionalDesc: this.t(`m.permApply['该功能可以根据用户当前的权限需求,自动匹配相关的用户组']`), guideTitle: this.$t(`m.permApply['如需启用该功能,请联系部署同学部署相关ES服务']`), diff --git a/frontend/src/components/header-nav/index.vue b/frontend/src/components/header-nav/index.vue index 8343001d2..e82592648 100644 --- a/frontend/src/components/header-nav/index.vue +++ b/frontend/src/components/header-nav/index.vue @@ -173,7 +173,8 @@ }; }; - const NORMAL_DOCU_LINK = '/IAM/UserGuide/Introduce/README.md'; + const curLang = formatI18nKey().toLowerCase().indexOf('en') > -1 ? 'EN' : 'ZH'; + const NORMAL_DOCU_LINK = `/${curLang}/IAM/1.16/UserGuide/Introduce/README.md`; // const GRADE_DOCU_LINK = '/权限中心/产品白皮书/场景案例/GradingManager.md'; const docuLinkMap = new Map([ diff --git a/frontend/src/views/grading-admin/index.vue b/frontend/src/views/grading-admin/index.vue index bf331f50a..6c6033192 100644 --- a/frontend/src/views/grading-admin/index.vue +++ b/frontend/src/views/grading-admin/index.vue @@ -273,7 +273,7 @@ import _ from 'lodash'; import { mapGetters } from 'vuex'; import { buildURLParams } from '@/common/url'; - import { getWindowHeight, formatCodeData } from '@/common/util'; + import { getWindowHeight, formatCodeData, formatI18nKey } from '@/common/util'; import ConfirmDialog from '@/components/iam-confirm-dialog/index'; import ApplyDialog from './components/apply-join-dialog'; import IamEditInput from '@/views/my-manage-space/components/iam-edit/input'; @@ -864,8 +864,8 @@ }, handleOpenDocu () { - const GRADE_DOCU_LINK = '/IAM/UserGuide/Feature/ManagerCreate.md'; - window.open(`${window.BK_DOCS_URL_PREFIX}${GRADE_DOCU_LINK}`); + const curLang = formatI18nKey().toLowerCase().indexOf('en') > -1 ? 'EN' : 'ZH'; + window.open(`${window.BK_DOCS_URL_PREFIX}/${curLang}/IAM/1.16/UserGuide/Feature/ManagerCreate.md`); } } diff --git a/frontend/src/views/my-manage-space/index.vue b/frontend/src/views/my-manage-space/index.vue index b0c8f53de..bc83c77a1 100644 --- a/frontend/src/views/my-manage-space/index.vue +++ b/frontend/src/views/my-manage-space/index.vue @@ -319,7 +319,7 @@ diff --git a/frontend/src/views/my-manage-space/index.vue b/frontend/src/views/my-manage-space/index.vue index bc83c77a1..af9820dcb 100644 --- a/frontend/src/views/my-manage-space/index.vue +++ b/frontend/src/views/my-manage-space/index.vue @@ -196,9 +196,9 @@ iconColor[1] : iconColor[0] }" /> @@ -224,9 +224,9 @@ @@ -319,7 +319,7 @@