From 7f135ed7e1d0a8dfead9078799215ad75d107e1a Mon Sep 17 00:00:00 2001 From: zty Date: Fri, 23 Aug 2024 17:20:22 +0800 Subject: [PATCH 1/6] =?UTF-8?q?fix:=20=E6=B0=B4=E6=B3=A5=E7=A3=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/enm_coal/workshopAnalysis.vue | 12 +- src/views/enm_kiln/teamAnalysis.vue | 100 ++++-- src/views/enm_pack/report.vue | 450 +++++++++++++++++++----- src/views/enm_pack/teamAnalysis.vue | 4 +- src/views/enm_pack/workshopAnalysis.vue | 2 +- 5 files changed, 439 insertions(+), 129 deletions(-) diff --git a/src/views/enm_coal/workshopAnalysis.vue b/src/views/enm_coal/workshopAnalysis.vue index 0941abcd..aab4a16d 100644 --- a/src/views/enm_coal/workshopAnalysis.vue +++ b/src/views/enm_coal/workshopAnalysis.vue @@ -171,6 +171,14 @@ export default { } return classInfo; }, + precen(a, b) { + if (b !== 0 && b !== null && a !== null) { + let precen = (a / b)* 100; + return precen.toFixed(2) + "%"; + } else { + return "/"; + } + }, getData() { let that = this; let query0 = {}; @@ -255,11 +263,11 @@ export default { //环比增长率(%) let lastRate = 0; if ( - lastDiff == "/" && + lastDiff !== "/" && lastNum !== "/" && lastNum !== 0 ) { - lastRate = (lastDiff / lastNum) * 100; + lastRate = this.precen(lastDiff, lastNum); } else { lastRate = "/"; } diff --git a/src/views/enm_kiln/teamAnalysis.vue b/src/views/enm_kiln/teamAnalysis.vue index 863c7897..0ee2adcf 100644 --- a/src/views/enm_kiln/teamAnalysis.vue +++ b/src/views/enm_kiln/teamAnalysis.vue @@ -136,11 +136,11 @@ export default { params.year = that.query.year_s; params.mgroup = that.query.mgroup; this.$API.mtm.goal.list.req(params).then((res) => { - let data = []; - if (res.length > 0) { - data = res[0]; - } - that.getData(data); + // let data = []; + // if (res.length > 0) { + // this.data = res; + // } + that.getData(res); }); }, getData(goalData) { @@ -215,46 +215,81 @@ export default { ? item.入窑生料_Fe2O3_rate_pass : "/"; arr[8] = - item.入窑生料_细度_rate_pass != null - ? item.入窑生料_细度_rate_pass + item.出磨煤粉_细度_rate_pass != null + ? item.出磨煤粉_细度_rate_pass : "/"; arr[9] = - item.入窑生料_水分_rate_pass != null - ? item.入窑生料_水分_rate_pass + item.出磨煤粉_水分_rate_pass != null + ? item.出磨煤粉_水分_rate_pass : "/"; arr[10] = - item.熟料_立升重_rate_pass != null - ? item.熟料_立升重_rate_pass + item.出窑熟料_立升重_rate_pass != null + ? item.出窑熟料_立升重_rate_pass : "/"; arr[11] = - item.熟料_fCaO_rate_pass != null - ? item.熟料_fCaO_rate_pass + item.出窑熟料_fCaO_rate_pass != null + ? item.出窑熟料_fCaO_rate_pass : "/"; //煤耗 - arr[12] = item.elec_consume_unit; //当期值(KW·h/t) - let keyVale = "goal_val_" + n; - arr[5] = goalData[keyVale]; //目标值(KW·h/t)//需要接口获取 - arr[6] = arr[4] - item.celec_consume_unit; //当期与目标差值(KW·h/t) + arr[12] = item.coal_consume_unit; //当期值(KW·h/t) + let keyValue = "goal_val_" + n; + if (goalData.length > 0){ + goalData.forEach((item) => { + if (item.id == "3638341891940192256") { + arr[13] = item[keyValue]; //目标值(KW·h/t)//需要接口获取 + }else if (item.id == "3637651365016526848"){ + arr[25] = item[keyValue]; //目标值(KW·h/t)//需要接口获取 + } + }); + }; + let dq = 0 + if (arr[13] !== null && arr[13] !== undefined){ + dq = arr[12] - arr[13]; //当期与目标差值(KW·h/t) + }else{ + dq == "/" + }; + arr[14] = dq; //当期与目标差值 let ind_pre = 0, huanbi = 0; if (item.month_s == 1) { ind_pre = 12; huanbi = wrapArr0[ind_pre] - ? wrapArr0[ind_pre].elec_consume_unit + ? wrapArr0[ind_pre].coal_consume_unit : "/"; } else { ind_pre = ind - 1; huanbi = wrapArr[ind_pre] - ? wrapArr[ind_pre].elec_consume_unit - ? wrapArr[ind_pre].elec_consume_unit + ? wrapArr[ind_pre].coal_consume_unit + ? wrapArr[ind_pre].coal_consume_unit : "/" : "/"; } arr[15] = huanbi; //环期值(KW·h/t)上个月的值 - arr[16] = item.celec_consume_unit; //当期与环期差值(KW·h/t) - arr[17] = item.celec_consume_unit; //环比增长率(%) - arr[18] = item.celec_consume_unit; //同比增长率(%) + if(huanbi !=="/"){ + arr[16] = arr[12] - huanbi; //当期与环期差值(KW·h/t) + }else{ + arr[16] = "/" + }; + if (arr[15] !== "/"&& arr[15]!== 0 && arr[16]!=="/") { + arr[17] = (arr[16] / arr[15]) * 100; //环比增长率(%) + } else{ + arr[17] = "/" + }; + let sameRate = 0; + if ( + wrapArr0[ind] && + wrapArr0[ind].coal_consume_unit + ) { + sameRate = + ((arrs[1] - + wrapArr0[ind].coal_consume_unit) / + wrapArr0[ind].coal_consume_unit) * + 100; + } else { + sameRate = "/"; + } + arr[18] = sameRate; ///同比增长率(%)需要当前值/ 上一年同一个月的值即wrapArr0[ind].elec_consume_unit //电耗 //设备 arr[19] = @@ -278,8 +313,10 @@ export default { ? item.窑头排风机_consume_unit : "/"; arr[24] = item.elec_consume_unit; //当期值(KW·h/t) - arr[25] = item.celec_consume_unit; //目标值(KW·h/t)//需要接口获取 - arr[26] = item.celec_consume_unit; //当期与目标差值(KW·h/t) + // arr[25] = item.celec_consume_unit; //目标值(KW·h/t)//需要接口获取 + if (item.elec_consume_unit != null &&item.elec_consume_unit !== "/"){ + arr[26] = arr[24]-arr[25] //当期与目标差值(KW·h/t) + } let ind_pre1 = 0, huanbi1 = 0; if (item.month_s == 1) { @@ -296,13 +333,18 @@ export default { : "/"; } arr[27] = huanbi; //环期值(KW·h/t)上个月的值 - arr[28] = item.celec_consume_unit; //当期与环期差值(KW·h/t) - arr[29] = item.celec_consume_unit; //环比增长率(%) + if(arr[27]!=="/" && huanbi1!=="/"){ + arr[28] = arr[24] - huanbi1; //当期与环期差值(KW·h/t) + }else{ + arr[28] = "/" + } + if(arr[28]!=="/" && huanbi1!=="/"){ + arr[29] = (arr[28] / huanbi1) * 100; //环比增长率(%) + }else{ + arr[29] = "/"}; //环比增长率(%) arr[30] = item.celec_consume_unit; //同比增长率(%) - arr[31] = item.celec_consume_unit; //同比增长率(%) wrapArr[ind] = arr; }); - console.log(wrapArr); that.tableDatas = wrapArr; } else { } diff --git a/src/views/enm_pack/report.vue b/src/views/enm_pack/report.vue index e04dc87c..625bd68c 100644 --- a/src/views/enm_pack/report.vue +++ b/src/views/enm_pack/report.vue @@ -38,8 +38,9 @@ - - {{ item[0] }} + + {{ item[0] }} + {{ item[0] }} {{ item[1] }} {{ item[4] }} - {{ item[5].toFixed(2) }} + {{ item[5] }} {{ item[6] }} - {{ item[7].toFixed(2) }} + {{ item[7] }} {{ item[8] }} @@ -326,8 +327,18 @@ export default { mgroup: "", }, tableDatas: [ - ["产量", "总产量(t)", 0, 0, 0, 0, 0, 0, 0, 0], - ["能耗", "单位产品分布电耗(KW·h/t)", 0, 0, 0, 0, 0, 0, 0, 0], + ["出厂水泥", "P.O42.5R 散装(t)", 0, 0, 0, "/", "/", "/","/"], + ["出厂水泥", "P.O42.5R 袋装(t)", 0, 0, 0, "/", "/", "/","/"], + ["出厂水泥", "P.O42.5 袋装(t)", 0, 0, 0, "/", "/", "/","/"], + ["出厂水泥", "P.O42.5 散装(t)", 0, 0, 0, "/", "/", "/","/"], + ["出厂水泥", "P.C42.5 袋装(t)", 0, 0, 0, "/", "/", "/","/"], + ["出厂水泥", "P.C42.5 散装(t)", 0, 0, 0, "/", "/", "/","/"], + ["出厂水泥", "P.O52.5 散装(t)", 0, 0, 0, "/", "/", "/","/"], + ["出厂水泥", "出厂水泥合计(t)", 0, 0, 0, 0, 0, 0, 0], + + ["出厂熟料", "熟料(t)", 0, 0, 0, "/", "/", "/","/"], + ["能耗", "单位产品分布电耗(KW·h/t)", 0, 0, 0, 0, 0, 0, 0], + ], tableName: "生产报告", modelValue: true, @@ -360,6 +371,54 @@ export default { yAxisIndex: 0, data: [], }, + { + name: "P.O42.5R 散装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.O42.5R 袋装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.O42.5 袋装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.O42.5 散装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.C42.5 袋装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.C42.5 散装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.O52.5 散装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "熟料", + type: "bar", + yAxisIndex: 0, + data: [], + }, { name: "分布电耗", type: "bar", @@ -384,12 +443,60 @@ export default { }, yAxis: yAxis, series: [ - { + { name: "总产量", type: "bar", yAxisIndex: 0, data: [], }, + { + name: "P.O42.5R 散装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.O42.5R 袋装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.O42.5 袋装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.O42.5 散装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.C42.5 袋装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.C42.5 散装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "P.O52.5 散装", + type: "bar", + yAxisIndex: 0, + data: [], + }, + { + name: "熟料", + type: "bar", + yAxisIndex: 0, + data: [], + }, { name: "分布电耗", type: "bar", @@ -440,43 +547,69 @@ export default { params1.year_s = year; params1.type = "year_s"; params1.mgroup = that.query.mgroup; - this.$API.enm.enstat.req(params1).then((res1) => { + this.$API.enm.mpointstat.list.req(params1).then((res1) => { if (res1.length > 0) { - let data1 = res1[0]; - that.tableDatas[0][4] = data1.total_production; - that.tableDatas[1][4] = data1.elec_consume_unit; - } - }); - //月 + res1.forEach((item) => { + if (item.mpoint_name == "水泥+P.O42.5R 散装") { + that.tableDatas[0][4] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5R 袋装"){ + that.tableDatas[1][4] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 袋装") { + that.tableDatas[2][4] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 散装") { + that.tableDatas[3][4] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 袋装") { + that.tableDatas[4][4] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 散装") { + that.tableDatas[5][4] = item.val; + }else if (item.mpoint_name == "水泥+P.O52.5 散装") { + that.tableDatas[6][4] = item.val; + }else if (item.mpoint_name == "出厂批次水泥合计") { + that.tableDatas[7][4] = item.val; + }else if (item.mpoint_name == "出厂熟料"){ + that.tableDatas[8][4] = item.val; + }else if (item.mpoint_name == "包装进线") { + that.tableDatas[9][4] = item.val; + } + } + )} + }).then(()=>{ + //月 let params2 = {}; params2.page = 0; params2.year_s = year; params2.month_s = month; params2.type = "month_s"; params2.mgroup = that.query.mgroup; - this.$API.enm.enstat.req(params2).then((res2) => { + this.$API.enm.mpointstat.list.req(params2).then((res2) => { if (res2.length > 0) { - let data2 = res2[0]; - that.tableDatas[0][3] = data2.total_production; - that.tableDatas[1][3] = data2.elec_consume_unit; + res2.forEach((item) => { + if (item.mpoint_name == "水泥+P.O42.5R 散装") { + that.tableDatas[0][3] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5R 袋装"){ + that.tableDatas[1][3] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 袋装") { + that.tableDatas[2][3] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 散装") { + that.tableDatas[3][3] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 袋装") { + that.tableDatas[4][3] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 散装") { + that.tableDatas[5][3] = item.val; + }else if (item.mpoint_name == "水泥+P.O52.5 散装") { + that.tableDatas[6][3] = item.val; + }else if (item.mpoint_name == "出厂批次水泥合计") { + that.tableDatas[7][3] = item.val; + }else if (item.mpoint_name == "出厂熟料"){ + that.tableDatas[8][3] = item.val; + }else if (item.mpoint_name == "包装进线") { + that.tableDatas[9][3] = item.val; + } + } + ) } - }); - //昨日 - let params3 = {}; - params3.page = 0; - params3.year_s = year_d; - params3.month_s = month_d; - params3.day_s = days_d; - params3.type = "day_s"; - params3.mgroup = that.query.mgroup; - this.$API.enm.enstat.req(params3).then((res3) => { - if (res3.length > 0) { - let data3 = res3[0]; - that.tableDatas[0][2] = data3.total_production; - that.tableDatas[1][2] = data3.elec_consume_unit; - } - }); - //月目标 + }).then(() => { + //月年目标 let params5 = {}; params5.page = 0; params5.mgroup = that.query.mgroup; @@ -488,63 +621,121 @@ export default { data5.forEach((item5) => { let str = "goal_val_" + that.month; if (item5.goal_cate_name == "总产量(t)") { - that.tableDatas[0][5] = item5[str]; - that.tableDatas[0][7] = item5.goal_val; + that.tableDatas[7][5] = item5[str]; + that.tableDatas[7][7] = item5.goal_val; + that.tableDatas[7][8] = precen( + that.tableDatas[7][4], + that.tableDatas[7][7] + );//计算年完成度 + that.tableDatas[7][6] = precen( + that.tableDatas[7][3], + that.tableDatas[7][5] + );// 计算月完成度 + } else if ( item5.goal_cate_name == "单位产品分布电耗(KW·h/t)" ) { - that.tableDatas[1][5] = item5[str]; - that.tableDatas[1][7] = item5.goal_val; + that.tableDatas[9][5] = item5[str]; + that.tableDatas[9][7] = item5.goal_val; + //计算月目标值 + that.tableDatas[9][8] = precen( + that.tableDatas[9][4], + that.tableDatas[9][7] + );//计算年完成度 + that.tableDatas[9][6] = precen( + that.tableDatas[9][3], + that.tableDatas[9][5] + );// 计算月完成度 + } }); } - }) - .then((res) => { - //年 - let params1 = {}; - params1.page = 0; - params1.year_s = year; - params1.type = "year_s"; - params1.mgroup = this.query.mgroup; - this.$API.enm.enstat.req(params1).then((res1) => { - if (res1.length > 0) { - let data1 = res1[0]; - that.tableDatas[0][4] = data1.total_production; - that.tableDatas[0][8] = precen( - that.tableDatas[0][4], - that.tableDatas[0][7] - ); - that.tableDatas[1][4] = data1.elec_consume_unit; - that.tableDatas[1][8] = precen( - that.tableDatas[1][4], - that.tableDatas[1][7] - ); - } - }); - //月 - let params2 = {}; - params2.page = 0; - params2.year_s = year; - params2.month_s = month; - params2.type = "month_s"; - params2.mgroup = this.query.mgroup; - this.$API.enm.enstat.req(params2).then((res2) => { - if (res2.length > 0) { - let data2 = res2[0]; - that.tableDatas[0][3] = data2.total_production; - that.tableDatas[0][6] = precen( - that.tableDatas[0][3], - that.tableDatas[0][5] - ); - that.tableDatas[1][3] = data2.elec_consume_unit; - that.tableDatas[1][6] = precen( - that.tableDatas[1][3], - that.tableDatas[1][5] - ); - } - }); }); + }) + }); + //昨日 + let params3 = {}; + params3.page = 0; + params3.year_s = year_d; + params3.month_s = month_d; + params3.day_s = days_d; + params3.type = "day_s"; + params3.mgroup = that.query.mgroup; + this.$API.enm.mpointstat.list.req(params3).then((res3) => { + if (res3.length > 0) { + res3.forEach((item) => { + if (item.mpoint_name == "水泥+P.O42.5R 散装") { + that.tableDatas[0][2] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5R 袋装"){ + that.tableDatas[1][2] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 袋装") { + that.tableDatas[2][2] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 散装") { + that.tableDatas[3][2] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 袋装") { + that.tableDatas[4][2] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 散装") { + that.tableDatas[5][2] = item.val; + }else if (item.mpoint_name == "水泥+P.O52.5 散装") { + that.tableDatas[6][2] = item.val; + }else if (item.mpoint_name == "出厂批次水泥合计") { + that.tableDatas[7][2] = item.val; + }else if (item.mpoint_name == "出厂熟料"){ + that.tableDatas[8][2] = item.val; + }else if (item.mpoint_name == "包装进线") { + that.tableDatas[9][2] = item.val; + } + } + ) + } + }); + // this.$API.mtm.goal.list + // .then((res) => { + // //月年完成度 + // let params1 = {}; + // params1.page = 0; + // params1.year_s = year; + // params1.type = "year_s"; + // params1.mgroup = this.query.mgroup; + // this.$API.enm.enstat.req(params1).then((res1) => { + // if (res1.length > 0) { + // let data1 = res1[0]; + // that.tableDatas[0][4] = data1.total_production; + // that.tableDatas[0][8] = precen( + // that.tableDatas[0][4], + // that.tableDatas[0][7] + // ); + // that.tableDatas[1][4] = data1.elec_consume_unit; + // that.tableDatas[1][8] = precen( + // that.tableDatas[1][4], + // that.tableDatas[1][7] + // ); + // } + // }); + // //月 + // let params2 = {}; + // params2.page = 0; + // params2.year_s = year; + // params2.month_s = month; + // params2.type = "month_s"; + // params2.mgroup = this.query.mgroup; + // this.$API.enm.enstat.req(params2).then((res2) => { + // if (res2.length > 0) { + // let data2 = res2[0]; + // that.tableDatas[0][3] = data2.total_production; + // that.tableDatas[0][6] = precen( + // that.tableDatas[0][3], + // that.tableDatas[0][5] + // ); + // that.tableDatas[1][3] = data2.elec_consume_unit; + // that.tableDatas[1][6] = precen( + // that.tableDatas[1][3], + // that.tableDatas[1][5] + // ); + // } + // }); + // }); that.getDayData(year, month); that.getMonthData(year); }); @@ -572,7 +763,7 @@ export default { } } }, - //获取天数据 + //获取天数据-图表 getDayData(year, month) { let that = this; let query1 = {}; @@ -581,19 +772,53 @@ export default { query1.month_s = month; query1.type = "day_s"; query1.mgroup = this.query.mgroup; - this.$API.enm.enstat.req(query1).then((response) => { + this.$API.enm.mpointstat.list.req(query1).then((response) => { let seriesData0 = [], - seriesData1 = []; - + seriesData1 = [], + seriesData2 = [], + seriesData3 = [], + seriesData4 = [], + seriesData5 = [], + seriesData6 = [], + seriesData7 = [], + seriesData8 = [], + seriesData9 = []; let data = response; data.forEach((item) => { let ind = item.day_s - 1; - seriesData0[ind] = item.total_production; - seriesData1[ind] = item.elec_consume_unit; + if (item.mpoint_name == "水泥+P.O42.5R 散装") { + seriesData1[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5R 袋装"){ + seriesData2[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 袋装") { + seriesData3[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 散装") { + seriesData4[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 袋装") { + seriesData5[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 散装") { + seriesData6[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.O52.5 散装") { + seriesData7[ind] = item.val; + }else if (item.mpoint_name == "出厂批次水泥合计") { + seriesData0[ind] = item.val; + }else if (item.mpoint_name == "出厂熟料"){ + seriesData8[ind] = item.val; + }else if (item.mpoint_name == "包装进线") { + seriesData9[ind] = item.val; + } }); let options = { ...that.option1 }; options.series[0].data = seriesData0; options.series[1].data = seriesData1; + options.series[2].data = seriesData2; + options.series[3].data = seriesData3; + options.series[4].data = seriesData4; + options.series[5].data = seriesData5; + options.series[6].data = seriesData6; + options.series[7].data = seriesData7; + options.series[8].data = seriesData8; + options.series[9].data = seriesData9; let dayXAxis = []; for (let i = 1; i <= that.days; i++) { let item = i + "日"; @@ -603,7 +828,7 @@ export default { that.optionDay = options; }); }, - //获取月数据 + //获取月数据-图表 getMonthData(year) { let that = this; let query2 = {}; @@ -611,18 +836,53 @@ export default { query2.year_s = year; query2.type = "month_s"; query2.mgroup = that.query.mgroup; - this.$API.enm.enstat.req(query2).then((response) => { + this.$API.enm.mpointstat.list.req(query2).then((response) => { let seriesData0 = [], - seriesData1 = []; + seriesData1 = [], + seriesData2 = [], + seriesData3 = [], + seriesData4 = [], + seriesData5 = [], + seriesData6 = [], + seriesData7 = [], + seriesData8 = [], + seriesData9 = []; let data = response; data.forEach((item) => { let ind = item.month_s - 1; - seriesData0[ind] = item.total_production; - seriesData1[ind] = item.elec_consume_unit; + if (item.mpoint_name == "水泥+P.O42.5R 散装") { + seriesData1[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5R 袋装"){ + seriesData2[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 袋装") { + seriesData3[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.O42.5 散装") { + seriesData4[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 袋装") { + seriesData5[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.C42.5 散装") { + seriesData6[ind] = item.val; + }else if (item.mpoint_name == "水泥+P.O52.5 散装") { + seriesData7[ind] = item.val; + }else if (item.mpoint_name == "出厂批次水泥合计") { + seriesData0[ind] = item.val; + }else if (item.mpoint_name == "出厂熟料"){ + seriesData8[ind] = item.val; + }else if (item.mpoint_name == "包装进线") { + seriesData9[ind] = item.val; + } }); let options = { ...that.option2 }; options.series[0].data = seriesData0; options.series[1].data = seriesData1; + options.series[2].data = seriesData2; + options.series[3].data = seriesData3; + options.series[4].data = seriesData4; + options.series[5].data = seriesData5; + options.series[6].data = seriesData6; + options.series[7].data = seriesData7; + options.series[8].data = seriesData8; + options.series[9].data = seriesData9; let monthXAxis = []; for (let i = 1; i <= that.month; i++) { let item = i + "月"; diff --git a/src/views/enm_pack/teamAnalysis.vue b/src/views/enm_pack/teamAnalysis.vue index fa5da65a..19e40fd5 100644 --- a/src/views/enm_pack/teamAnalysis.vue +++ b/src/views/enm_pack/teamAnalysis.vue @@ -182,7 +182,7 @@ export default { : "/" : "/"; } - arr[6] = huanbi; //环期值(KW·h/t)上个月的值 + arr[6] = huanbi; //环期值(KW·h/t)上个月的值\ let diff = 0; if (arr[6] == "/"){ diff == "/"; @@ -191,7 +191,7 @@ export default { } arr[7] = diff; if (arr[7]=="/" || arr[6]=="/" || arr[6]==0){ - arr[8] = "/"; + arr[8] == "/"; }else{ arr[8] = (arr[7]/arr[6])*100 //环比增长率(%)= 当期与环期差值(KW·h/t)/环期值(KW·h/t)*100% } diff --git a/src/views/enm_pack/workshopAnalysis.vue b/src/views/enm_pack/workshopAnalysis.vue index 9d129930..d2e65acb 100644 --- a/src/views/enm_pack/workshopAnalysis.vue +++ b/src/views/enm_pack/workshopAnalysis.vue @@ -229,7 +229,7 @@ export default { //当期与目标差值(KW·h/t) let diff = 0; if (item[2] !== "/") { - diff = item[1] - item[2]; + diff = (item[1] - item[2]).toFixed(2); } else { diff = "/"; } From 1793a41dfb650f5b1b6b7c90d3434e87b5a43609 Mon Sep 17 00:00:00 2001 From: shijing Date: Mon, 26 Aug 2024 09:02:11 +0800 Subject: [PATCH 2/6] =?UTF-8?q?feat:=E9=BB=91=E5=8C=96=E8=BD=A6=E9=97=B4?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E7=9C=8B=E6=9D=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/bigScreen/index_heihuadept.vue | 992 +++++++++++++++++++++++ 1 file changed, 992 insertions(+) create mode 100644 src/views/bigScreen/index_heihuadept.vue diff --git a/src/views/bigScreen/index_heihuadept.vue b/src/views/bigScreen/index_heihuadept.vue new file mode 100644 index 00000000..a6be8cfd --- /dev/null +++ b/src/views/bigScreen/index_heihuadept.vue @@ -0,0 +1,992 @@ + + + + From 28d482604303fa73fad35282835c9b5521aaa030 Mon Sep 17 00:00:00 2001 From: shijing Date: Mon, 26 Aug 2024 09:59:02 +0800 Subject: [PATCH 3/6] =?UTF-8?q?feat:=E5=85=89=E5=AD=90=E7=BB=9F=E8=AE=A1?= =?UTF-8?q?=E5=88=86=E6=9E=90-=E4=BB=BB=E5=8A=A1=E7=BB=9F=E8=AE=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/statistics/task_rate_gx.vue | 218 ++++++++++++++++++++++++++ 1 file changed, 218 insertions(+) create mode 100644 src/views/statistics/task_rate_gx.vue diff --git a/src/views/statistics/task_rate_gx.vue b/src/views/statistics/task_rate_gx.vue new file mode 100644 index 00000000..b96f23c5 --- /dev/null +++ b/src/views/statistics/task_rate_gx.vue @@ -0,0 +1,218 @@ + + + + From 8c3bafcc19d8282d82ab4a6e8c29e02b465c0246 Mon Sep 17 00:00:00 2001 From: shijing Date: Mon, 26 Aug 2024 09:59:53 +0800 Subject: [PATCH 4/6] =?UTF-8?q?fix:=E5=85=89=E5=AD=90=E7=BB=9F=E8=AE=A1?= =?UTF-8?q?=E5=88=86=E6=9E=90=E6=B7=BB=E5=8A=A0=E6=96=B0=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/config/route.js | 77 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 77 insertions(+) diff --git a/src/config/route.js b/src/config/route.js index 7b563ac6..ef7c67e2 100644 --- a/src/config/route.js +++ b/src/config/route.js @@ -2966,6 +2966,17 @@ const routes = [ perms: ["bigScreenP_dept"], }, children: [ + { + path: "/bigScreenP_heihua", + name: "bigScreenP_heihua", + meta: { + title: "黑化车间", + icon: "el-icon-trend-charts", + perms: ["bigScreenP_dept10"], + fullpage: true, + }, + component: "bigScreen/index_heihuadept.vue", + }, { path: "/bigScreenP_10", name: "bigScreenP_10", @@ -3181,6 +3192,72 @@ const routes = [ }, component: "statistics/stock_statistics.vue", }, + //合格数统计——光芯 + { + name: "pass_num_gx", + path: "/statistic/pass_num_gx", + meta: { + title: "合格数统计", + icon: "el-icon-DataAnalysis", + perms: ["pass_num_gx"], + }, + component: "statistics/pass_num_gx.vue", + }, + //任务进度统计——光芯 + { + name: "task_rate_gx", + path: "/statistic/task_rate_gx", + meta: { + title: "任务进度", + icon: "el-icon-DataAnalysis", + perms: ["task_rate_gx"], + }, + component: "statistics/task_rate_gx.vue", + }, + //库存统计——光芯 + { + path: "/statistic_inm", + name: "statistic_inm", + meta: { + title: "库存统计", + icon: "el-icon-trend-charts", + perms: ["statistic_inm_gx"], + }, + component: "statistics/statistics_inm.vue", + }, + //过程检验统计——光芯 + { + path: "/process_check_gx", + name: "process_check_gx", + meta: { + title: "过程检验统计", + icon: "el-icon-trend-charts", + perms: ["process_check_gx"], + }, + component: "statistics/process_check_gx.vue", + }, + //成品检验统计——光芯 + { + path: "/good_check_gx", + name: "good_check_gx", + meta: { + title: "成品检验统计", + icon: "el-icon-trend-charts", + perms: ["good_check_gx"], + }, + component: "statistics/good_check_gx.vue", + }, + //扫边车间数据汇总——光芯 + // { + // path: "/statistics_saobian", + // name: "statistics_saobian", + // meta: { + // title: "扫边车间统计", + // icon: "el-icon-trend-charts", + // perms: ["statistic_inm"], + // }, + // component: "statistics/statistics_saobian.vue", + // }, //综合查询 { name: "total_statistics", From fabfe947386ffe1ff5eef17ef194ff75bb8c3fec Mon Sep 17 00:00:00 2001 From: shijing Date: Mon, 26 Aug 2024 10:57:47 +0800 Subject: [PATCH 5/6] =?UTF-8?q?feat:=E5=85=89=E5=AD=90=E6=88=90=E5=93=81?= =?UTF-8?q?=E6=A3=80=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/statistics/good_check_gx.vue | 103 ++++++++++++++++++++++ src/views/statistics/process_check_gx.vue | 103 ++++++++++++++++++++++ 2 files changed, 206 insertions(+) create mode 100644 src/views/statistics/good_check_gx.vue create mode 100644 src/views/statistics/process_check_gx.vue diff --git a/src/views/statistics/good_check_gx.vue b/src/views/statistics/good_check_gx.vue new file mode 100644 index 00000000..7583d0e3 --- /dev/null +++ b/src/views/statistics/good_check_gx.vue @@ -0,0 +1,103 @@ + + + + + diff --git a/src/views/statistics/process_check_gx.vue b/src/views/statistics/process_check_gx.vue new file mode 100644 index 00000000..4322d295 --- /dev/null +++ b/src/views/statistics/process_check_gx.vue @@ -0,0 +1,103 @@ + + + + + From f810b751dd1115c6afc2f3694497f3c84a97108a Mon Sep 17 00:00:00 2001 From: shijing Date: Mon, 26 Aug 2024 10:58:50 +0800 Subject: [PATCH 6/6] =?UTF-8?q?feat:=E5=85=89=E5=AD=90=E5=90=88=E6=A0=BC?= =?UTF-8?q?=E6=95=B0=E7=BB=9F=E8=AE=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/statistics/pass_num_gx.vue | 260 +++++++++++++++++++++++++++ 1 file changed, 260 insertions(+) create mode 100644 src/views/statistics/pass_num_gx.vue diff --git a/src/views/statistics/pass_num_gx.vue b/src/views/statistics/pass_num_gx.vue new file mode 100644 index 00000000..79d2f7f8 --- /dev/null +++ b/src/views/statistics/pass_num_gx.vue @@ -0,0 +1,260 @@ + + + +