From 9496d7f8ed37a05078d16a9beb8529c101c17c5c Mon Sep 17 00:00:00 2001 From: "@changcode" Date: Wed, 1 Dec 2021 15:40:07 +0800 Subject: [PATCH 1/2] =?UTF-8?q?style:=20endpoint=20=E6=89=B9=E9=87=8F?= =?UTF-8?q?=E6=96=B0=E5=A2=9E=E6=A0=B7=E5=BC=8F=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/common/rightBox/batchAddEndpoint.vue | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/nezha-fronted/src/components/common/rightBox/batchAddEndpoint.vue b/nezha-fronted/src/components/common/rightBox/batchAddEndpoint.vue index 20bc1fc51..e08d07dc6 100644 --- a/nezha-fronted/src/components/common/rightBox/batchAddEndpoint.vue +++ b/nezha-fronted/src/components/common/rightBox/batchAddEndpoint.vue @@ -10,9 +10,9 @@ -
+
- + Date: Thu, 2 Dec 2021 16:42:37 +0800 Subject: [PATCH 2/2] =?UTF-8?q?NEZ-1378=20fix:=20Module=E5=86=85=E5=AE=B9?= =?UTF-8?q?=E8=BF=87=E9=95=BF=E6=97=B6=E9=BC=A0=E6=A0=87=E6=82=AC=E6=B5=AE?= =?UTF-8?q?=E6=8F=90=E7=A4=BA=EF=BC=8C=E8=A1=A5=E5=85=85=E5=9B=BD=E9=99=85?= =?UTF-8?q?=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../rightBox/administration/modelBox.vue | 6 +-- .../common/rightBox/batchAddEndpoint.vue | 37 ++++++++++++------- .../components/common/rightBox/moduleBox.vue | 8 ++-- .../common/v-selectpagenew/Table.js | 2 +- 4 files changed, 33 insertions(+), 20 deletions(-) diff --git a/nezha-fronted/src/components/common/rightBox/administration/modelBox.vue b/nezha-fronted/src/components/common/rightBox/administration/modelBox.vue index e41313ff9..5a3c2d066 100644 --- a/nezha-fronted/src/components/common/rightBox/administration/modelBox.vue +++ b/nezha-fronted/src/components/common/rightBox/administration/modelBox.vue @@ -90,9 +90,9 @@ export default { chartlList: [], // chart 列表数据 ChartSearchShowFields: [ // ChartSearch 下拉搜索表头 { title: 'ID', data: 'id' }, - { title: this.$t('config.model.titleName'), data: 'name' }, - { title: this.$t('config.model.titleType'), data: 'type' }, - { title: this.$t('overall.remark'), data: 'remark' } + { title: this.$t('config.model.titleName'), data: 'name', key: 'name' }, + { title: this.$t('config.model.titleType'), data: 'type', key: 'type' }, + { title: this.$t('overall.remark'), data: 'remark', key: 'remark' } ], url: 'asset/model', brandUrl: 'asset/brand', diff --git a/nezha-fronted/src/components/common/rightBox/batchAddEndpoint.vue b/nezha-fronted/src/components/common/rightBox/batchAddEndpoint.vue index e08d07dc6..9ca5d7a03 100644 --- a/nezha-fronted/src/components/common/rightBox/batchAddEndpoint.vue +++ b/nezha-fronted/src/components/common/rightBox/batchAddEndpoint.vue @@ -193,7 +193,8 @@ export default { return row.name.substring(0, 12) + '...' } return row.name - } + }, + key: 'name' }, { title: this.$t('project.project.projectName'), @@ -203,7 +204,9 @@ export default { } else { return row.project.name } - } + }, + deep: true, + orjinNME: 'project' }, { title: this.$t('overall.remark'), @@ -211,39 +214,47 @@ export default { if (row.remark && row.remark.length > 15) { return row.remark.substring(0, 12) + '...' } - return row.remark - } + return row.remark = row.remark ? row.remark : '' + }, + key: 'remark' } ], columns: [ { title: 'id', data: 'id' }, { - title: 'name', + title: this.$t('config.model.titleName'), data: function (row) { if (row.name.length > 15) { return row.name.substring(0, 12) + '...' } return row.name - } + }, + key: 'name' }, - { title: 'Manage Ip', data: 'manageIp' }, + { title: 'Manage Ip', data: 'manageIp', key: 'manageIp' }, { - title: 'Type', + title: this.$t('overall.type'), data: (row) => { return row.type ? row.type.name : '' - } + }, + deep: true, + orjinNME: 'type' }, { - title: 'Model', + title: this.$t('overall.model'), data: (row) => { return row.model ? row.model.name : '' - } + }, + deep: true, + orjinNME: 'model' }, { - title: 'Datacenter', + title: this.$t('overall.dc'), data: (row) => { return row.dc ? row.dc.name : '' - } + }, + deep: true, + orjinNME: 'dc' } ], object: {}, diff --git a/nezha-fronted/src/components/common/rightBox/moduleBox.vue b/nezha-fronted/src/components/common/rightBox/moduleBox.vue index 5a1c2fcd5..af96e62c2 100644 --- a/nezha-fronted/src/components/common/rightBox/moduleBox.vue +++ b/nezha-fronted/src/components/common/rightBox/moduleBox.vue @@ -606,9 +606,10 @@ export default { return row.name.substring(0, 12) + '...' } return row.name - } + }, + key: 'name' }, - { title: this.$t('config.model.titleType'), data: 'type' }, + { title: this.$t('config.model.titleType'), data: 'type', key: 'type' }, { title: this.$t('overall.remark'), data: function (row) { @@ -616,7 +617,8 @@ export default { return row.remark.substring(0, 12) + '...' } return row.remark - } + }, + key: 'remark' } ], showAllBasicOption: false, diff --git a/nezha-fronted/src/components/common/v-selectpagenew/Table.js b/nezha-fronted/src/components/common/v-selectpagenew/Table.js index 8fdb63c68..5f2d25af3 100644 --- a/nezha-fronted/src/components/common/v-selectpagenew/Table.js +++ b/nezha-fronted/src/components/common/v-selectpagenew/Table.js @@ -33,7 +33,7 @@ export default { key: idx, domProps: { innerHTML: this.renderColumn(val, col), - title: val[col.title] + title: col.deep ? val[col.orjinNME].name : val[col.key] } }) }))