diff --git a/nezha-fronted/src/components/chart/chartMixin.js b/nezha-fronted/src/components/chart/chartMixin.js index 329f3c3d2..7386b6a5a 100644 --- a/nezha-fronted/src/components/chart/chartMixin.js +++ b/nezha-fronted/src/components/chart/chartMixin.js @@ -226,7 +226,6 @@ export default { if (chartInfo.elements) { if (chartInfo.elements[expressionIndex]) { alias = alias + this.handleLegendAlias(legend, chartInfo.elements[expressionIndex].legend, tagKeysArr) - console.log(alias, this.handleLegendAlias(legend, chartInfo.elements[expressionIndex].legend, tagKeysArr), legend, chartInfo.elements[expressionIndex].legend, tagKeysArr) } if (!alias) { alias = chartInfo.elements[expressionIndex].expression || '' diff --git a/nezha-fronted/src/components/common/bottomBox/tabs/notebookTab.vue b/nezha-fronted/src/components/common/bottomBox/tabs/notebookTab.vue index e6c701e71..34c48a6d9 100644 --- a/nezha-fronted/src/components/common/bottomBox/tabs/notebookTab.vue +++ b/nezha-fronted/src/components/common/bottomBox/tabs/notebookTab.vue @@ -176,6 +176,10 @@ export default { let charts = this.$lodash.cloneDeep(this.$refs.notebookList.copyDataList) charts = charts.filter(item => item.name !== 'groupTemp') charts.forEach(item => { + delete item.x + delete item.y + delete item.modifiedName + delete item.oldElements if (item.type === 'text') { delete item.param.isEdit delete item.param.oldText diff --git a/nezha-fronted/src/components/page/notebook/notebookList.vue b/nezha-fronted/src/components/page/notebook/notebookList.vue index 548171b5d..2de237713 100644 --- a/nezha-fronted/src/components/page/notebook/notebookList.vue +++ b/nezha-fronted/src/components/page/notebook/notebookList.vue @@ -101,16 +101,6 @@ export default { this.$refs['chart' + item.id] && this.$refs['chart' + item.id][0] && this.$refs['chart' + item.id][0].getChartData(refreshData) }) }, - resizedEvent (i, newH, newW, newHPx, newWPx) { - // TODO 重新渲染图表,向后端发送put请求 - setTimeout(() => { - this.$refs['chart' + i][0].resize() - this.onScroll(this.scrollTop) - }, 100) - }, - movedEvent (i, newX, newY) { - this.onScroll(this.scrollTop) - }, onScroll (scrollTop = 0) { const self = this if (this.scrollTopTimer) { @@ -165,8 +155,7 @@ export default { const cloneDataList = this.$lodash.cloneDeep(n) const tempList = cloneDataList.map((item, index) => { return { - ...item, - i: item.id + ...item } }) this.$nextTick(() => {