From 3beb002bf62a995594fe815605e9a5a3444178e2 Mon Sep 17 00:00:00 2001 From: lhzzforever Date: Mon, 26 Aug 2024 18:01:59 +0800 Subject: [PATCH 1/7] =?UTF-8?q?feature:=20=E4=BC=98=E5=8C=96=E9=9C=80?= =?UTF-8?q?=E6=B1=82=E6=88=91=E7=9A=84=E6=9D=83=E9=99=90=E3=80=81=E7=94=A8?= =?UTF-8?q?=E6=88=B7=E7=BB=84=E7=BB=87=E6=9E=B6=E6=9E=84=E6=A8=A1=E5=9D=97?= =?UTF-8?q?=E5=8E=BB=E6=8E=89ID=E6=90=9C=E7=B4=A2=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/iam-resource-cascade-search/index.vue | 10 +++++----- frontend/src/language/lang/en.js | 5 ++--- frontend/src/language/lang/zh.js | 5 ++--- frontend/src/views/perm/index.vue | 10 +--------- frontend/src/views/user/components/render-depart.vue | 9 +-------- frontend/src/views/user/components/render-user.vue | 9 +-------- 6 files changed, 12 insertions(+), 36 deletions(-) diff --git a/frontend/src/components/iam-resource-cascade-search/index.vue b/frontend/src/components/iam-resource-cascade-search/index.vue index 4040f99ac..cf5230628 100644 --- a/frontend/src/components/iam-resource-cascade-search/index.vue +++ b/frontend/src/components/iam-resource-cascade-search/index.vue @@ -335,11 +335,11 @@ name: this.$t(`m.userGroup['用户组名']`), default: true }, - { - id: 'id', - name: 'ID', - default: true - }, + // { + // id: 'id', + // name: 'ID', + // default: true + // }, { id: 'description', name: this.$t(`m.common['描述']`), diff --git a/frontend/src/language/lang/en.js b/frontend/src/language/lang/en.js index 44481a260..f14916ce0 100644 --- a/frontend/src/language/lang/en.js +++ b/frontend/src/language/lang/en.js @@ -395,8 +395,7 @@ export const m = { '模板名称不能为空': 'Template name cannot be empty', '模板成员不能为空': 'Template member cannot be empty', '模板名称必填, 不允许输入表情字符': 'Template name is required and emoji characters are not allowed to be entered', - '用户组名不允许输入表情字符': 'User group name does not allow input of emoticons', - 'ID必须是一个正整数': 'ID must be a positive integer' + '用户组名不允许输入表情字符': 'User group name does not allow input of emoticons' }, info: { '加入用户组申请成功': 'Apply to join the group successfully', @@ -811,7 +810,7 @@ export const m = { '直接加入人员模板的用户组权限': 'Directly add user group permissions to personnel templates', '通过组织加入人员模板的用户组权限': 'User group permissions for joining member templates through organization', '通过人员模板加入': 'Through Member Template', - '输入ID、用户组名、描述等按回车键进行搜索': 'Enter ID, user group name and description, etc. Press Enter to search' + '输入用户组名、描述等按回车键进行搜索': 'Enter user group name and description, etc. Press Enter to search' }, permTemplate: { '模板名': 'Template name', diff --git a/frontend/src/language/lang/zh.js b/frontend/src/language/lang/zh.js index 69ab8686f..536c163a6 100644 --- a/frontend/src/language/lang/zh.js +++ b/frontend/src/language/lang/zh.js @@ -395,8 +395,7 @@ export const m = { '模板名称不能为空': '模板名称不能为空', '模板成员不能为空': '模板成员不能为空', '模板名称必填, 不允许输入表情字符': '模板名称必填, 不允许输入表情字符', - '用户组名不允许输入表情字符': '用户组名不允许输入表情字符', - 'ID必须是一个正整数': 'ID必须是一个正整数' + '用户组名不允许输入表情字符': '用户组名不允许输入表情字符' }, info: { '加入用户组申请成功': '加入用户组申请成功', @@ -811,7 +810,7 @@ export const m = { '直接加入人员模板的用户组权限': '直接加入人员模板的用户组权限', '通过组织加入人员模板的用户组权限': '通过组织加入人员模板的用户组权限', '通过人员模板加入': '通过人员模板加入', - '输入ID、用户组名、描述等按回车键进行搜索': '输入ID、用户组名、描述等按回车键进行搜索' + '输入用户组名、描述等按回车键进行搜索': '输入用户组名、描述等按回车键进行搜索' }, permTemplate: { '模板名': '模板名', diff --git a/frontend/src/views/perm/index.vue b/frontend/src/views/perm/index.vue index f3c320c69..9f045fcec 100644 --- a/frontend/src/views/perm/index.vue +++ b/frontend/src/views/perm/index.vue @@ -87,7 +87,7 @@ { diff --git a/frontend/src/views/user/components/render-depart.vue b/frontend/src/views/user/components/render-depart.vue index 7dc523f2e..cb44ac1fc 100644 --- a/frontend/src/views/user/components/render-depart.vue +++ b/frontend/src/views/user/components/render-depart.vue @@ -17,7 +17,7 @@ :custom-select-width="customSelectWidth" :min-select-width="'165px'" :max-select-width="'200px'" - :search-select-place-holder="$t(`m.perm['输入ID、用户组名、描述等按回车键进行搜索']`)" + :search-select-place-holder="$t(`m.perm['输入用户组名、描述等按回车键进行搜索']`)" @on-remote-table="handleRemoteTable" @on-refresh-table="handleRefreshTable" @on-input-value="handleInputValue" @@ -398,13 +398,6 @@ }, async fetchRemoteTable (isRefreshCurCount = false) { - if (this.curSearchParams.id) { - const exp = /^[1-9]\d*$/; - if (!exp.test(this.curSearchParams.id)) { - this.curEmptyData = formatCodeData(0, { ...this.curEmptyData, ...{ tipType: 'search' } }, true); - return this.messageWarn(this.$t(`m.verify['ID必须是一个正整数']`)); - } - } const typeMap = { GroupPerm: async () => { this.emptyData = _.cloneDeep(this.curEmptyData); diff --git a/frontend/src/views/user/components/render-user.vue b/frontend/src/views/user/components/render-user.vue index fac59d892..6c8723d55 100644 --- a/frontend/src/views/user/components/render-user.vue +++ b/frontend/src/views/user/components/render-user.vue @@ -10,7 +10,7 @@ :active="active" :min-select-width="'165px'" :max-select-width="'200px'" - :search-select-place-holder="$t(`m.perm['输入ID、用户组名、描述等按回车键进行搜索']`)" + :search-select-place-holder="$t(`m.perm['输入用户组名、描述等按回车键进行搜索']`)" @on-remote-table="handleRemoteTable" @on-refresh-table="handleRefreshTable" @on-input-value="handleInputValue" @@ -505,13 +505,6 @@ async fetchRemoteTable (isRefreshCurCount = false) { // 这里需要拿到所有tab项的total,所以需要调所有接口, 且需要在当前页动态加载tab的label - if (this.curSearchParams.id) { - const exp = /^[1-9]\d*$/; - if (!exp.test(this.curSearchParams.id)) { - this.curEmptyData = formatCodeData(0, { ...this.curEmptyData, ...{ tipType: 'search' } }, true); - return this.messageWarn(this.$t(`m.verify['ID必须是一个正整数']`)); - } - } const typeMap = { GroupPerm: async () => { this.emptyData = _.cloneDeep(this.curEmptyData); From b6390bfc0db0d5441c62eb13c0ced5fa4750686e Mon Sep 17 00:00:00 2001 From: lhzzforever Date: Thu, 29 Aug 2024 11:47:21 +0800 Subject: [PATCH 2/7] =?UTF-8?q?fix:=20=E5=85=BC=E5=AE=B9=E5=AE=B9=E5=99=A8?= =?UTF-8?q?=E5=8C=96=E9=83=A8=E7=BD=B2=E5=A4=96=E9=83=A8=E7=8E=AF=E5=A2=83?= =?UTF-8?q?=E9=9D=9E=E6=A0=B9=E8=B7=AF=E5=BE=84=E7=9A=84path?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/index.html | 1 - frontend/src/common/util.js | 2 +- frontend/src/router/ce.js | 4 ++-- frontend/src/router/ee.js | 5 +++-- frontend/src/router/ieod.js | 7 ++++--- 5 files changed, 10 insertions(+), 9 deletions(-) diff --git a/frontend/index.html b/frontend/index.html index eea14bc38..a07356c3f 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -6,7 +6,6 @@ - 权限中心 | 蓝鲸智云
diff --git a/frontend/src/common/util.js b/frontend/src/common/util.js index 873fdf058..7c979018c 100644 --- a/frontend/src/common/util.js +++ b/frontend/src/common/util.js @@ -827,5 +827,5 @@ export function getCopyValue (value) { */ export const getRoutePath = (subPath) => { const path = subPath.startsWith('/') ? subPath.slice(1) : subPath; - return rootPath ? `${rootPath}${path}` : path; + return rootPath ? `${rootPath}${path}` : subPath; }; diff --git a/frontend/src/router/ce.js b/frontend/src/router/ce.js index 54413d7cd..f1c5a0dba 100644 --- a/frontend/src/router/ce.js +++ b/frontend/src/router/ce.js @@ -25,7 +25,6 @@ */ import il8n from '@/language'; -import { rootPath } from '@blueking/sub-saas/dist/main.js'; import { getRoutePath } from '@/common/util'; // const SITE_URL = window.SITE_URL; @@ -210,9 +209,10 @@ const NotFound = () => import(/* webpackChunkName: 'none' */ '../views/404'); // Main const MainEntry = () => import(/* webpackChunkName: 'index' */ '../views'); +const SITE_URL = getRoutePath(window.SITE_URL); export const routes = [ { - path: rootPath, + path: SITE_URL, name: 'iamMain', component: MainEntry, children: [ diff --git a/frontend/src/router/ee.js b/frontend/src/router/ee.js index 4b5c4a988..cf90171ee 100644 --- a/frontend/src/router/ee.js +++ b/frontend/src/router/ee.js @@ -25,7 +25,6 @@ */ import il8n from '@/language'; -import { rootPath } from '@blueking/sub-saas/dist/main.js'; import { getRoutePath } from '@/common/util'; // 系统接入 @@ -208,9 +207,11 @@ const NotFound = () => import(/* webpackChunkName: 'none' */ '../views/404'); // Main const MainEntry = () => import(/* webpackChunkName: 'index' */ '../views'); +const SITE_URL = getRoutePath(window.SITE_URL); + export const routes = [ { - path: rootPath, + path: SITE_URL, name: 'iamMain', component: MainEntry, children: [ diff --git a/frontend/src/router/ieod.js b/frontend/src/router/ieod.js index 6649378ef..cb6e09f1b 100644 --- a/frontend/src/router/ieod.js +++ b/frontend/src/router/ieod.js @@ -25,7 +25,6 @@ */ import il8n from '@/language'; -import { rootPath } from '@blueking/sub-saas/dist/main.js'; import { getRoutePath } from '@/common/util'; // 系统接入 @@ -207,11 +206,13 @@ const NotFound = () => import(/* webpackChunkName: 'none' */ '../views/404'); // Main const MainEntry = () => import(/* webpackChunkName: 'index' */ '../views'); - +// 兼容容器化部署外部环境非根路径的path +const SITE_URL = getRoutePath(window.SITE_URL); +console.log(SITE_URL); export const routes = [ { // path: window.SITE_URL, - path: rootPath, + path: SITE_URL, name: 'iamMain', component: MainEntry, children: [ From ed79229a72687543b5c25f9bae534fa31b9aea26 Mon Sep 17 00:00:00 2001 From: lhzzforever Date: Thu, 29 Aug 2024 11:52:01 +0800 Subject: [PATCH 3/7] =?UTF-8?q?fix:=20=E5=85=BC=E5=AE=B9=E9=9D=9E=E6=A0=B9?= =?UTF-8?q?=E8=B7=AF=E5=BE=84=E7=9A=84path?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/router/ce.js | 1 + frontend/src/router/ieod.js | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/frontend/src/router/ce.js b/frontend/src/router/ce.js index f1c5a0dba..87118155f 100644 --- a/frontend/src/router/ce.js +++ b/frontend/src/router/ce.js @@ -210,6 +210,7 @@ const NotFound = () => import(/* webpackChunkName: 'none' */ '../views/404'); const MainEntry = () => import(/* webpackChunkName: 'index' */ '../views'); const SITE_URL = getRoutePath(window.SITE_URL); + export const routes = [ { path: SITE_URL, diff --git a/frontend/src/router/ieod.js b/frontend/src/router/ieod.js index cb6e09f1b..016bc69dc 100644 --- a/frontend/src/router/ieod.js +++ b/frontend/src/router/ieod.js @@ -206,9 +206,10 @@ const NotFound = () => import(/* webpackChunkName: 'none' */ '../views/404'); // Main const MainEntry = () => import(/* webpackChunkName: 'index' */ '../views'); + // 兼容容器化部署外部环境非根路径的path const SITE_URL = getRoutePath(window.SITE_URL); -console.log(SITE_URL); + export const routes = [ { // path: window.SITE_URL, From 77f1d3f4ba50a2e0cb9ebf337b57b614b9a8bc2d Mon Sep 17 00:00:00 2001 From: lhzzforever Date: Thu, 29 Aug 2024 18:17:19 +0800 Subject: [PATCH 4/7] =?UTF-8?q?fix:=20=E4=BC=98=E5=8C=96=E8=93=9D=E7=9B=BE?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E4=BA=BA=E5=91=98=E5=86=85=E5=B5=8C=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E8=8E=B7=E5=8F=96=E7=BB=84=E7=BB=87=E6=9E=B6=E6=9E=84?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E8=B0=83=E7=94=A8=E5=A4=9A=E6=AC=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/views/my-manage-space/add-member-boundary/index.vue | 1 - 1 file changed, 1 deletion(-) diff --git a/frontend/src/views/my-manage-space/add-member-boundary/index.vue b/frontend/src/views/my-manage-space/add-member-boundary/index.vue index 40b257614..6c2fa9720 100644 --- a/frontend/src/views/my-manage-space/add-member-boundary/index.vue +++ b/frontend/src/views/my-manage-space/add-member-boundary/index.vue @@ -666,7 +666,6 @@ } }, created () { - this.fetchInitData(); this.$once('hook:beforeDestroy', () => { bus.$off('edit-member-boundary'); }); From fdad341cb86b2c210362a22a8e6ffdf1e8361e20 Mon Sep 17 00:00:00 2001 From: lhzzforever Date: Mon, 2 Sep 2024 11:19:56 +0800 Subject: [PATCH 5/7] =?UTF-8?q?fix:=20=20=E6=88=91=E7=9A=84=E6=9D=83?= =?UTF-8?q?=E9=99=90=E9=9D=9E=E8=B5=84=E6=BA=90=E5=AE=9E=E4=BE=8B=E6=90=9C?= =?UTF-8?q?=E7=B4=A2=E5=A2=9E=E5=8A=A0=E7=B3=BB=E7=BB=9F=E7=AD=9B=E9=80=89?= =?UTF-8?q?(https://github.com/TencentBlueKing/bk-iam-saas/issues/2794)=20?= =?UTF-8?q?feature:=20=E5=8E=BB=E6=8E=89=E7=BB=84=E6=9D=83=E9=99=90?= =?UTF-8?q?=E6=9D=83=E9=99=90=E6=A8=A1=E6=9D=BF=E5=88=B7=E6=96=B0icon(http?= =?UTF-8?q?s://github.com/TencentBlueKing/bk-iam-saas/issues/2795)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../group/components/add-group-perm-sideslider.vue | 4 ++-- .../components/add-group-perm-sideslider.vue | 8 ++++---- .../perm-apply/apply-join-user-group/index.vue | 14 +++++++++++++- 3 files changed, 19 insertions(+), 7 deletions(-) diff --git a/frontend/src/views/group/components/add-group-perm-sideslider.vue b/frontend/src/views/group/components/add-group-perm-sideslider.vue index 8e9a39b16..ad0881fcd 100644 --- a/frontend/src/views/group/components/add-group-perm-sideslider.vue +++ b/frontend/src/views/group/components/add-group-perm-sideslider.vue @@ -32,7 +32,8 @@ :data="searchData" :value="searchValue" :quick-search-method="quickSearchMethod" - style="width: 240px; display: inline-block;" /> + style="width: 240px; display: inline-block;" + />
@@ -361,7 +362,6 @@ showSelectionCount: false }); this.currentBackup = 1; - this.currentSelectList = []; this.requestQueueBySys = []; this.requestQueueByTemplate = []; this.selection = []; diff --git a/frontend/src/views/manage-spaces/secondary-manage-space/components/add-group-perm-sideslider.vue b/frontend/src/views/manage-spaces/secondary-manage-space/components/add-group-perm-sideslider.vue index f994a250a..aef472fd8 100644 --- a/frontend/src/views/manage-spaces/secondary-manage-space/components/add-group-perm-sideslider.vue +++ b/frontend/src/views/manage-spaces/secondary-manage-space/components/add-group-perm-sideslider.vue @@ -32,12 +32,13 @@ :data="searchData" :value="searchValue" :quick-search-method="quickSearchMethod" - style="width: 240px; display: inline-block;" /> -
+
@@ -351,7 +352,6 @@ showSelectionCount: false }); this.currentBackup = 1; - this.currentSelectList = []; this.requestQueueBySys = []; this.requestQueueByTemplate = []; this.selection = []; diff --git a/frontend/src/views/perm-apply/apply-join-user-group/index.vue b/frontend/src/views/perm-apply/apply-join-user-group/index.vue index 1f9f00af9..3c59faa9b 100644 --- a/frontend/src/views/perm-apply/apply-join-user-group/index.vue +++ b/frontend/src/views/perm-apply/apply-join-user-group/index.vue @@ -581,6 +581,7 @@ remoteMethod: this.handleGradeAdmin } ], + searchData: [], enableGroupInstanceSearch: window.ENABLE_GROUP_INSTANCE_SEARCH.toLowerCase() === 'true', curSelectMenu: '', curInputText: '', @@ -644,7 +645,7 @@ 'is_selected': true } ]; - this.searchData = this.enableGroupInstanceSearch ? this.initSearchData.filter(item => ['name', 'id', 'description', 'role_id'].includes(item.id)) : this.initSearchData; + this.searchData = this.enableGroupInstanceSearch ? this.initSearchData.filter(item => ['name', 'id', 'description', 'system_id', 'role_id'].includes(item.id)) : this.initSearchData; this.setCurrentQueryCache(this.refreshCurrentQuery()); const isObject = (payload) => { return Object.prototype.toString.call(payload) === '[object Object]'; @@ -1267,6 +1268,17 @@ // this.requestQueue.shift() } }, + + async handleRemoteSystem (value) { + const params = {}; + if (this.externalSystemId) { + params.hidden = false; + } + const result = await this.$store.dispatch('system/getSystems', params).then(({ data }) => { + return data.map(({ id, name }) => ({ id, name })).filter((item) => item.name.indexOf(value) > -1); + }); + return result || []; + }, // 管理空间数据 handleGradeAdmin (value) { From 174d20e3700b3f34bc3ec8e13fad353b54850307 Mon Sep 17 00:00:00 2001 From: lhzzforever Date: Mon, 2 Sep 2024 11:25:31 +0800 Subject: [PATCH 6/7] =?UTF-8?q?fix:=20=E6=B7=BB=E5=8A=A0=E6=BC=8F=E7=BC=BA?= =?UTF-8?q?=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/views/group/components/add-group-perm-sideslider.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/views/group/components/add-group-perm-sideslider.vue b/frontend/src/views/group/components/add-group-perm-sideslider.vue index ad0881fcd..eebca7eb0 100644 --- a/frontend/src/views/group/components/add-group-perm-sideslider.vue +++ b/frontend/src/views/group/components/add-group-perm-sideslider.vue @@ -34,11 +34,11 @@ :quick-search-method="quickSearchMethod" style="width: 240px; display: inline-block;" /> -
-
+
--> From 17b3e8d5e052b38ae50bc28f80b3659ad105a239 Mon Sep 17 00:00:00 2001 From: nannan00 <17491932+nannan00@users.noreply.github.com> Date: Mon, 2 Sep 2024 12:02:21 +0800 Subject: [PATCH 7/7] docs: v1.10.33 version log --- saas/VERSION | 2 +- saas/resources/version_log/change_log.md | 11 +++++++++++ saas/resources/version_log/change_log_en.md | 11 +++++++++++ 3 files changed, 23 insertions(+), 1 deletion(-) diff --git a/saas/VERSION b/saas/VERSION index 4cbb00665..9fa8be307 100644 --- a/saas/VERSION +++ b/saas/VERSION @@ -1 +1 @@ -1.10.32 +1.10.33 diff --git a/saas/resources/version_log/change_log.md b/saas/resources/version_log/change_log.md index 892076106..ebcaaaf96 100644 --- a/saas/resources/version_log/change_log.md +++ b/saas/resources/version_log/change_log.md @@ -1,3 +1,14 @@ + +# V1.10.33 版本更新日志 + +### 缺陷修复 + +* 申请加入用户组资源实例搜索增加系统筛选 +* 组权限添加权限模板去掉刷新icon +* 兼容容器化部署外部环境非根路径的path + +--- + # V1.10.32 版本更新日志 diff --git a/saas/resources/version_log/change_log_en.md b/saas/resources/version_log/change_log_en.md index 618a0827f..92bcbaea5 100644 --- a/saas/resources/version_log/change_log_en.md +++ b/saas/resources/version_log/change_log_en.md @@ -1,3 +1,14 @@ + +# V1.10.33 Version Update Log + +### Bug Fixes + +* Added system filter to the resource instance search when applying to join a user group. +* Removed the refresh icon from the permission template addition in group permissions. +* Compatible with non-root path deployment in containerized external environments. + +--- + # V1.10.32 Version Update Log