diff --git a/src/pages/package.json b/src/pages/package.json index 2bb44cd1c..b4d8b8a52 100644 --- a/src/pages/package.json +++ b/src/pages/package.json @@ -46,7 +46,7 @@ "art-template": "4.1.0", "axios": "^0.26.1", "babel-preset-env": "^1.7.0", - "bk-magic-vue": "2.5.4-beta.9", + "bk-magic-vue": "^2.5.7", "connect-history-api-fallback": "1.6.0", "cookie": "0.4.0", "cookie-parser": "1.4.4", diff --git a/src/pages/src/components/organization/mixin.js b/src/pages/src/components/organization/mixin.js index 355d3bfc7..ed4c51fa8 100644 --- a/src/pages/src/components/organization/mixin.js +++ b/src/pages/src/components/organization/mixin.js @@ -136,9 +136,6 @@ export default { this.isDirectory = true; this.messageSuccess(msg); this.$emit('updateAcitveNode'); - this.$nextTick(() => { - this.topTreeHeight = this.$refs.treebox.offsetHeight - this.$refs.bottomTree.offsetHeight; - }); } catch (e) { console.warn(e); } diff --git a/src/pages/src/language/lang/en.js b/src/pages/src/language/lang/en.js index e468952c1..55ed2df4c 100644 --- a/src/pages/src/language/lang/en.js +++ b/src/pages/src/language/lang/en.js @@ -574,4 +574,5 @@ export default { '确认要还原当前目录?': 'Restore the current directory?', 无该应用访问权限: 'No access permission for the application', 返回上一页: 'Return to previous page', + 新建目录: 'New directory', }; diff --git a/src/pages/src/language/lang/zh.js b/src/pages/src/language/lang/zh.js index 86524b116..9197c8b27 100644 --- a/src/pages/src/language/lang/zh.js +++ b/src/pages/src/language/lang/zh.js @@ -573,4 +573,5 @@ export default { '确认要还原当前目录?': '确认要还原当前目录?', 无该应用访问权限: '无该应用访问权限', 返回上一页: '返回上一页', + 新建目录: '新建目录', }; diff --git a/src/pages/src/views/organization/index.vue b/src/pages/src/views/organization/index.vue index 52511fbc2..a30f9f0f6 100644 --- a/src/pages/src/views/organization/index.vue +++ b/src/pages/src/views/organization/index.vue @@ -640,6 +640,7 @@ export default { methods: { async initData() { try { + this.treeLoading = true; const res = await this.$store.dispatch('organization/getOrganizationTree'); if (!res.data || !res.data.length) return; this.treeDataList = res.data; @@ -675,6 +676,8 @@ export default { }); }); } + } finally { + this.treeLoading = false; } }, @@ -897,7 +900,7 @@ export default { handleTableSearch(list) { this.isTableDataEmpty = false; this.basicLoading = true; - if (!list.length) return this.handleTableData(); + if (!list.length) return this.handleClickEmpty(); const valueList = [`category_id=${this.currentCategoryId}&page=${this.paginationConfig.current}&page_size=${this.paginationConfig.limit}`]; let key = ''; list.forEach((item) => { @@ -905,6 +908,7 @@ export default { if (Object.keys(this.enumList).includes(item.id)) { key = this.enumList[item.id]; } + if (!item.values) return; item.values.forEach((v) => { value.push(v.id); }); diff --git a/src/pages/src/views/organization/tree/OrganizationTree.vue b/src/pages/src/views/organization/tree/OrganizationTree.vue index be351a331..cd392f3f5 100644 --- a/src/pages/src/views/organization/tree/OrganizationTree.vue +++ b/src/pages/src/views/organization/tree/OrganizationTree.vue @@ -8,11 +8,9 @@ - specific language governing permissions and limitations under the License. -->