完善数据处理
This commit is contained in:
@@ -186,7 +186,7 @@ type StateType = {
|
|||||||
let state: StateType = reactive({
|
let state: StateType = reactive({
|
||||||
neType: [],
|
neType: [],
|
||||||
chartRealTime: false,
|
chartRealTime: false,
|
||||||
chartLegendSelectedFlag: false,
|
chartLegendSelectedFlag: true,
|
||||||
});
|
});
|
||||||
|
|
||||||
// 存储每个指标的临时固定颜色
|
// 存储每个指标的临时固定颜色
|
||||||
|
|||||||
@@ -551,18 +551,18 @@ function fnRanderChartData() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (const item of orgData) {
|
for (const item of orgData) {
|
||||||
chartDataXAxisData.push(item['timeGroup']);
|
|
||||||
const keys = Object.keys(item);
|
const keys = Object.keys(item);
|
||||||
for (const y of chartDataYSeriesData) {
|
for (const y of chartDataYSeriesData) {
|
||||||
for (const key of keys) {
|
for (const key of keys) {
|
||||||
if (y.key === key) {
|
if (y.key === key) {
|
||||||
y.data.push(+item[key]);
|
y.data.push(+item[key]);
|
||||||
|
chartDataXAxisData.push(item['timeGroup']);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// console.log(queryParams.sortOrder, chartLegendSelected);
|
///console.log(queryParams.sortOrder, chartDataXAxisData);
|
||||||
// console.log(chartDataXAxisData, chartDataYSeriesData);
|
console.log(chartDataXAxisData, chartDataYSeriesData);
|
||||||
|
|
||||||
// 绘制图数据
|
// 绘制图数据
|
||||||
kpiChart.value.setOption(
|
kpiChart.value.setOption(
|
||||||
|
|||||||
Reference in New Issue
Block a user