Commit fd7d9058 by wusiyi

fix: 修复图表显示错误

parent 12d12d5c
...@@ -30,7 +30,7 @@ export interface statisticData { ...@@ -30,7 +30,7 @@ export interface statisticData {
} }
export interface trendType { export interface trendType {
confirmNum: number // 接单数 confirmNum: number // 接单数
producedNum: number // 生产数 produceNum: number // 生产数
shipmentNum: number // 发货数 shipmentNum: number // 发货数
shipmentRateOf24Hour: number // 24小时发货率 shipmentRateOf24Hour: number // 24小时发货率
shipmentRateOf48Hour: number // 48小时发货率 shipmentRateOf48Hour: number // 48小时发货率
......
...@@ -694,7 +694,6 @@ const createChartOption = (config: typeof chartConfig1) => { ...@@ -694,7 +694,6 @@ const createChartOption = (config: typeof chartConfig1) => {
series: data.series.map((item) => ({ series: data.series.map((item) => ({
name: item.name, name: item.name,
type: 'line', type: 'line',
stack: 'Total',
data: item.data, data: item.data,
smooth: true, smooth: true,
lineStyle: { lineStyle: {
...@@ -832,7 +831,7 @@ const getchartTimes = async (v: string, type: string) => { ...@@ -832,7 +831,7 @@ const getchartTimes = async (v: string, type: string) => {
const updateOrderTrendChart = (data: trendType[], type: number | string) => { const updateOrderTrendChart = (data: trendType[], type: number | string) => {
const confirmNums = data.map((el) => el.confirmNum) const confirmNums = data.map((el) => el.confirmNum)
const producedNums = data.map((el) => el.producedNum) const produceNums = data.map((el) => el.produceNum)
const shipmentNums = data.map((el) => el.shipmentNum) const shipmentNums = data.map((el) => el.shipmentNum)
const startTimes = data.map((el) => el.startTime) const startTimes = data.map((el) => el.startTime)
const timerange = data.map((el) => `${el.startTime}——${el.endTime}`) const timerange = data.map((el) => `${el.startTime}——${el.endTime}`)
...@@ -843,7 +842,7 @@ const updateOrderTrendChart = (data: trendType[], type: number | string) => { ...@@ -843,7 +842,7 @@ const updateOrderTrendChart = (data: trendType[], type: number | string) => {
chartConfig1.value.xAxisData = timerange chartConfig1.value.xAxisData = timerange
} }
chartConfig1.value.series[0].data = confirmNums chartConfig1.value.series[0].data = confirmNums
chartConfig1.value.series[1].data = producedNums chartConfig1.value.series[1].data = produceNums
chartConfig1.value.series[2].data = shipmentNums chartConfig1.value.series[2].data = shipmentNums
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment