diff --git a/nezha-fronted/src/components/charts/chart-list.vue b/nezha-fronted/src/components/charts/chart-list.vue index 57977005d..fc6dfc3e4 100644 --- a/nezha-fronted/src/components/charts/chart-list.vue +++ b/nezha-fronted/src/components/charts/chart-list.vue @@ -831,7 +831,7 @@ let startTime = ''; let endTime = ''; if (filterType === 'refresh') {//刷新 - const now = new Date(); + const now = new Date(bus.computeTimezone(new Date().getTime())); const origin = new Date(this.filter.end_time); const numInterval = now.getTime() - origin.getTime(); if (numInterval >= 60000) {//大于1分钟,则start、end均往后移numInterval,否则时间不变 diff --git a/nezha-fronted/src/components/charts/chartPreview.vue b/nezha-fronted/src/components/charts/chartPreview.vue index 81d644f4c..e5bfec31a 100644 --- a/nezha-fronted/src/components/charts/chartPreview.vue +++ b/nezha-fronted/src/components/charts/chartPreview.vue @@ -205,7 +205,10 @@ showLegend:true, tableShow:true, urlShow:true, - searchTime: [new Date().setHours(new Date().getHours()-1),new Date()], + searchTime: [ + new Date(bus.computeTimezone(new Date().getTime())).setHours(new Date(bus.computeTimezone(new Date().getTime())).getHours() - 1), + new Date(bus.computeTimezone(new Date().getTime())) + ], //oldSearchTime:[], minHeight:200, chartSpaceHeight:5,//top-border: 1,bottom-border: 1,padding-bottome:3 @@ -221,7 +224,10 @@ // 全屏查看 show(chartInfo) { this.isError = false; - this.searchTime = [new Date().setHours(new Date().getHours()-1),new Date()]; + this.searchTime = [ + new Date(bus.computeTimezone(new Date().getTime())).setHours(new Date(bus.computeTimezone(new Date().getTime())).getHours() - 1), + new Date(bus.computeTimezone(new Date().getTime())) + ]; this.chart = JSON.parse(JSON.stringify(chartInfo)); let chartType= chartInfo.type; @@ -242,7 +248,6 @@ chartContainerId = 'chartAlertListPreview'; } - console.log('previewChart',this.chart,chartContainerId) //设置高度 chart-table this.$nextTick(() => { //const chartBox = document.getElementById('chartPreviewDailog'); @@ -264,7 +269,6 @@ tableBox.style.height = `${height-this.titleHeight-this.pageHeight-25}px`;//-75-32+25 }else{ const chartDiv = document.getElementById(chartContainerId); - console.log('container div',chartDiv) chartDiv.style.height = `${height-this.chartSpaceHeight-this.titleHeight-15}px`; } }); @@ -361,7 +365,7 @@ let startTime = bus.timeFormate(this.searchTime[0], 'yyyy-MM-dd hh:mm:ss'); let endTime = bus.timeFormate(this.searchTime[1], 'yyyy-MM-dd hh:mm:ss'); if(!startTime || !endTime){//如果时间为空,则默认取最近1小时 - let now = new Date(); + let now = new Date(bus.computeTimezone(new Date().getTime())); startTime = bus.timeFormate(now, 'yyyy-MM-dd hh:mm:ss'); endTime = bus.timeFormate(now.setHours(now.getHours()-1), 'yyyy-MM-dd hh:mm:ss'); this.searchTime[0] = startTime; diff --git a/nezha-fronted/src/components/common/rightBox/assetBox.vue b/nezha-fronted/src/components/common/rightBox/assetBox.vue index 198ad8b78..1c7142246 100644 --- a/nezha-fronted/src/components/common/rightBox/assetBox.vue +++ b/nezha-fronted/src/components/common/rightBox/assetBox.vue @@ -267,6 +267,7 @@ this.editAsset.accounts.length > 0 && (this.accountType = this.editAsset.accounts[0].protocol); } this.$set(this.editAsset, "modelId", n.model.id); + this.modelSize = n.model.usize; let initLocationData={ idc: n.idc, cabinet: n.cabinet, diff --git a/nezha-fronted/src/components/common/rightBox/promServerBox.vue b/nezha-fronted/src/components/common/rightBox/promServerBox.vue index 0f225eef4..81cf1919e 100644 --- a/nezha-fronted/src/components/common/rightBox/promServerBox.vue +++ b/nezha-fronted/src/components/common/rightBox/promServerBox.vue @@ -44,7 +44,6 @@ v-model="editPromServer.type" placeholder="" size="small" - popper-class="config-dropdown" :options="$CONSTANTS.promServer.theData" :props="{ multiple: false, checkStrictly: false ,emitPath:false}" clearable> diff --git a/nezha-fronted/src/components/page/dashboard/chartBox.vue b/nezha-fronted/src/components/page/dashboard/chartBox.vue index 1a33fb165..0ee04b00f 100644 --- a/nezha-fronted/src/components/page/dashboard/chartBox.vue +++ b/nezha-fronted/src/components/page/dashboard/chartBox.vue @@ -49,7 +49,7 @@ } .z-top { - z-index: 2900; + /*z-index: 2900;*/ }