From 6b978fa93b3d5d879ac6817a7061986ed8d0b7bd Mon Sep 17 00:00:00 2001 From: lb Date: Thu, 19 Oct 2023 16:22:56 +0800 Subject: [PATCH] done 1019 again --- .../pms/carHistory/components/configs/chart.js | 11 +++++++---- .../pms/carHistory/components/temperatureDialog.vue | 4 ++++ 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/src/views/modules/pms/carHistory/components/configs/chart.js b/src/views/modules/pms/carHistory/components/configs/chart.js index 6ce0432..663687f 100644 --- a/src/views/modules/pms/carHistory/components/configs/chart.js +++ b/src/views/modules/pms/carHistory/components/configs/chart.js @@ -169,6 +169,7 @@ export default ({ x_data, y_data }, graph2) => { dataZoom: { type: 'inside' }, + series: [ { id: 'temp-series', @@ -186,15 +187,17 @@ export default ({ x_data, y_data }, graph2) => { name: '燃气消耗量(m³)', xAxisIndex: 1, yAxisIndex: 1, - data: Array(65) - .fill(1) - .map((val) => Math.floor(Math.random() * 128)), + data: graph2?.gas || [], + // data: Array(65) + // .fill(1) + // .map((val) => Math.floor(Math.random() * 128)), type: "line", }, { id: 'lambda-series', name: 'lambda', - data: [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, 33, 11, 21, 3, 5, 67, 8, 88, 90, 12, 32, 2, 31, 33, null, null], + // data: [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, 33, 11, 21, 3, 5, 67, 8, 88, 90, 12, 32, 2, 31, 33, null, null], + data: [null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, null, ...(graph2?.lambda || []), null, null], xAxisIndex: 0, yAxisIndex: 2, // data: Array(65) diff --git a/src/views/modules/pms/carHistory/components/temperatureDialog.vue b/src/views/modules/pms/carHistory/components/temperatureDialog.vue index aeff206..52239c7 100644 --- a/src/views/modules/pms/carHistory/components/temperatureDialog.vue +++ b/src/views/modules/pms/carHistory/components/temperatureDialog.vue @@ -158,6 +158,10 @@ export default { loadChartConfig({ x_data: null, y_data: this.dataList.map((i) => i.temp1), + }, + { + gas: this.dataList.map((i) => i.press2), + lambda: this.dataList.map((i) => i.remark), }) ); },