This commit is contained in:
shijing 2025-02-21 17:27:55 +08:00
commit db03953ce8
2 changed files with 22 additions and 13 deletions

View File

@ -956,17 +956,26 @@ export default {
if (res3.length > 0) {
let data3 = res3[0];
that.tableDatas[0][3] = data3.total_production;
that.tableDatas[1][3] = data3.production_hour;
that.tableDatas[2][3] = data3.run_hour;
that.tableDatas[3][3] = data3.run_rate;
that.tableDatas[4][3] = data3.elec_consume_unit;
that.tableDatas[5][3] = data3.celec_consume_unit;
that.tableDatas[6][3] = data3.coal_consume_unit;
that.tableDatas[7][3] = data3.cen_consume_unit;
that.tableDatas[8][3] = data3.elec_consume;
that.tableDatas[9][3] = data3.production_cost_unit;
that.tableDatas[10][3] = data3.ammonia_consume;
that.tableDatas[11][3] = (data3.ammonia_consume*1000/data3.total_production).toFixed(2);
if (data3.total_production<1){
that.tableDatas[4][3] = 0;
that.tableDatas[5][3] = 0;
that.tableDatas[6][3] = 0;
that.tableDatas[7][3] = 0;
that.tableDatas[8][3] = 0;
}else{
that.tableDatas[1][3] = data3.production_hour;
that.tableDatas[2][3] = data3.run_hour;
that.tableDatas[3][3] = data3.run_rate;
that.tableDatas[4][3] = data3.elec_consume_unit;
that.tableDatas[5][3] = data3.celec_consume_unit;
that.tableDatas[6][3] = data3.coal_consume_unit;
that.tableDatas[7][3] = data3.cen_consume_unit;
that.tableDatas[8][3] = data3.elec_consume;
that.tableDatas[9][3] = data3.production_cost_unit;
that.tableDatas[10][3] = data3.ammonia_consume;
that.tableDatas[11][3] = (data3.ammonia_consume*1000/data3.total_production).toFixed(2);
}
}
});
//

View File

@ -107,7 +107,7 @@
<el-button
link
size="small"
v-if="scope.row.type == 'year_s' || scope.row.type == 'month_s' || scope.row.type == 'day_s'"
v-if="scope.row.type == 'year_s' || scope.row.type == 'month_s' || scope.row.type == 'day_s'|| scope.row.type == 'month'|| scope.row.type == 'day'"
@click="handle_edit(scope.row)"
type="primary"
>校正</el-button
@ -282,7 +282,7 @@ export default {
{
name: tableData.length > 0 ? tableData[0].mpoint_name : "",
type: 'line', // 线
data: tableData.length > 0 ? tableData.reverse().map((item) => parseFloat(item.val)) : [], //
data: tableData.length > 0 ? tableData.map((item) => parseFloat(item.val)) : [], //
smooth: true, // 线
}
];