diff --git a/nezha-fronted/src/assets/stylus/main.scss b/nezha-fronted/src/assets/stylus/main.scss index c979642ae..bde3c25aa 100644 --- a/nezha-fronted/src/assets/stylus/main.scss +++ b/nezha-fronted/src/assets/stylus/main.scss @@ -53,6 +53,18 @@ li{ .margin-b-20 { margin-bottom: 20px !important; } +.margin-l-30 { + margin-left: 30px !important; +} +.margin-r-30 { + margin-right: 30px !important; +} +.margin-t-30 { + margin-top: 30px !important; +} +.margin-b-30 { + margin-bottom: 30px !important; +} .float-left { float: left; } @@ -986,3 +998,20 @@ li{ .el-date-table td.end-date span, .el-date-table td.start-date span { background-color: $global-text-color-active !important; } + +/* --begin--复选框自定义颜色 */ +.el-checkbox__input.is-focus .el-checkbox__inner, +.el-checkbox__input .el-checkbox__inner:hover, +.el-checkbox__input.is-checked .el-checkbox__inner, +.el-checkbox__input.is-indeterminate .el-checkbox__inner { + border-color: $global-text-color-active; +} + +.el-checkbox__input.is-checked + .el-checkbox__label { + color: $global-text-color-active; +} + +.el-checkbox__input.is-checked .el-checkbox__inner, .asset .content-left .el-checkbox__input.is-indeterminate .el-checkbox__inner { + background-color: $global-text-color-active; +} +/* --end--复选框自定义颜色 */ diff --git a/nezha-fronted/src/components/common/language/cn.js b/nezha-fronted/src/components/common/language/cn.js index ef2205077..227b3770d 100644 --- a/nezha-fronted/src/components/common/language/cn.js +++ b/nezha-fronted/src/components/common/language/cn.js @@ -24,7 +24,11 @@ const cn = { select: '选择', ok: 'Ok', all: '全选', - other: "其他" + other: "其他", + query: '查询', + back: '返回', + unavailable: '不可用', + available: '可用' }, dashboard:{ title:'仪表盘', @@ -335,7 +339,8 @@ const cn = { promId: "Prometheus Server ID", createProm: "新增Prometheus Server", editProm: "修改Prometheus Server", - type: "类别" + type: "类别", + checkTime: '检查时间' }, }, alert: { diff --git a/nezha-fronted/src/components/common/language/en.js b/nezha-fronted/src/components/common/language/en.js index 7a87cf446..487af02b0 100644 --- a/nezha-fronted/src/components/common/language/en.js +++ b/nezha-fronted/src/components/common/language/en.js @@ -32,7 +32,9 @@ const en = { all: 'All',//'全选' other: 'Others',//"其他" query: 'Query', //查询 - back: 'Back' //返回 + back: 'Back', //返回 + unavailable: 'Unavailable', + available: 'Available' }, dashboard:{ title:'Dashboard', @@ -342,7 +344,8 @@ const en = { promId: 'Prometheus server ID',//"Prometheus Server ID" createProm: 'New prometheus server',//"新增Prometheus Server" editProm: 'Edit prometheus server',//"修改Prometheus Server" - type: 'Type'//"类别" + type: 'Type',//"类别" + checkTime: 'Check time' }, }, alert: { diff --git a/nezha-fronted/src/components/common/rightBox/panelBox.vue b/nezha-fronted/src/components/common/rightBox/panelBox.vue index 5c31e972c..4707bbcee 100644 --- a/nezha-fronted/src/components/common/rightBox/panelBox.vue +++ b/nezha-fronted/src/components/common/rightBox/panelBox.vue @@ -95,7 +95,7 @@ if (response.code === 200) { this.esc(); this.$message({duration: 1000, type: 'success', message: this.$t("tip.saveSuccess")}); - this.$emit("reload"); + this.$emit("reload", this.panel.name); } else { this.$message.error(response.msg); } @@ -125,6 +125,6 @@ diff --git a/nezha-fronted/src/components/page/asset/asset.vue b/nezha-fronted/src/components/page/asset/asset.vue index c70efbfa3..ddf7cde7c 100644 --- a/nezha-fronted/src/components/page/asset/asset.vue +++ b/nezha-fronted/src/components/page/asset/asset.vue @@ -703,20 +703,3 @@ margin-right:6px; } - diff --git a/nezha-fronted/src/components/page/config/promServer.vue b/nezha-fronted/src/components/page/config/promServer.vue index d1fa09499..f17fa91ce 100644 --- a/nezha-fronted/src/components/page/config/promServer.vue +++ b/nezha-fronted/src/components/page/config/promServer.vue @@ -60,9 +60,13 @@ - {{scope.row[item.prop] == '1' ? 'Global' : ''}} - {{scope.row[item.prop] == '2' ? 'Per-Datacenter' : ''}} - + {{scope.row[item.prop] == '1' ? 'Global' : ''}} + {{scope.row[item.prop] == '2' ? 'Per-Datacenter' : ''}} + + + {{scope.row[item.prop] == '1' ? $t('overall.available') : ''}} + {{scope.row[item.prop] == '0' ? $t('overall.unavailable') : ''}} +
  {{$t('overall.delete')}} @@ -115,14 +119,16 @@ {{item.name}} - - - - +
+ + + + +
@@ -247,6 +253,14 @@ label: this.$t("config.promServer.type"), prop: 'type', show: true, + }, { + label: this.$t('asset.createAssetTab.state'), + prop: 'status', + show: true + }, { + label: this.$t('config.promServer.checkTime'), + prop: 'checkTime', + show: true }, { label: this.$t('config.account.option'), prop: 'option', diff --git a/nezha-fronted/src/components/page/dashboard/chartBox.vue b/nezha-fronted/src/components/page/dashboard/chartBox.vue index b02605ce6..d708b4ab5 100644 --- a/nezha-fronted/src/components/page/dashboard/chartBox.vue +++ b/nezha-fronted/src/components/page/dashboard/chartBox.vue @@ -46,11 +46,15 @@ .label-center{ margin-top:6px; } - .z-top{ - z-index: 50; + + .z-top { + z-index: 49; } diff --git a/nezha-fronted/src/components/page/dashboard/chartMetric.vue b/nezha-fronted/src/components/page/dashboard/chartMetric.vue index 074ac9bf3..119751437 100644 --- a/nezha-fronted/src/components/page/dashboard/chartMetric.vue +++ b/nezha-fronted/src/components/page/dashboard/chartMetric.vue @@ -106,12 +106,12 @@ @@ -407,6 +407,13 @@ } }); }, + panelReloadOnlyPanel() { //仅刷新panel数据 + this.$get('panel?pageNo=1&pageSize=-1').then(response => { + if (response.code === 200) { + this.panelData = response.data.list; + } + }); + }, getTableData: function () { this.$get('panel?pageNo=1&pageSize=-1').then(response => { if (response.code === 200) { diff --git a/nezha-fronted/src/components/page/project/project.vue b/nezha-fronted/src/components/page/project/project.vue index 7206b3334..bee4d0b9c 100644 --- a/nezha-fronted/src/components/page/project/project.vue +++ b/nezha-fronted/src/components/page/project/project.vue @@ -1,5 +1,11 @@