diff --git a/nezha-fronted/src/components/common/mixin/table.js b/nezha-fronted/src/components/common/mixin/table.js index ec8078517..e7034f5ca 100644 --- a/nezha-fronted/src/components/common/mixin/table.js +++ b/nezha-fronted/src/components/common/mixin/table.js @@ -68,11 +68,15 @@ export default { }, tableDataSort (item) { let orderBy = '' + let str = item.prop + if (str === 'dc') { + str = 'datacenter' + } if (item.order === 'ascending') { - orderBy = item.prop + orderBy = str } if (item.order === 'descending') { - orderBy = '-' + item.prop + orderBy = '-' + str } this.$emit('orderBy', orderBy) } diff --git a/nezha-fronted/src/components/common/rightBox/administration/roleBox.vue b/nezha-fronted/src/components/common/rightBox/administration/roleBox.vue index 6576752cb..072ef601e 100644 --- a/nezha-fronted/src/components/common/rightBox/administration/roleBox.vue +++ b/nezha-fronted/src/components/common/rightBox/administration/roleBox.vue @@ -165,7 +165,9 @@ export default { this.$refs.roleForm.validate((valid) => { if (valid) { if (this.editRole.id) { + this.editRole.i18n = this.editRole.name this.$put(this.url, this.editRole).then(res => { + console.log(this.editRole) this.prevent_opt.save = false if (res.code === 200) { this.$message({ duration: 2000, type: 'success', message: this.$t('tip.saveSuccess') }) diff --git a/nezha-fronted/src/components/common/rightBox/administration/userBox.vue b/nezha-fronted/src/components/common/rightBox/administration/userBox.vue index 0b8da0a1b..e925468b4 100644 --- a/nezha-fronted/src/components/common/rightBox/administration/userBox.vue +++ b/nezha-fronted/src/components/common/rightBox/administration/userBox.vue @@ -109,7 +109,7 @@ export default { } else { callback() } - }; + } return { editUser: {}, url: 'sys/user', diff --git a/nezha-fronted/src/components/common/rightBox/setting/cabinetBox.vue b/nezha-fronted/src/components/common/rightBox/setting/cabinetBox.vue index 6766b1491..7d1d35d83 100644 --- a/nezha-fronted/src/components/common/rightBox/setting/cabinetBox.vue +++ b/nezha-fronted/src/components/common/rightBox/setting/cabinetBox.vue @@ -55,9 +55,6 @@ export default { ] } } - }, - created() { - }, methods: { clickOutside () { diff --git a/nezha-fronted/src/components/common/searchInput.vue b/nezha-fronted/src/components/common/searchInput.vue index 1ca6e7fde..ad02a898a 100644 --- a/nezha-fronted/src/components/common/searchInput.vue +++ b/nezha-fronted/src/components/common/searchInput.vue @@ -1652,14 +1652,17 @@ export default { top: 0px; } .localStorage_list_box .list_box_content{ - text-align: left; - padding: 5px 0; - box-sizing: border-box; - border-bottom: 1px solid #dfdfdf; + text-align: left; + padding: 5px 0; + box-sizing: border-box; + border-bottom: 1px solid #dfdfdf; } .localStorage_list_box ul li{ - padding: 5px 10px; - line-height: 20px; + padding: 5px 10px; + line-height: 20px; + text-overflow: ellipsis; + overflow: hidden; + white-space: nowrap; } .localStorage_list_box ul li:hover{ background: #f0f0f0; @@ -1670,7 +1673,8 @@ export default { color: #2e2e2e; } .localStorage_list_box ul li .value{ - font-weight: 600; + font-weight: 600; + width: 350px; } .localStorage_list_box .list_box_clear{ padding-left: 10px; diff --git a/nezha-fronted/src/components/common/table/settings/agentTable.vue b/nezha-fronted/src/components/common/table/settings/agentTable.vue index 364f2ecfc..c23eeb620 100644 --- a/nezha-fronted/src/components/common/table/settings/agentTable.vue +++ b/nezha-fronted/src/components/common/table/settings/agentTable.vue @@ -86,12 +86,12 @@ export default { prop: 'id', show: true, width: 80, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('config.agent.dataCenter'), prop: 'dc', show: true, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('config.agent.host'), prop: 'host', @@ -104,12 +104,12 @@ export default { label: this.$t('config.agent.type'), prop: 'type', show: true, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('asset.state'), prop: 'status', show: true, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('config.agent.checkTime'), prop: 'checkTime',