From a76fbf8b51de1fa6798918e50a91c371308d9fbe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=9C=E7=AC=99=E6=AD=8C?= <2277317060@qq.com> Date: Wed, 13 Mar 2024 16:31:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/board/finalAssembly/index.vue | 61 +++--- src/views/board/foaming/index2.vue | 2 - src/views/board/pourInto/index2.vue | 112 +++++----- src/views/board/scanDown/index.vue | 73 ++----- src/views/board/week/index.vue | 278 +++++++++++------------- 5 files changed, 230 insertions(+), 296 deletions(-) diff --git a/src/views/board/finalAssembly/index.vue b/src/views/board/finalAssembly/index.vue index 99f061f..34a4c2c 100644 --- a/src/views/board/finalAssembly/index.vue +++ b/src/views/board/finalAssembly/index.vue @@ -8,16 +8,16 @@
班组
上线数量
-
{{ info.bz }}
-
{{ info.sxsl }}
+
{{ info1.X_VALUE }}
+
{{ info1.Y_VALUE }}
-
产品条码: {{ info.tm }}
-
扫描时间: {{ info.sj }}
-
产品型号: {{ info.xh }}
-
订单编号: {{ info.bh }}
-
订单数量: {{ info.ddsl }}
-
上线数量: {{ info.sxsl2 }}
-
提示信息: {{ info.tsxx }}
+
产品条码: {{ info.COLUMN_A }}
+
扫描时间: {{ info.COLUMN_E }}
+
产品型号: {{ info.COLUMN_B }}
+
订单编号: {{ info.COLUMN_F }}
+
订单数量: {{ info.COLUMN_C }}
+
上线数量: {{ info.COLUMN_G }}
+
提示信息: {{ info.COLUMN_D }}
@@ -60,35 +60,35 @@
- {{ index + 1 }} + {{ item.COLUMN_A }}
- {{ item.value1 }} + {{ item.COLUMN_B }}
- {{ item.value2 }} + {{ item.COLUMN_C }}
- {{ item.value3 }} + {{ item.COLUMN_D }}
- {{ item.value4 }} + {{ item.COLUMN_E }}
- {{ item.value7 }} + {{ item.COLUMN_F }}
- {{ item.value5 }} + {{ item.COLUMN_G }}
- {{ item.value6 }} + {{ item.COLUMN_H }}
@@ -139,6 +139,7 @@ export default { }, ], info: {}, + info1: {}, scrollTableOption: { step: 0.5, // 数值越大速度滚动越快 limitMoveNum: 10, // 开始无缝滚动的数据量 this.dataList.length @@ -153,14 +154,14 @@ export default { RequestDataSet: [ { e: 'zzsc-01', - i: "", + i: "scada_zz_scan_bar_01('')", f: (e) => { - this.info = e + this.info = e[0] } }, { e: 'zzsc-02', - i: "", + i: "scada_zz_sx_hour_01('')", f: (e) => { this.$refs.chart1.setData({ tooltip: { @@ -179,7 +180,7 @@ export default { }, xAxis: { type: "category", - data: e.x, + data: e.map(v=>v.X_VALUE), axisLine: { lineStyle: { color: "white", @@ -243,7 +244,7 @@ export default { ]), }, }, - data: e.y.data, + data: e.map(v=>v.Y_VALUE), }, ], }) @@ -251,7 +252,7 @@ export default { }, { e: 'zzsc-03', - i: "", + i: "scada_zz_sx_xh_01('')", f: (e) => { this.$refs.chart2.setData({ grid: { @@ -262,7 +263,7 @@ export default { containLabel: true, }, xAxis: { - data: e.x, + data: e.map(v=>v.X_VALUE), axisLine: { lineStyle: { color: "#3d5269", @@ -331,7 +332,7 @@ export default { position: "top", }, }, - data: e.y.data, + data: e.map(v=>v.Y_VALUE), }, ], }) @@ -339,11 +340,18 @@ export default { }, { e: 'zzsc-04', - i: "", + i: "scada_zz_sc_tj_01('')", f: (e) => { this.scrollTableData = e } }, + { + e: 'zzsc-05', + i: "scada_zz_bz_sum_01('')", + f: (e) => { + this.info1 = e[0] || {} + } + }, ] } @@ -360,7 +368,6 @@ export default { }, methods: {}, beforeDestroy() { - console.log(1) if(intervalFun){ clearInterval(intervalFun) intervalFun = null diff --git a/src/views/board/foaming/index2.vue b/src/views/board/foaming/index2.vue index 8798f83..8c22805 100644 --- a/src/views/board/foaming/index2.vue +++ b/src/views/board/foaming/index2.vue @@ -756,7 +756,6 @@ export default { e: 'xm-08', i: "scada_pp_zt_jp_01('')", f: (e) => { - // console.log(e) this.status1 = e[0]?.X_VALUE this.status2 = e[0]?.X_VALUE this.meter1 = e[0]?.Y_VALUE_ONE @@ -781,7 +780,6 @@ export default { }, 1000 * 10) }, beforeDestroy() { - console.log(1) if(intervalFun){ clearInterval(intervalFun) intervalFun = null diff --git a/src/views/board/pourInto/index2.vue b/src/views/board/pourInto/index2.vue index d2d2e7b..ad6f8ca 100644 --- a/src/views/board/pourInto/index2.vue +++ b/src/views/board/pourInto/index2.vue @@ -202,11 +202,11 @@
- {{ item.value1 }} + {{ item.X_VALUE }}
- {{ item.value2 }} + {{ item.Y_VALUE }}
@@ -247,11 +247,11 @@
- {{ item.value1 }} + {{ item.X_VALUE }}
- {{ item.value2 }} + {{ item.Y_VALUE }}
@@ -292,11 +292,11 @@
- {{ item.value1 }} + {{ item.X_VALUE }}
- {{ item.value2 }} + {{ item.Y_VALUE }}
@@ -337,11 +337,11 @@
- {{ item.value1 }} + {{ item.X_VALUE }}
- {{ item.value2 }} + {{ item.Y_VALUE }}
@@ -492,34 +492,33 @@ export default { scrollTableData2: [], scrollTableData3: [], scrollTableData4: [], - RequestDataSet: [ { e: 'zzgx-01', i: "scada_zz_up_gz_01('CX_02')", f: (e) => { - this.gz = e[0] + this.gz = e[0] || {} } }, { e: 'zzgx-02', i: "scada_zz_up_dj_01('CX_02')", f: (e) => { - this.dj = e[0] + this.dj =e[0] || {} } }, { e: 'zzgx-03', i: "scada_zz_up_xn_01('CX_02')", f: (e) => { - this.zl = e[0] + this.zl =e[0] || {} } }, { e: 'zzgx-04', i: "scada_zz_up_jl_01('CX_02')", f: (e) => { - this.gdy = e[0] + this.gdy = e[0] || {} } }, { @@ -544,10 +543,10 @@ export default { type: "pie", radius: "70%", center: ["50%", "50%"], - data: e.map(val=>{ + data: e.map(val => { return { - name:val.X_VALUE, - value:val.Y_VALUE + name: val.X_VALUE, + value: val.Y_VALUE } }), itemStyle: { @@ -573,8 +572,9 @@ export default { }, { e: 'zzgx-07', - i: "", + i: "scada_zz_up_gz_02('CX_02')", f: (e) => { + let data = e[0] this.$refs.chart11.setData({ series: [ { @@ -597,7 +597,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.value1, + value: (parseFloat(data.Y_VALUE_ONE) === 0 ? 0.01 : parseFloat(data.Y_VALUE_ONE)), label: { normal: { rich: { @@ -616,7 +616,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value1 + + parseFloat(data.Y_VALUE_ONE) + "}" + "\n{b|总数}" ); @@ -676,7 +676,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.value2, + value: (parseFloat(data.Y_VALUE_TWO) === 0 ? 0.01 : parseFloat(data.Y_VALUE_TWO)), label: { normal: { rich: { @@ -695,7 +695,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value2 + + parseFloat(data.Y_VALUE_TWO) + "}" + "\n{b|合格数}" ); @@ -755,7 +755,7 @@ export default { center: ["50%", "50%"], data: [ { - value: parseFloat(e.value3), + value: (parseFloat(data.X_VALUE) === 0 ? 0.01 : parseFloat(data.X_VALUE)), label: { normal: { rich: { @@ -774,7 +774,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value3 + + parseFloat(data.X_VALUE) + "%}" + "\n{b|合格率}" ); @@ -797,7 +797,7 @@ export default { }, }, { - value: parseFloat((100 - parseFloat(e.value3)).toFixed(2)), + value: parseFloat((100 - parseFloat(data.X_VALUE)).toFixed(2)), name: "invisible", itemStyle: { normal: { @@ -816,15 +816,16 @@ export default { }, { e: 'zzgx-08', - i: "", + i: "scada_zz_up_gz_03('CX_02')", f: (e) => { this.scrollTableData1 = e } }, { e: 'zzgx-09', - i: "", + i: "scada_zz_up_dj_02('CX_02')", f: (e) => { + let data = e[0] this.$refs.chart21.setData({ series: [ { @@ -847,7 +848,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.value1, + value: (parseFloat(data.Y_VALUE_ONE) === 0 ? 0.01 : parseFloat(data.Y_VALUE_ONE)), label: { normal: { rich: { @@ -866,7 +867,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value1 + + parseFloat(data.Y_VALUE_ONE) + "}" + "\n{b|总数}" ); @@ -926,7 +927,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.value2, + value: (parseFloat(data.Y_VALUE_TWO) === 0 ? 0.01 : parseFloat(data.Y_VALUE_TWO)), label: { normal: { rich: { @@ -945,7 +946,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value2 + + parseFloat(data.Y_VALUE_TWO) + "}" + "\n{b|合格数}" ); @@ -1005,7 +1006,7 @@ export default { center: ["50%", "50%"], data: [ { - value: parseFloat(e.value3), + value: (parseFloat(data.X_VALUE) === 0 ? 0.01 : parseFloat(data.X_VALUE)), label: { normal: { rich: { @@ -1024,7 +1025,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value3 + + parseFloat(data.X_VALUE) + "%}" + "\n{b|合格率}" ); @@ -1047,7 +1048,7 @@ export default { }, }, { - value: parseFloat((100 - parseFloat(e.value3)).toFixed(2)), + value: parseFloat((100 - parseFloat(data.X_VALUE)).toFixed(2)), name: "invisible", itemStyle: { normal: { @@ -1066,15 +1067,16 @@ export default { }, { e: 'zzgx-10', - i: "", + i: "scada_zz_up_dj_03('CX_02')", f: (e) => { this.scrollTableData2 = e } }, { e: 'zzgx-11', - i: "SCADA_INV_STATS_01('')", + i: "scada_zz_up_xn_02('CX_02')", f: (e) => { + let data = e[0] this.$refs.chart31.setData({ series: [ { @@ -1097,7 +1099,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.value1, + value:(parseFloat(data.Y_VALUE_ONE) === 0 ? 0.01 : parseFloat(data.Y_VALUE_ONE)), label: { normal: { rich: { @@ -1116,7 +1118,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value1 + + parseFloat(data.Y_VALUE_ONE) + "}" + "\n{b|总数}" ); @@ -1176,7 +1178,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.value2, + value: (parseFloat(data.Y_VALUE_TWO) === 0 ? 0.01 : parseFloat(data.Y_VALUE_TWO)), label: { normal: { rich: { @@ -1195,7 +1197,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value2 + + parseFloat(data.Y_VALUE_TWO) + "}" + "\n{b|合格数}" ); @@ -1255,7 +1257,7 @@ export default { center: ["50%", "50%"], data: [ { - value: parseFloat(e.value3), + value: (parseFloat(data.X_VALUE) === 0 ? 0.01 : parseFloat(data.X_VALUE)), label: { normal: { rich: { @@ -1274,7 +1276,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value3 + + parseFloat(data.X_VALUE) + "%}" + "\n{b|合格率}" ); @@ -1297,7 +1299,7 @@ export default { }, }, { - value: parseFloat((100 - parseFloat(e.value3)).toFixed(2)), + value: parseFloat((100 - parseFloat(data.X_VALUE)).toFixed(2)), name: "invisible", itemStyle: { normal: { @@ -1316,15 +1318,16 @@ export default { }, { e: 'zzgx-12', - i: "", + i: "scada_zz_up_xn_03('CX_02')", f: (e) => { this.scrollTableData3 = e } }, { e: 'zzgx-13', - i: "", + i: "scada_zz_up_jl_02('CX_02')", f: (e) => { + let data = e[0] this.$refs.chart41.setData({ series: [ { @@ -1347,7 +1350,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.value1, + value:(parseFloat(data.Y_VALUE_ONE) === 0 ? 0.01 : parseFloat(data.Y_VALUE_ONE)), label: { normal: { rich: { @@ -1366,7 +1369,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value1 + + parseFloat(data.Y_VALUE_ONE) + "}" + "\n{b|总数}" ); @@ -1426,7 +1429,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.value2, + value: (parseFloat(data.Y_VALUE_TWO) === 0 ? 0.01 : parseFloat(data.Y_VALUE_TWO)), label: { normal: { rich: { @@ -1445,7 +1448,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value2 + + parseFloat(data.Y_VALUE_TWO) + "}" + "\n{b|合格数}" ); @@ -1505,7 +1508,7 @@ export default { center: ["50%", "50%"], data: [ { - value: parseFloat(e.value3), + value: (parseFloat(data.X_VALUE) === 0 ? 0.01 : parseFloat(data.X_VALUE)), label: { normal: { rich: { @@ -1524,7 +1527,7 @@ export default { formatter: function (params) { return ( "{a|" + - e.value3 + + parseFloat(data.X_VALUE) + "%}" + "\n{b|合格率}" ); @@ -1547,7 +1550,7 @@ export default { }, }, { - value: parseFloat((100 - parseFloat(e.value3)).toFixed(2)), + value: parseFloat((100 - parseFloat(data.X_VALUE)).toFixed(2)), name: "invisible", itemStyle: { normal: { @@ -1566,7 +1569,7 @@ export default { }, { e: 'zzgx-14', - i: "", + i: "scada_zz_up_jl_03('CX_02')", f: (e) => { this.scrollTableData4 = e } @@ -1710,8 +1713,7 @@ export default { } }, beforeDestroy() { - console.log(1) - if(intervalFun){ + if (intervalFun) { clearInterval(intervalFun) intervalFun = null } @@ -2028,7 +2030,7 @@ export default { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; - vertical-align:top + vertical-align: top } } diff --git a/src/views/board/scanDown/index.vue b/src/views/board/scanDown/index.vue index 4511000..237570a 100644 --- a/src/views/board/scanDown/index.vue +++ b/src/views/board/scanDown/index.vue @@ -179,6 +179,11 @@ export default { e: 'cp-1-01', i: "scada_cp_cp_cl_01('CX_01')", f: (e) => { + this.finishedProductOutput = { + mb: e.reduce((v1, v2) => v1 + v2.Y_VALUE_TWO, 0), + jdmb: 1, + sj: e.reduce((v1, v2) => v1 + v2.Y_VALUE_ONE, 0), + } this.$refs.chart1.setData({ tooltip: { trigger: 'axis', @@ -290,7 +295,6 @@ export default { normal: { barBorderRadius: 5, color: function (val) { - console.log() if (e[val.dataIndex].Y_VALUE_ONE >= e[val.dataIndex].Y_VALUE_TWO) { return '#30e391' } else { @@ -338,13 +342,6 @@ export default { }) } }, - { - e: 'cp-1-02', - i: "", - f: (e) => { - this.finishedProductOutput = e - } - }, { e: 'cp-1-03', i: "scada_cp_zj_01('CX_01')", @@ -433,7 +430,6 @@ export default { itemStyle: { normal: { color: function (val) { - console.log() if (e[val.dataIndex].Y_VALUE_TWO < 3) { return '#30e391' } else { @@ -479,13 +475,6 @@ export default { }) } }, - { - e: 'cp-1-04', - i: "", - f: (e) => { - this.finalInspection = e - } - }, { e: 'cp-1-05', i: "scada_cp_rk_jp_01('CX_01')", @@ -494,12 +483,6 @@ export default { this.meter = e[0].Y_VALUE } }, - { - e: 'cp-1-06', - i: "", - f: (e) => { - } - }, { e: 'cp-1-07', i: "scada_cp_rk_loss_01('CX_01')", @@ -595,13 +578,7 @@ export default { i: "scada_cp_rk_order_01('CX_01')", f: (e) => { this.scrollTableData = e - } - }, - { - e: 'cp-1-09', - i: "", - f: (e) => { - this.zhddhj = e + this.zhddhj = e.reduce((v1, v2) => v1 + v2.COLUMN_D, 0) } }, ], @@ -610,6 +587,11 @@ export default { e: 'cp-2-01', i: "scada_cp_cp_cl_01('CX_02')", f: (e) => { + this.finishedProductOutput = { + mb: e.reduce((v1, v2) => v1 + v2.Y_VALUE_TWO, 0), + jdmb: 1, + sj: e.reduce((v1, v2) => v1 + v2.Y_VALUE_ONE, 0), + } this.$refs.chart1.setData({ tooltip: { trigger: 'axis', @@ -721,7 +703,6 @@ export default { normal: { barBorderRadius: 5, color: function (val) { - console.log() if (e[val.dataIndex].Y_VALUE_ONE >= e[val.dataIndex].Y_VALUE_TWO) { return '#30e391' } else { @@ -769,13 +750,6 @@ export default { }) } }, - { - e: 'cp-2-02', - i: "", - f: (e) => { - this.finishedProductOutput = e - } - }, { e: 'cp-2-03', i: "scada_cp_zj_01('CX_02')", @@ -864,7 +838,6 @@ export default { itemStyle: { normal: { color: function (val) { - console.log() if (e[val.dataIndex].Y_VALUE_TWO < 3) { return '#30e391' } else { @@ -910,13 +883,6 @@ export default { }) } }, - { - e: 'cp-2-04', - i: "", - f: (e) => { - this.finalInspection = e - } - }, { e: 'cp-2-05', i: "scada_cp_rk_jp_01('CX_02')", @@ -925,13 +891,6 @@ export default { this.meter = e[0].Y_VALUE } }, - { - e: 'cp-2-06', - i: "", - f: (e) => { - this.meter = e - } - }, { e: 'cp-2-07', i: "scada_cp_rk_loss_01('CX_02')", @@ -1027,13 +986,7 @@ export default { i: "scada_cp_rk_order_01('CX_02')", f: (e) => { this.scrollTableData = e - } - }, - { - e: 'cp-2-09', - i: "", - f: (e) => { - this.zhddhj = e + this.zhddhj = e.reduce((v1, v2) => v1 + v2.COLUMN_D, 0) } }, ] @@ -1089,7 +1042,7 @@ export default { }, methods: {}, beforeDestroy() { - if(intervalFun){ + if (intervalFun) { clearInterval(intervalFun) intervalFun = null } diff --git a/src/views/board/week/index.vue b/src/views/board/week/index.vue index 12afbd8..36182e2 100644 --- a/src/views/board/week/index.vue +++ b/src/views/board/week/index.vue @@ -26,10 +26,10 @@
序号
-
+
订单编号
-
+
产品型号
@@ -56,27 +56,27 @@
- {{ index + 1 }} + {{ item.COLUMN_A }}
- {{ item.value1 }} + class="scrollTableItem" style=" width:20%;"> + {{ item.COLUMN_B }}
- {{ item.value2 }} + class="scrollTableItem" style="width: 37%"> + {{ item.COLUMN_C }}
- {{ item.value3 }} + {{ item.COLUMN_D }}
- {{ item.value4 }} + {{ item.COLUMN_E }}
- {{ item.value5 }} + {{ item.COLUMN_F }}
@@ -117,7 +117,7 @@
合计:{{ totalNum }}台
订单数量:{{ info1.ddsl }} 完成数量:{{ info1.wcsl }} 清单率:{{ - ((info1.wcsl / info1.ddsl) * 100).toFixed(2) + info1.wcsl === 0 ? 0 : ((info1.wcsl / info1.ddsl) * 100).toFixed(2) }}%
@@ -196,8 +196,9 @@ export default { RequestDataSet: [ { e: 'zh-1-01', - i: "", + i: "scada_aq_pro_tj_02('CX_01')", f: (e) => { + this.totalNum = e.reduce((v1, v2) => v1 + v2.Y_VALUE_TWO, 0) this.$refs.topLeft.setData({ grid: { top: "20%", @@ -214,7 +215,7 @@ export default { }, legend: { right: '0', - data: e.y.map(e => e.name), + data: ['计划产量', '实际产量'], textStyle: { fontSize: 0.75 * vw, color: "#F1F1F3", @@ -232,7 +233,7 @@ export default { color: "#F1F1F3", }, }, - data: e.x + data: e.map(e => e.X_VALUE), } ], yAxis: [ @@ -253,7 +254,7 @@ export default { ], series: [ { - name: e.y[0].name, + name: '计划产量', type: 'bar', barGap: 0, emphasis: { @@ -276,10 +277,10 @@ export default { fontSize: 0.75 * vw }, }, - data: e.y[0].data, + data: e.map(e => e.Y_VALUE_ONE), }, { - name: e.y[1].name, + name: '实际产量', type: 'bar', emphasis: { focus: 'series' @@ -302,33 +303,23 @@ export default { color: true ? '#9ce375' : "#4FD3B9", }, }, - data: e.y[1].data, + data: e.map(e => e.Y_VALUE_TWO), }, ] }) } }, - { - e: 'zh-1-02', - i: "", - f: (e) => { - this.totalNum = e - } - }, { e: 'zh-1-03', - i: "", + i: "scada_aq_pro_three_02('CX_01')", f: (e) => { + this.info1 = { + ddsl: e.reduce((v1, v2) => v1 + parseFloat(v2.COLUMN_D) || 0, 0), + wcsl: e.reduce((v1, v2) => v1 + parseFloat(v2.COLUMN_E) || 0, 0) + } this.scrollTableData = e } }, - { - e: 'zh-1-04', - i: "", - f: (e) => { - this.info1 = e - } - }, { e: 'zh-1-05', i: "", @@ -507,7 +498,7 @@ export default { }, { e: 'zh-1-06', - i: "", + i: "scada_aq_pro_xh_02('CX_01')", f: (e) => { this.$refs.productionEfficiency.setData({ grid: { @@ -519,7 +510,7 @@ export default { }, dataZoom: [], xAxis: { - data: e.x, + data: e.map(e => e.X_VALUE), axisLine: { lineStyle: { color: "#0177d4", @@ -586,7 +577,7 @@ export default { fontSize: 0.75 * vw }, }, - data: e.y.sort().reverse(), + data: e.map(e => e.Y_VALUE), }, ], }) @@ -594,8 +585,9 @@ export default { }, { e: 'zh-1-07', - i: "", + i: "scada_aq_zj_gx_01('')", f: (e) => { + let data = e[0] || {} this.$refs.equipmentPowerOne.setData({ series: [ { @@ -618,7 +610,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.nd, + value: parseFloat(data.COLUMN_A), label: { normal: { rich: { @@ -637,7 +629,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_A) + "%}" + "\n{b|内胆检漏}" ); @@ -660,7 +652,7 @@ export default { }, }, { - value: 100 - e.nd, + value: 100 - parseFloat(data.COLUMN_A), name: "invisible", itemStyle: { normal: { @@ -697,7 +689,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.gz, + value: parseFloat(data.COLUMN_B), label: { normal: { rich: { @@ -716,7 +708,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_B) + "%}" + "\n{b|灌注}" ); @@ -739,7 +731,7 @@ export default { }, }, { - value: 100 - e.gz, + value: 100 - parseFloat(data.COLUMN_B), name: "invisible", itemStyle: { normal: { @@ -776,7 +768,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.dy, + value: parseFloat(data.COLUMN_C), label: { normal: { rich: { @@ -795,7 +787,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_C) + "%}" + "\n{b|低压检漏}" ); @@ -818,7 +810,7 @@ export default { }, }, { - value: 100 - e.dy, + value: 100 - parseFloat(data.COLUMN_C), name: "invisible", itemStyle: { normal: { @@ -855,7 +847,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.ag, + value: parseFloat(data.COLUMN_D), label: { normal: { rich: { @@ -874,7 +866,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_D) + "%}" + "\n{b|安规检}" ); @@ -897,7 +889,7 @@ export default { }, }, { - value: 100 - e.ag, + value: 100 - parseFloat(data.COLUMN_D), name: "invisible", itemStyle: { normal: { @@ -934,7 +926,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.cw, + value: parseFloat(data.COLUMN_E), label: { normal: { rich: { @@ -953,7 +945,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_E) + "%}" + "\n{b|测温}" ); @@ -976,7 +968,7 @@ export default { }, }, { - value: 100 - e.cw, + value: 100 - parseFloat(data.COLUMN_E), name: "invisible", itemStyle: { normal: { @@ -1013,7 +1005,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.zj, + value: parseFloat(data.COLUMN_F), label: { normal: { rich: { @@ -1032,7 +1024,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_F) + "%}" + "\n{b|终检}" ); @@ -1055,7 +1047,7 @@ export default { }, }, { - value: 100 - e.zj, + value: 100 - parseFloat(data.COLUMN_F), name: "invisible", itemStyle: { normal: { @@ -1076,8 +1068,9 @@ export default { RequestDataSet1: [ { e: 'zh-2-01', - i: "", + i: "scada_aq_pro_tj_02('CX_02')", f: (e) => { + this.totalNum = e.reduce((v1, v2) => v1 + v2.Y_VALUE_TWO, 0) this.$refs.topLeft.setData({ grid: { top: "20%", @@ -1094,7 +1087,7 @@ export default { }, legend: { right: '0', - data: e.y.map(e => e.name), + data: ['计划产量', '实际产量'], textStyle: { fontSize: 0.75 * vw, color: "#F1F1F3", @@ -1112,7 +1105,7 @@ export default { color: "#F1F1F3", }, }, - data: e.x + data: e.map(e => e.X_VALUE), } ], yAxis: [ @@ -1133,7 +1126,7 @@ export default { ], series: [ { - name: e.y[0].name, + name: '计划产量', type: 'bar', barGap: 0, emphasis: { @@ -1156,10 +1149,10 @@ export default { fontSize: 0.75 * vw }, }, - data: e.y[0].data, + data: e.map(e => e.Y_VALUE_ONE), }, { - name: e.y[1].name, + name: '实际产量', type: 'bar', emphasis: { focus: 'series' @@ -1182,34 +1175,23 @@ export default { color: true ? '#9ce375' : "#4FD3B9", }, }, - data: e.y[1].data, + data: e.map(e => e.Y_VALUE_TWO), }, ] }) } }, - { - e: 'zh-2-02', - i: "", - f: (e) => { - this.totalNum = e - - } - }, { e: 'zh-2-03', - i: "", + i: "scada_aq_pro_three_02('CX_02')", f: (e) => { + this.info1 = { + ddsl: e.reduce((v1, v2) => v1 + parseFloat(v2.COLUMN_D) || 0, 0), + wcsl: e.reduce((v1, v2) => v1 + parseFloat(v2.COLUMN_E) || 0, 0) + } this.scrollTableData = e } }, - { - e: 'zh-2-04', - i: "", - f: (e) => { - this.info1 = e - } - }, { e: 'zh-2-05', i: "", @@ -1388,7 +1370,7 @@ export default { }, { e: 'zh-2-06', - i: "", + i: "scada_aq_pro_xh_02('CX_02')", f: (e) => { this.$refs.productionEfficiency.setData({ grid: { @@ -1400,7 +1382,7 @@ export default { }, dataZoom: [], xAxis: { - data: e.x, + data: e.map(e => e.X_VALUE), axisLine: { lineStyle: { color: "#0177d4", @@ -1467,7 +1449,7 @@ export default { fontSize: 0.75 * vw }, }, - data: e.y.sort().reverse(), + data: e.map(e => e.Y_VALUE), }, ], }) @@ -1475,8 +1457,9 @@ export default { }, { e: 'zh-2-07', - i: "", + i: "scada_aq_zj_gx_01('')", f: (e) => { + let data = e[0] || {} this.$refs.equipmentPowerOne.setData({ series: [ { @@ -1499,7 +1482,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.nd, + value: parseFloat(data.COLUMN_A), label: { normal: { rich: { @@ -1518,7 +1501,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_A) + "%}" + "\n{b|内胆检漏}" ); @@ -1541,7 +1524,7 @@ export default { }, }, { - value: 100 - e.nd, + value: 100 - parseFloat(data.COLUMN_A), name: "invisible", itemStyle: { normal: { @@ -1578,7 +1561,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.gz, + value: parseFloat(data.COLUMN_B), label: { normal: { rich: { @@ -1597,7 +1580,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_B) + "%}" + "\n{b|灌注}" ); @@ -1620,7 +1603,7 @@ export default { }, }, { - value: 100 - e.gz, + value: 100 - parseFloat(data.COLUMN_B), name: "invisible", itemStyle: { normal: { @@ -1657,7 +1640,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.dy, + value: parseFloat(data.COLUMN_C), label: { normal: { rich: { @@ -1676,7 +1659,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_C) + "%}" + "\n{b|低压检漏}" ); @@ -1699,7 +1682,7 @@ export default { }, }, { - value: 100 - e.dy, + value: 100 - parseFloat(data.COLUMN_C), name: "invisible", itemStyle: { normal: { @@ -1736,7 +1719,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.ag, + value: parseFloat(data.COLUMN_D), label: { normal: { rich: { @@ -1755,7 +1738,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_D) + "%}" + "\n{b|安规检}" ); @@ -1778,7 +1761,7 @@ export default { }, }, { - value: 100 - e.ag, + value: 100 - parseFloat(data.COLUMN_D), name: "invisible", itemStyle: { normal: { @@ -1815,7 +1798,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.cw, + value: parseFloat(data.COLUMN_E), label: { normal: { rich: { @@ -1834,7 +1817,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_E) + "%}" + "\n{b|测温}" ); @@ -1857,7 +1840,7 @@ export default { }, }, { - value: 100 - e.cw, + value: 100 - parseFloat(data.COLUMN_E), name: "invisible", itemStyle: { normal: { @@ -1894,7 +1877,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.zj, + value: parseFloat(data.COLUMN_F), label: { normal: { rich: { @@ -1913,7 +1896,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_F) + "%}" + "\n{b|终检}" ); @@ -1936,7 +1919,7 @@ export default { }, }, { - value: 100 - e.zj, + value: 100 - parseFloat(data.COLUMN_F), name: "invisible", itemStyle: { normal: { @@ -1957,8 +1940,9 @@ export default { RequestDataSet2: [ { e: 'zh-3-01', - i: "", + i: "scada_aq_pro_tj_02('')", f: (e) => { + this.totalNum = e.reduce((v1, v2) => v1 + v2.Y_VALUE_TWO, 0) this.$refs.topLeft.setData({ grid: { top: "20%", @@ -1975,7 +1959,7 @@ export default { }, legend: { right: '0', - data: e.y.map(e => e.name), + data: ['计划产量', '实际产量'], textStyle: { fontSize: 0.75 * vw, color: "#F1F1F3", @@ -1993,7 +1977,7 @@ export default { color: "#F1F1F3", }, }, - data: e.x + data: e.map(e => e.X_VALUE), } ], yAxis: [ @@ -2014,7 +1998,7 @@ export default { ], series: [ { - name: e.y[0].name, + name: '计划产量', type: 'bar', barGap: 0, emphasis: { @@ -2037,10 +2021,10 @@ export default { fontSize: 0.75 * vw }, }, - data: e.y[0].data, + data: e.map(e => e.Y_VALUE_ONE), }, { - name: e.y[1].name, + name: '实际产量', type: 'bar', emphasis: { focus: 'series' @@ -2063,34 +2047,23 @@ export default { color: true ? '#9ce375' : "#4FD3B9", }, }, - data: e.y[1].data, + data: e.map(e => e.Y_VALUE_TWO), }, ] }) } }, - { - e: 'zh-3-02', - i: "", - f: (e) => { - this.totalNum = e - - } - }, { e: 'zh-3-03', - i: "", + i: "scada_aq_pro_three_02('')", f: (e) => { + this.info1 = { + ddsl: e.reduce((v1, v2) => v1 + parseFloat(v2.COLUMN_D) || 0, 0), + wcsl: e.reduce((v1, v2) => v1 + parseFloat(v2.COLUMN_E) || 0, 0) + } this.scrollTableData = e } }, - { - e: 'zh-3-04', - i: "", - f: (e) => { - this.info1 = e - } - }, { e: 'zh-3-05', i: "", @@ -2269,7 +2242,7 @@ export default { }, { e: 'zh-3-06', - i: "", + i: "scada_aq_pro_xh_02('')", f: (e) => { this.$refs.productionEfficiency.setData({ grid: { @@ -2281,7 +2254,7 @@ export default { }, dataZoom: [], xAxis: { - data: e.x, + data: e.map(e => e.X_VALUE), axisLine: { lineStyle: { color: "#0177d4", @@ -2348,7 +2321,7 @@ export default { fontSize: 0.75 * vw }, }, - data: e.y.sort().reverse(), + data: e.map(e => e.Y_VALUE), }, ], }) @@ -2356,8 +2329,9 @@ export default { }, { e: 'zh-3-07', - i: "", + i: "scada_aq_zj_gx_01('')", f: (e) => { + let data = e[0] || {} this.$refs.equipmentPowerOne.setData({ series: [ { @@ -2380,7 +2354,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.nd, + value: parseFloat(data.COLUMN_A), label: { normal: { rich: { @@ -2399,7 +2373,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_A) + "%}" + "\n{b|内胆检漏}" ); @@ -2422,7 +2396,7 @@ export default { }, }, { - value: 100 - e.nd, + value: 100 - parseFloat(data.COLUMN_A), name: "invisible", itemStyle: { normal: { @@ -2459,7 +2433,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.gz, + value: parseFloat(data.COLUMN_B), label: { normal: { rich: { @@ -2478,7 +2452,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_B) + "%}" + "\n{b|灌注}" ); @@ -2501,7 +2475,7 @@ export default { }, }, { - value: 100 - e.gz, + value: 100 - parseFloat(data.COLUMN_B), name: "invisible", itemStyle: { normal: { @@ -2538,7 +2512,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.dy, + value: parseFloat(data.COLUMN_C), label: { normal: { rich: { @@ -2557,7 +2531,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_C) + "%}" + "\n{b|低压检漏}" ); @@ -2580,7 +2554,7 @@ export default { }, }, { - value: 100 - e.dy, + value: 100 - parseFloat(data.COLUMN_C), name: "invisible", itemStyle: { normal: { @@ -2617,7 +2591,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.ag, + value: parseFloat(data.COLUMN_D), label: { normal: { rich: { @@ -2636,7 +2610,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_D) + "%}" + "\n{b|安规检}" ); @@ -2659,7 +2633,7 @@ export default { }, }, { - value: 100 - e.ag, + value: 100 - parseFloat(data.COLUMN_D), name: "invisible", itemStyle: { normal: { @@ -2696,7 +2670,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.cw, + value: parseFloat(data.COLUMN_E), label: { normal: { rich: { @@ -2715,7 +2689,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_E) + "%}" + "\n{b|测温}" ); @@ -2738,7 +2712,7 @@ export default { }, }, { - value: 100 - e.cw, + value: 100 - parseFloat(data.COLUMN_E), name: "invisible", itemStyle: { normal: { @@ -2775,7 +2749,7 @@ export default { center: ["50%", "50%"], data: [ { - value: e.zj, + value: parseFloat(data.COLUMN_F), label: { normal: { rich: { @@ -2794,7 +2768,7 @@ export default { formatter: function (params) { return ( "{a|" + - params.value + + parseFloat(data.COLUMN_F) + "%}" + "\n{b|终检}" ); @@ -2817,7 +2791,7 @@ export default { }, }, { - value: 100 - e.zj, + value: 100 - parseFloat(data.COLUMN_F), name: "invisible", itemStyle: { normal: { @@ -2839,17 +2813,17 @@ export default { }, mounted() { - if(this.nowLine === 1 ){ + if (this.nowLine === 1) { this.RequestDataSet.forEach(val => { mixData(val) }) } - if(this.nowLine === 2 ){ + if (this.nowLine === 2) { this.RequestDataSet1.forEach(val => { mixData(val) }) } - if(this.nowLine === 3 ){ + if (this.nowLine === 3) { this.RequestDataSet2.forEach(val => { mixData(val) }) @@ -2857,17 +2831,17 @@ export default { intervalFun = setInterval(() => { - if(this.nowLine === 1 ){ + if (this.nowLine === 1) { this.RequestDataSet.forEach(val => { mixData(val) }) } - if(this.nowLine === 2 ){ + if (this.nowLine === 2) { this.RequestDataSet1.forEach(val => { mixData(val) }) } - if(this.nowLine === 3 ){ + if (this.nowLine === 3) { this.RequestDataSet2.forEach(val => { mixData(val) }) @@ -2929,7 +2903,7 @@ export default { } }, beforeDestroy() { - if(intervalFun){ + if (intervalFun) { clearInterval(intervalFun) intervalFun = null }