diff --git a/src/utils/api.js b/src/utils/api.js index 3162c88a..aba989fa 100644 --- a/src/utils/api.js +++ b/src/utils/api.js @@ -84,6 +84,7 @@ export const api = { victimLocation: '/interface/detection/security/filter/victimLocation', eventSeverity: '/interface/detection/security/filter/severity', listBasic: '/interface/detection/security/list/basic', + listCount: '/interface/detection/security/list/count', overviewBasic: '/interface/detection/security/detail/overview/basic', overviewEvent: '/interface/detection/security/detail/overview/event' }, @@ -93,6 +94,7 @@ export const api = { eventSeverity: '/interface/detection/performance/filter/severity', activeEntity: '/interface/detection/performance/filter/activeEntity', listBasic: '/interface/detection/performance/list/basic', + listCount: '/interface/detection/performance/list/count', overviewBasic: '/interface/detection/performance/detail/overview/basic' } } diff --git a/src/utils/date-util.js b/src/utils/date-util.js index 071ca43e..62dac86b 100644 --- a/src/utils/date-util.js +++ b/src/utils/date-util.js @@ -40,8 +40,7 @@ export function getNowTime (interval) { endTime } } -//日期格式转换 -export function rTime(date) { - let json_date = new Date(date).toJSON(); - return new Date(new Date(json_date) + 8 * 3600 * 1000).toISOString().replace(/T/g, ' ').replace(/\.[\d]{3}Z/, '') +// 日期格式转换 +export function rTime (date) { + return window.$dayJs.tz(new Date(date)).format('YYYY-MM-DD HH:mm:ss') } diff --git a/src/views/charts/PanelChart.vue b/src/views/charts/PanelChart.vue index dae7e3a9..9e55529d 100644 --- a/src/views/charts/PanelChart.vue +++ b/src/views/charts/PanelChart.vue @@ -45,8 +45,7 @@