diff --git a/nezha-fronted/src/components/charts/chart-list-group.vue b/nezha-fronted/src/components/charts/chart-list-group.vue index 07206155d..959645101 100644 --- a/nezha-fronted/src/components/charts/chart-list-group.vue +++ b/nezha-fronted/src/components/charts/chart-list-group.vue @@ -1414,11 +1414,12 @@ export default { // 设置图表的尺寸 setChartSize (item, index) { + console.log(item) this.$nextTick(() => { const chartBox = document.getElementById('chart-' + item.id) if (chartBox) { chartBox.style.width = `${(item.span / 12) * 100}%` - chartBox.style.height = `${document.getElementById('listContainer').offsetWidth / 12 * item.height}px` + chartBox.style.height = `${document.getElementById('listContainer' + item.groupId).offsetWidth / 12 * item.height}px` } }) }, diff --git a/nezha-fronted/src/components/common/js/tools.js b/nezha-fronted/src/components/common/js/tools.js index f48d9b74f..0a49f069f 100644 --- a/nezha-fronted/src/components/common/js/tools.js +++ b/nezha-fronted/src/components/common/js/tools.js @@ -399,8 +399,9 @@ export const chartResizeTool = { const chartBlankWidth = this.chartBlankWidth const chartBlankHeight = this.chartBlankHeight const titleHeight = this.titleHeight - const containerWidth = data.groupId ? document.getElementById('listContainer' + data.groupId).offsetWidth - 20 : document.getElementById('listContainer').offsetWidth + const containerWidth = data.groupId ? document.getElementById('listContainer' + data.groupId).offsetWidth + 40 : document.getElementById('listContainer').offsetWidth const step = this.stepWidth(containerWidth) + console.log(originalData,containerWidth) const mouseOriginalX = event.clientX // 鼠标初始坐标 const mouseOriginalY = event.clientY const originalWidth = step * data.span // 图表、阴影初始宽高 diff --git a/nezha-fronted/src/components/common/language/cn.js b/nezha-fronted/src/components/common/language/cn.js index 5943aff7d..efd235c84 100644 --- a/nezha-fronted/src/components/common/language/cn.js +++ b/nezha-fronted/src/components/common/language/cn.js @@ -1403,7 +1403,15 @@ const cn = { basicTypeFile: '路径', basicTypeJournal: '单位', basicTypeSyslog: '监听地址', - basicAppName: '应用名称' + basicAppName: '应用名称', + metrics: '指标', + logs: '日志', + parameter: '参数', + labels2: '标签', + relabel: 'Relabel', + auth: '作者', + basic: '基础', + pipeline: '管道' }, metrics: { metrics: '指标', diff --git a/nezha-fronted/src/components/common/language/en.js b/nezha-fronted/src/components/common/language/en.js index ddb61ebaa..f23abd323 100644 --- a/nezha-fronted/src/components/common/language/en.js +++ b/nezha-fronted/src/components/common/language/en.js @@ -1406,7 +1406,15 @@ const en = { basicTypeFile: 'Path', basicTypeJournal: 'Unit', basicTypeSyslog: 'Listen address', - basicAppName: 'App name' + basicAppName: 'App name', + metrics: 'Metrics', + logs: 'Logs', + parameter: 'Parameter', + labels2: 'Labels', + relabel: 'Relabel', + auth: 'Auth', + basic: 'Basic', + pipeline: 'Pipeline' }, metrics: { metrics: 'Metrics', // "指标" diff --git a/nezha-fronted/src/components/common/rightBox/editEndpointBoxNew.vue b/nezha-fronted/src/components/common/rightBox/editEndpointBoxNew.vue index 9be338db2..eff394826 100644 --- a/nezha-fronted/src/components/common/rightBox/editEndpointBoxNew.vue +++ b/nezha-fronted/src/components/common/rightBox/editEndpointBoxNew.vue @@ -102,13 +102,13 @@