diff --git a/nezha-fronted/src/components/common/rightBox/alertRuleBox.vue b/nezha-fronted/src/components/common/rightBox/alertRuleBox.vue index 5c67b11c0..0ea21a780 100644 --- a/nezha-fronted/src/components/common/rightBox/alertRuleBox.vue +++ b/nezha-fronted/src/components/common/rightBox/alertRuleBox.vue @@ -10,7 +10,7 @@ -
{{editAlertRule.id ? $t("alert.config.editAlertConfig") + " ID:" + editAlertRule.id : $t("alert.config.createAlertConfig")}}
+
{{editAlertRule.id ? $t("alert.config.editAlertConfig") : $t("alert.config.createAlertConfig")}}
diff --git a/nezha-fronted/src/components/common/table/alert/alertMessageTable.vue b/nezha-fronted/src/components/common/table/alert/alertMessageTable.vue index c40dff27c..3312ae31b 100644 --- a/nezha-fronted/src/components/common/table/alert/alertMessageTable.vue +++ b/nezha-fronted/src/components/common/table/alert/alertMessageTable.vue @@ -129,7 +129,7 @@ export default { components: { nzAlertTag, alertRuleInfo: alertRuleInfo, - alertLabel: alertLabel, + alertLabel: alertLabel }, props: { nowTime: { @@ -157,27 +157,26 @@ export default { prop: 'id', show: true, width: 80, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('alert.alertName'), prop: 'alertRule', show: true, width: 180, - sortable:false, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('alert.list.labels'), prop: 'labels', show: true, NotSet: true, minWidth: 250, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('alert.severity'), prop: 'severity', show: true, width: 110, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('alert.summary'), prop: 'summary', @@ -193,18 +192,18 @@ export default { prop: 'remark', show: false, minWidth: 200 - }, { + }, { label: this.$t('alert.startAt'), prop: 'startAt', show: true, width: 150, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('config.terminallog.duration'), prop: 'duration', show: true, width: 150 - }, + } ], viewAssetState: false, tableDataInitNum: 0 @@ -260,9 +259,9 @@ export default { }) return result }, - chartUnitChange:function(unit){ - this.chartUnit=unit; - this.$nextTick(()=>{ + chartUnitChange: function (unit) { + this.chartUnit = unit + this.$nextTick(() => { this.queryChartDate() }) }, @@ -411,8 +410,8 @@ export default { this.queryChartDate() }) }, - dialogClose() { - this.graphShow = false; + dialogClose () { + this.graphShow = false }, getAlertList () { if (!this.scrollbarWrap) { diff --git a/nezha-fronted/src/components/common/table/alert/alertSilenceTable.vue b/nezha-fronted/src/components/common/table/alert/alertSilenceTable.vue index ced27108c..d53ab485d 100644 --- a/nezha-fronted/src/components/common/table/alert/alertSilenceTable.vue +++ b/nezha-fronted/src/components/common/table/alert/alertSilenceTable.vue @@ -168,7 +168,7 @@ export default { if (record.endAt) { return calcDurationByStringTimeB(record.startAt, record.endAt) } - return calcDurationByStringTimeB(record.startAt, this.nowTime) + return calcDurationByStringTimeB(record.startAt, this.utcTimeToTimezoneStr(this.nowTime)) } }, tagType () { diff --git a/nezha-fronted/src/components/common/table/settings/operationLogTable.vue b/nezha-fronted/src/components/common/table/settings/operationLogTable.vue index 1f4a1908f..8fa874664 100644 --- a/nezha-fronted/src/components/common/table/settings/operationLogTable.vue +++ b/nezha-fronted/src/components/common/table/settings/operationLogTable.vue @@ -38,7 +38,7 @@ {{scope.row[item.prop]}} ms {{formatUsername(scope.row)}} - {{scope.row[item.prop]}} + {{utcTimeToTimezoneStr(scope.row[item.prop])}} {{scope.row[item.prop]}} diff --git a/nezha-fronted/src/components/common/table/settings/terminalLogTable.vue b/nezha-fronted/src/components/common/table/settings/terminalLogTable.vue index c740d9184..61c6757b8 100644 --- a/nezha-fronted/src/components/common/table/settings/terminalLogTable.vue +++ b/nezha-fronted/src/components/common/table/settings/terminalLogTable.vue @@ -43,11 +43,14 @@ + {{utcTimeToTimezoneStr(scope.row[item.prop])}} + {{utcTimeToTimezoneStr(scope.row[item.prop])}} {{scope.row[item.prop]}} @@ -89,13 +90,13 @@ export default { prop: 'id', show: true, width: 80, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('config.user.name'), prop: 'name', show: true, width: 150, - sortable:'custom' + sortable: 'custom' }, { label: this.$t('config.user.username'), prop: 'username', diff --git a/nezha-fronted/src/components/page/dashboard/overview/overview.vue b/nezha-fronted/src/components/page/dashboard/overview/overview.vue index eec0a097c..9f1ddfcf0 100644 --- a/nezha-fronted/src/components/page/dashboard/overview/overview.vue +++ b/nezha-fronted/src/components/page/dashboard/overview/overview.vue @@ -109,7 +109,7 @@
- +
{{item.name}} diff --git a/nezha-fronted/src/components/page/dashboard/overview/overview2.vue b/nezha-fronted/src/components/page/dashboard/overview/overview2.vue index 1a517fb75..6c8e9b867 100644 --- a/nezha-fronted/src/components/page/dashboard/overview/overview2.vue +++ b/nezha-fronted/src/components/page/dashboard/overview/overview2.vue @@ -127,7 +127,7 @@
- +
{{item.name}} diff --git a/nezha-fronted/src/libs/bus.js b/nezha-fronted/src/libs/bus.js index 72cd8ea68..4e66a1467 100644 --- a/nezha-fronted/src/libs/bus.js +++ b/nezha-fronted/src/libs/bus.js @@ -338,7 +338,7 @@ export default new Vue({ } else { return configTime } - } + }, }, created () { this.getDefaultDate()