fix:大屏数据修改

This commit is contained in:
shijing 2024-07-02 11:02:35 +08:00
parent f91f0dbb49
commit 1da3fc9261
1 changed files with 13 additions and 9 deletions

View File

@ -898,12 +898,12 @@ export default {
let that = this;
let params = {
type: "month_s",
year_s: that.year,
monnth: that.month,
year_s: that.currentYear,
month_s: that.currentMonth,
};
that.$API.enm.enstat.req(params).then((res) => {
// console.log("", res.results);
let data = res.results;
console.log("工序电耗", data);
let seriesData = [0, 0, 0, 0, 0];
data.forEach((item, index) => {
if (item.mgroup_name == "石灰石破碎") {
@ -913,6 +913,7 @@ export default {
} else if (item.mgroup_name == "回转窑") {
seriesData[2] = item.elec_consume;
} else if (item.mgroup_name == "余热发电") {
console.log("余热发电工序电耗", item.elec_consume);
seriesData[3] = item.elec_consume;
} else if (item.mgroup_name == "煤磨") {
seriesData[4] = item.elec_consume;
@ -962,8 +963,11 @@ export default {
let chartDom6 = document.getElementById("pieChart");
let myChart6 = echarts.init(chartDom6);
let colors = [];
colors.push(that.linearGradientColors[0]);
colors.push(that.linearGradientColors[3]);
let option6 = {
color: that.linearGradientColors,
color: colors,
tooltip: {
trigger: "item",
},
@ -1460,7 +1464,7 @@ export default {
year_s: that.currentYear,
month_s: that.currentMonth,
page: 0,
query: "{total_production,run_rate,elec_consume_unit}",
query: "{total_production,run_rate,elec_consume_unit,production_elec_unit}",
};
that.$API.enm.enstat.req(query).then((res) => {
let info = {
@ -1470,7 +1474,7 @@ export default {
if (value == "余热发电") {
info.rows = [
{
label: "发电量(t)",
label: "发电量(kwh)",
field: "total_production",
value: res[0].total_production,
},
@ -1480,8 +1484,8 @@ export default {
value: res[0].run_rate,
},
{
label: "吨熟料发电量(kwh)",
field: "elec_consume_unit",
label: "吨熟料发电量(kwh/t)",
field: "production_elec_unit",
value: res[0].production_elec_unit
? res[0].production_elec_unit
: "0.00",
@ -2173,7 +2177,7 @@ export default {
width: 10px;
height: 10px;
border-radius: 5px;
background: #ffa500;
background: rgb(255, 0, 135);
}
/deep/ .el-table,
.el-table__body,