From 3c62b3522e6a760d33aadd2ab8ca68ffbafdbf8a Mon Sep 17 00:00:00 2001 From: xiangxy Date: Sun, 23 Apr 2023 15:44:15 +0800 Subject: [PATCH] change --- src/pages/ProdCount2.vue | 15 ++++++++------- src/pages/StorageMonitor2.vue | 8 ++++---- 2 files changed, 12 insertions(+), 11 deletions(-) diff --git a/src/pages/ProdCount2.vue b/src/pages/ProdCount2.vue index d1a78ac..87387a9 100644 --- a/src/pages/ProdCount2.vue +++ b/src/pages/ProdCount2.vue @@ -132,15 +132,16 @@ export default { // }, async initData () { let res = await productionStatistics() - this.resData = res - this.taskData = [...res.productionTask] - this.realqty = res.materialTask[0].real_qty - this.planqty = res.materialTask[0].plan_qty - this.showNum1 = (res.finishedTask[0].real_qty + '').split('') - this.showNum2 = (res.finishedTask[1].real_qty + '').split('') - this.showNum3 = (res.finishedTask[2].real_qty + '').split('') + this.resData = res.result + this.taskData = [...res.result.productionTask] + this.realqty = res.result.materialTask[0].real_qty + this.planqty = res.result.materialTask[0].plan_qty + this.showNum1 = (res.result.finishedRes[0].real_qty + '').split('') + this.showNum2 = (res.result.finishedRes[1].real_qty + '').split('') + this.showNum3 = (res.result.finishedRes[2].real_qty + '').split('') this.setEchart01() this.setEchart05() + console.log(this.resData.materialTask[0].plan_qty) }, setEchart01 () { let data = [ diff --git a/src/pages/StorageMonitor2.vue b/src/pages/StorageMonitor2.vue index a49e7ca..329581b 100644 --- a/src/pages/StorageMonitor2.vue +++ b/src/pages/StorageMonitor2.vue @@ -239,10 +239,10 @@ export default { }, async initData () { let res = await storageMonitor() - this.array1 = res.materialList - this.array2 = res.productionList - this.group01 = [...res.materialTask] - this.group02 = [...res.productionTask] + this.array1 = res.result.materialList + this.array2 = res.result.productionList + this.group01 = [...res.result.materialTask] + this.group02 = [...res.result.productionTask] // for (let i = 0; i < this.structArr.length; i++) { // for (let j = 0; j < this.group01.length; j++) { // if (this.structArr[i].sequence_number === this.group01[j].sequence_number + '') {