Merge branch 'master' of http://gitea.xxhhcty.xyz:8080/zcdsj/factory_web
This commit is contained in:
commit
d2f41f69ab
|
|
@ -656,22 +656,6 @@ export default {
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
function precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = (a / b)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
function consume_precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = ((a / b)+1)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
let that = this;
|
let that = this;
|
||||||
var myDate = new Date();
|
var myDate = new Date();
|
||||||
let year = (that.year = myDate.getFullYear());
|
let year = (that.year = myDate.getFullYear());
|
||||||
|
|
@ -809,32 +793,32 @@ export default {
|
||||||
if (res1.length > 0) {
|
if (res1.length > 0) {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] = data1.total_production;
|
that.tableDatas[0][5] = data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] = data1.production_hour;
|
that.tableDatas[1][5] = data1.production_hour;
|
||||||
that.tableDatas[1][9] = precen(
|
that.tableDatas[1][9] = this.precen(
|
||||||
that.tableDatas[1][5],
|
that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.run_hour;
|
that.tableDatas[2][5] = data1.run_hour;
|
||||||
that.tableDatas[2][9] = precen(
|
that.tableDatas[2][9] = this.precen(
|
||||||
that.tableDatas[2][5],
|
that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] = data1.run_rate;
|
that.tableDatas[3][5] = data1.run_rate;
|
||||||
that.tableDatas[3][9] = precen(
|
that.tableDatas[3][9] = this.precen(
|
||||||
that.tableDatas[3][5],
|
that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][5] = data1.elec_consume_unit;
|
that.tableDatas[4][5] = data1.elec_consume_unit;
|
||||||
that.tableDatas[4][9] = consume_precen(
|
that.tableDatas[4][9] = this.consume_precen(
|
||||||
that.tableDatas[4][8] - that.tableDatas[4][5],
|
that.tableDatas[4][8] - that.tableDatas[4][5],
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][5] = data1.elec_consume;
|
that.tableDatas[5][5] = data1.elec_consume;
|
||||||
that.tableDatas[5][9] = consume_precen(
|
that.tableDatas[5][9] = this.consume_precen(
|
||||||
(that.tableDatas[5][8]-that.tableDatas[5][5]),
|
(that.tableDatas[5][8]-that.tableDatas[5][5]),
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
|
|
@ -852,32 +836,32 @@ export default {
|
||||||
if (res2.length > 0) {
|
if (res2.length > 0) {
|
||||||
let data2 = res2[0];
|
let data2 = res2[0];
|
||||||
that.tableDatas[0][4] = data2.total_production;
|
that.tableDatas[0][4] = data2.total_production;
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] = data2.production_hour;
|
that.tableDatas[1][4] = data2.production_hour;
|
||||||
that.tableDatas[1][7] = precen(
|
that.tableDatas[1][7] = this.precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.run_hour;
|
that.tableDatas[2][4] = data2.run_hour;
|
||||||
that.tableDatas[2][7] = precen(
|
that.tableDatas[2][7] = this.precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][4] = data2.run_rate;
|
that.tableDatas[3][4] = data2.run_rate;
|
||||||
that.tableDatas[3][7] = precen(
|
that.tableDatas[3][7] = this.precen(
|
||||||
that.tableDatas[3][4],
|
that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][4] = data2.elec_consume_unit;
|
that.tableDatas[4][4] = data2.elec_consume_unit;
|
||||||
that.tableDatas[4][7] = consume_precen(
|
that.tableDatas[4][7] = this.consume_precen(
|
||||||
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][4] = data2.elec_consume;
|
that.tableDatas[5][4] = data2.elec_consume;
|
||||||
that.tableDatas[5][7] = consume_precen(
|
that.tableDatas[5][7] = this.consume_precen(
|
||||||
(that.tableDatas[5][6]-that.tableDatas[5][4]),
|
(that.tableDatas[5][6]-that.tableDatas[5][4]),
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
|
|
@ -891,6 +875,22 @@ export default {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = (a / b)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
|
consume_precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = ((a / b)+1)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
typeRadioChange() {
|
typeRadioChange() {
|
||||||
this.searchDate = "";
|
this.searchDate = "";
|
||||||
},
|
},
|
||||||
|
|
@ -970,32 +970,32 @@ export default {
|
||||||
if (res2.length > 0) {
|
if (res2.length > 0) {
|
||||||
let data2 = res2[0];
|
let data2 = res2[0];
|
||||||
that.tableDatas[0][4] = data2.total_production;
|
that.tableDatas[0][4] = data2.total_production;
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] = data2.production_hour;
|
that.tableDatas[1][4] = data2.production_hour;
|
||||||
that.tableDatas[1][7] = precen(
|
that.tableDatas[1][7] = this.precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.run_hour;
|
that.tableDatas[2][4] = data2.run_hour;
|
||||||
that.tableDatas[2][7] = precen(
|
that.tableDatas[2][7] = this.precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][4] = data2.run_rate;
|
that.tableDatas[3][4] = data2.run_rate;
|
||||||
that.tableDatas[3][7] = precen(
|
that.tableDatas[3][7] = this.precen(
|
||||||
that.tableDatas[3][4],
|
that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][4] = data2.elec_consume_unit;
|
that.tableDatas[4][4] = data2.elec_consume_unit;
|
||||||
that.tableDatas[4][7] = consume_precen(
|
that.tableDatas[4][7] = this.consume_precen(
|
||||||
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][4] = data2.elec_consume;
|
that.tableDatas[5][4] = data2.elec_consume;
|
||||||
that.tableDatas[5][7] = consume_precen(
|
that.tableDatas[5][7] = this.consume_precen(
|
||||||
(that.tableDatas[5][6]-that.tableDatas[5][4]),
|
(that.tableDatas[5][6]-that.tableDatas[5][4]),
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1013,32 +1013,32 @@ export default {
|
||||||
if (res1.length > 0) {
|
if (res1.length > 0) {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] = data1.total_production;
|
that.tableDatas[0][5] = data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] = data1.production_hour;
|
that.tableDatas[1][5] = data1.production_hour;
|
||||||
that.tableDatas[1][9] = precen(
|
that.tableDatas[1][9] = this.precen(
|
||||||
that.tableDatas[1][5],
|
that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.run_hour;
|
that.tableDatas[2][5] = data1.run_hour;
|
||||||
that.tableDatas[2][9] = precen(
|
that.tableDatas[2][9] = this.precen(
|
||||||
that.tableDatas[2][5],
|
that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] = data1.run_rate;
|
that.tableDatas[3][5] = data1.run_rate;
|
||||||
that.tableDatas[3][9] = precen(
|
that.tableDatas[3][9] = this.precen(
|
||||||
that.tableDatas[3][5],
|
that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][5] = data1.elec_consume_unit;
|
that.tableDatas[4][5] = data1.elec_consume_unit;
|
||||||
that.tableDatas[4][9] = consume_precen(
|
that.tableDatas[4][9] = this.consume_precen(
|
||||||
that.tableDatas[4][8] - that.tableDatas[4][5],
|
that.tableDatas[4][8] - that.tableDatas[4][5],
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][5] = data1.elec_consume;
|
that.tableDatas[5][5] = data1.elec_consume;
|
||||||
that.tableDatas[5][9] = consume_precen(
|
that.tableDatas[5][9] = this.consume_precen(
|
||||||
(that.tableDatas[5][8]-that.tableDatas[5][5]),
|
(that.tableDatas[5][8]-that.tableDatas[5][5]),
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -896,22 +896,6 @@ export default {
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
function precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = (a / b) * 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
function consume_precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = ((a / b)+1)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
let that = this;
|
let that = this;
|
||||||
var myDate = new Date();
|
var myDate = new Date();
|
||||||
let year = (that.year = myDate.getFullYear());
|
let year = (that.year = myDate.getFullYear());
|
||||||
|
|
@ -1096,64 +1080,64 @@ export default {
|
||||||
if (res1.length > 0) {
|
if (res1.length > 0) {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] = data1.total_production;
|
that.tableDatas[0][5] = data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] = data1.production_hour;
|
that.tableDatas[1][5] = data1.production_hour;
|
||||||
that.tableDatas[1][9] = precen(
|
that.tableDatas[1][9] = this.precen(
|
||||||
that.tableDatas[1][5],
|
that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.run_hour;
|
that.tableDatas[2][5] = data1.run_hour;
|
||||||
that.tableDatas[2][9] = precen(
|
that.tableDatas[2][9] = this.precen(
|
||||||
that.tableDatas[2][5],
|
that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] = data1.run_rate;
|
that.tableDatas[3][5] = data1.run_rate;
|
||||||
that.tableDatas[3][9] = precen(
|
that.tableDatas[3][9] = this.precen(
|
||||||
that.tableDatas[3][5],
|
that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][5] = data1.elec_consume_unit;
|
that.tableDatas[4][5] = data1.elec_consume_unit;
|
||||||
that.tableDatas[4][9] = consume_precen(
|
that.tableDatas[4][9] = this.consume_precen(
|
||||||
(that.tableDatas[4][8]-that.tableDatas[4][5]),
|
(that.tableDatas[4][8]-that.tableDatas[4][5]),
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][5] =
|
that.tableDatas[5][5] =
|
||||||
data1.celec_consume_unit;
|
data1.celec_consume_unit;
|
||||||
that.tableDatas[5][9] = consume_precen(
|
that.tableDatas[5][9] = this.consume_precen(
|
||||||
(that.tableDatas[5][8]-that.tableDatas[5][5]),
|
(that.tableDatas[5][8]-that.tableDatas[5][5]),
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][5] = data1.coal_consume_unit;
|
that.tableDatas[6][5] = data1.coal_consume_unit;
|
||||||
that.tableDatas[6][9] = consume_precen(
|
that.tableDatas[6][9] = this.consume_precen(
|
||||||
(that.tableDatas[6][8]-that.tableDatas[6][5]),
|
(that.tableDatas[6][8]-that.tableDatas[6][5]),
|
||||||
that.tableDatas[6][8]
|
that.tableDatas[6][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][5] = data1.cen_consume_unit;
|
that.tableDatas[7][5] = data1.cen_consume_unit;
|
||||||
that.tableDatas[7][9] = consume_precen(
|
that.tableDatas[7][9] = this.consume_precen(
|
||||||
(that.tableDatas[7][8]-that.tableDatas[7][5]),
|
(that.tableDatas[7][8]-that.tableDatas[7][5]),
|
||||||
that.tableDatas[7][8]
|
that.tableDatas[7][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[8][5] = data1.elec_consume;
|
that.tableDatas[8][5] = data1.elec_consume;
|
||||||
that.tableDatas[8][9] = consume_precen(
|
that.tableDatas[8][9] = this.consume_precen(
|
||||||
(that.tableDatas[8][8]-that.tableDatas[8][5]),
|
(that.tableDatas[8][8]-that.tableDatas[8][5]),
|
||||||
that.tableDatas[8][8]
|
that.tableDatas[8][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[9][5] =
|
that.tableDatas[9][5] =
|
||||||
data1.production_cost_unit;
|
data1.production_cost_unit;
|
||||||
that.tableDatas[9][9] = consume_precen(
|
that.tableDatas[9][9] = this.consume_precen(
|
||||||
(that.tableDatas[9][8]-that.tableDatas[9][5]),
|
(that.tableDatas[9][8]-that.tableDatas[9][5]),
|
||||||
that.tableDatas[9][8]
|
that.tableDatas[9][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[10][5] = data1.ammonia_consume;
|
that.tableDatas[10][5] = data1.ammonia_consume;
|
||||||
that.tableDatas[10][9] = consume_precen(
|
that.tableDatas[10][9] = this.consume_precen(
|
||||||
that.tableDatas[10][8] - that.tableDatas[10][5],
|
that.tableDatas[10][8] - that.tableDatas[10][5],
|
||||||
that.tableDatas[10][8]
|
that.tableDatas[10][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[11][5] = (data1.ammonia_consume*1000/data1.total_production).toFixed(2);
|
that.tableDatas[11][5] = (data1.ammonia_consume*1000/data1.total_production).toFixed(2);
|
||||||
that.tableDatas[11][9] = consume_precen(
|
that.tableDatas[11][9] = this.consume_precen(
|
||||||
that.tableDatas[11][8] - that.tableDatas[11][5],
|
that.tableDatas[11][8] - that.tableDatas[11][5],
|
||||||
that.tableDatas[11][8]
|
that.tableDatas[11][8]
|
||||||
);
|
);
|
||||||
|
|
@ -1171,64 +1155,64 @@ export default {
|
||||||
if (res2.length > 0) {
|
if (res2.length > 0) {
|
||||||
let data2 = res2[0];
|
let data2 = res2[0];
|
||||||
that.tableDatas[0][4] = data2.total_production;
|
that.tableDatas[0][4] = data2.total_production;
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] = data2.production_hour;
|
that.tableDatas[1][4] = data2.production_hour;
|
||||||
that.tableDatas[1][7] = precen(
|
that.tableDatas[1][7] = this.precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.run_hour;
|
that.tableDatas[2][4] = data2.run_hour;
|
||||||
that.tableDatas[2][7] = precen(
|
that.tableDatas[2][7] = this.precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][4] = data2.run_rate;
|
that.tableDatas[3][4] = data2.run_rate;
|
||||||
that.tableDatas[3][7] = precen(
|
that.tableDatas[3][7] = this.precen(
|
||||||
that.tableDatas[3][4],
|
that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][4] = data2.elec_consume_unit;
|
that.tableDatas[4][4] = data2.elec_consume_unit;
|
||||||
that.tableDatas[4][7] = consume_precen(
|
that.tableDatas[4][7] = this.consume_precen(
|
||||||
that.tableDatas[4][6] - that.tableDatas[4][4],
|
that.tableDatas[4][6] - that.tableDatas[4][4],
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][4] =
|
that.tableDatas[5][4] =
|
||||||
data2.celec_consume_unit;
|
data2.celec_consume_unit;
|
||||||
that.tableDatas[5][7] = consume_precen(
|
that.tableDatas[5][7] = this.consume_precen(
|
||||||
that.tableDatas[5][6] - that.tableDatas[5][4],
|
that.tableDatas[5][6] - that.tableDatas[5][4],
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][4] = data2.coal_consume_unit;
|
that.tableDatas[6][4] = data2.coal_consume_unit;
|
||||||
that.tableDatas[6][7] = consume_precen(
|
that.tableDatas[6][7] = this.consume_precen(
|
||||||
that.tableDatas[6][6]-that.tableDatas[6][4],
|
that.tableDatas[6][6]-that.tableDatas[6][4],
|
||||||
that.tableDatas[6][6]
|
that.tableDatas[6][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][4] = data2.cen_consume_unit;
|
that.tableDatas[7][4] = data2.cen_consume_unit;
|
||||||
that.tableDatas[7][7] = consume_precen(
|
that.tableDatas[7][7] = this.consume_precen(
|
||||||
that.tableDatas[7][6]-that.tableDatas[7][4],
|
that.tableDatas[7][6]-that.tableDatas[7][4],
|
||||||
that.tableDatas[7][6]
|
that.tableDatas[7][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[8][4] = data2.elec_consume;
|
that.tableDatas[8][4] = data2.elec_consume;
|
||||||
that.tableDatas[8][7] = consume_precen(
|
that.tableDatas[8][7] = this.consume_precen(
|
||||||
that.tableDatas[8][6]-that.tableDatas[8][4],
|
that.tableDatas[8][6]-that.tableDatas[8][4],
|
||||||
that.tableDatas[8][6]
|
that.tableDatas[8][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[9][4] =
|
that.tableDatas[9][4] =
|
||||||
data2.production_cost_unit;
|
data2.production_cost_unit;
|
||||||
that.tableDatas[9][7] = consume_precen(
|
that.tableDatas[9][7] = this.consume_precen(
|
||||||
that.tableDatas[9][6]-that.tableDatas[9][4],
|
that.tableDatas[9][6]-that.tableDatas[9][4],
|
||||||
that.tableDatas[9][6]
|
that.tableDatas[9][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[10][4] = data2.ammonia_consume;
|
that.tableDatas[10][4] = data2.ammonia_consume;
|
||||||
that.tableDatas[10][7] = consume_precen(
|
that.tableDatas[10][7] = this.consume_precen(
|
||||||
that.tableDatas[10][6] - that.tableDatas[10][4],
|
that.tableDatas[10][6] - that.tableDatas[10][4],
|
||||||
that.tableDatas[10][6]
|
that.tableDatas[10][6]
|
||||||
)
|
)
|
||||||
that.tableDatas[11][4] = (data2.ammonia_consume*1000/data2.total_production).toFixed(2);
|
that.tableDatas[11][4] = (data2.ammonia_consume*1000/data2.total_production).toFixed(2);
|
||||||
that.tableDatas[11][7] = consume_precen(
|
that.tableDatas[11][7] = this.consume_precen(
|
||||||
that.tableDatas[11][6] - that.tableDatas[11][4],
|
that.tableDatas[11][6] - that.tableDatas[11][4],
|
||||||
that.tableDatas[11][6]
|
that.tableDatas[11][6]
|
||||||
)
|
)
|
||||||
|
|
@ -1241,6 +1225,22 @@ export default {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = (a / b) * 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
|
consume_precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = ((a / b)+1)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
typeRadioChange() {
|
typeRadioChange() {
|
||||||
this.searchDate = "";
|
this.searchDate = "";
|
||||||
},
|
},
|
||||||
|
|
@ -1327,64 +1327,64 @@ export default {
|
||||||
if (res2.length > 0) {
|
if (res2.length > 0) {
|
||||||
let data2 = res2[0];
|
let data2 = res2[0];
|
||||||
that.tableDatas[0][4] = data2.total_production;
|
that.tableDatas[0][4] = data2.total_production;
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] = data2.production_hour;
|
that.tableDatas[1][4] = data2.production_hour;
|
||||||
that.tableDatas[1][7] = precen(
|
that.tableDatas[1][7] = this.precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.run_hour;
|
that.tableDatas[2][4] = data2.run_hour;
|
||||||
that.tableDatas[2][7] = precen(
|
that.tableDatas[2][7] = this.precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][4] = data2.run_rate;
|
that.tableDatas[3][4] = data2.run_rate;
|
||||||
that.tableDatas[3][7] = precen(
|
that.tableDatas[3][7] = this.precen(
|
||||||
that.tableDatas[3][4],
|
that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][4] = data2.elec_consume_unit;
|
that.tableDatas[4][4] = data2.elec_consume_unit;
|
||||||
that.tableDatas[4][7] = consume_precen(
|
that.tableDatas[4][7] = this.consume_precen(
|
||||||
that.tableDatas[4][6] - that.tableDatas[4][4],
|
that.tableDatas[4][6] - that.tableDatas[4][4],
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][4] =
|
that.tableDatas[5][4] =
|
||||||
data2.celec_consume_unit;
|
data2.celec_consume_unit;
|
||||||
that.tableDatas[5][7] = consume_precen(
|
that.tableDatas[5][7] = this.consume_precen(
|
||||||
that.tableDatas[5][6] - that.tableDatas[5][4],
|
that.tableDatas[5][6] - that.tableDatas[5][4],
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][4] = data2.coal_consume_unit;
|
that.tableDatas[6][4] = data2.coal_consume_unit;
|
||||||
that.tableDatas[6][7] = consume_precen(
|
that.tableDatas[6][7] = this.consume_precen(
|
||||||
that.tableDatas[6][6]-that.tableDatas[6][4],
|
that.tableDatas[6][6]-that.tableDatas[6][4],
|
||||||
that.tableDatas[6][6]
|
that.tableDatas[6][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][4] = data2.cen_consume_unit;
|
that.tableDatas[7][4] = data2.cen_consume_unit;
|
||||||
that.tableDatas[7][7] = consume_precen(
|
that.tableDatas[7][7] = this.consume_precen(
|
||||||
that.tableDatas[7][6]-that.tableDatas[7][4],
|
that.tableDatas[7][6]-that.tableDatas[7][4],
|
||||||
that.tableDatas[7][6]
|
that.tableDatas[7][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[8][4] = data2.elec_consume;
|
that.tableDatas[8][4] = data2.elec_consume;
|
||||||
that.tableDatas[8][7] = consume_precen(
|
that.tableDatas[8][7] = this.consume_precen(
|
||||||
that.tableDatas[8][6]-that.tableDatas[8][4],
|
that.tableDatas[8][6]-that.tableDatas[8][4],
|
||||||
that.tableDatas[8][6]
|
that.tableDatas[8][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[9][4] =
|
that.tableDatas[9][4] =
|
||||||
data2.production_cost_unit;
|
data2.production_cost_unit;
|
||||||
that.tableDatas[9][7] = consume_precen(
|
that.tableDatas[9][7] = this.consume_precen(
|
||||||
that.tableDatas[9][6]-that.tableDatas[9][4],
|
that.tableDatas[9][6]-that.tableDatas[9][4],
|
||||||
that.tableDatas[9][6]
|
that.tableDatas[9][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[10][4] = data2.ammonia_consume;
|
that.tableDatas[10][4] = data2.ammonia_consume;
|
||||||
that.tableDatas[10][7] = consume_precen(
|
that.tableDatas[10][7] = this.consume_precen(
|
||||||
that.tableDatas[10][6] - that.tableDatas[10][4],
|
that.tableDatas[10][6] - that.tableDatas[10][4],
|
||||||
that.tableDatas[10][6]
|
that.tableDatas[10][6]
|
||||||
)
|
)
|
||||||
that.tableDatas[11][4] = (data2.ammonia_consume*1000/data2.total_production).toFixed(2);
|
that.tableDatas[11][4] = (data2.ammonia_consume*1000/data2.total_production).toFixed(2);
|
||||||
that.tableDatas[11][7] = consume_precen(
|
that.tableDatas[11][7] = this.consume_precen(
|
||||||
that.tableDatas[11][6] - that.tableDatas[11][4],
|
that.tableDatas[11][6] - that.tableDatas[11][4],
|
||||||
that.tableDatas[11][6]
|
that.tableDatas[11][6]
|
||||||
)
|
)
|
||||||
|
|
@ -1402,64 +1402,64 @@ export default {
|
||||||
if (res1.length > 0) {
|
if (res1.length > 0) {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] = data1.total_production;
|
that.tableDatas[0][5] = data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] = data1.production_hour;
|
that.tableDatas[1][5] = data1.production_hour;
|
||||||
that.tableDatas[1][9] = precen(
|
that.tableDatas[1][9] = this.precen(
|
||||||
that.tableDatas[1][5],
|
that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.run_hour;
|
that.tableDatas[2][5] = data1.run_hour;
|
||||||
that.tableDatas[2][9] = precen(
|
that.tableDatas[2][9] = this.precen(
|
||||||
that.tableDatas[2][5],
|
that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] = data1.run_rate;
|
that.tableDatas[3][5] = data1.run_rate;
|
||||||
that.tableDatas[3][9] = precen(
|
that.tableDatas[3][9] = this.precen(
|
||||||
that.tableDatas[3][5],
|
that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][5] = data1.elec_consume_unit;
|
that.tableDatas[4][5] = data1.elec_consume_unit;
|
||||||
that.tableDatas[4][9] = consume_precen(
|
that.tableDatas[4][9] = this.consume_precen(
|
||||||
(that.tableDatas[4][8]-that.tableDatas[4][5]),
|
(that.tableDatas[4][8]-that.tableDatas[4][5]),
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][5] =
|
that.tableDatas[5][5] =
|
||||||
data1.celec_consume_unit;
|
data1.celec_consume_unit;
|
||||||
that.tableDatas[5][9] = consume_precen(
|
that.tableDatas[5][9] = this.consume_precen(
|
||||||
(that.tableDatas[5][8]-that.tableDatas[5][5]),
|
(that.tableDatas[5][8]-that.tableDatas[5][5]),
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][5] = data1.coal_consume_unit;
|
that.tableDatas[6][5] = data1.coal_consume_unit;
|
||||||
that.tableDatas[6][9] = consume_precen(
|
that.tableDatas[6][9] = this.consume_precen(
|
||||||
(that.tableDatas[6][8]-that.tableDatas[6][5]),
|
(that.tableDatas[6][8]-that.tableDatas[6][5]),
|
||||||
that.tableDatas[6][8]
|
that.tableDatas[6][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][5] = data1.cen_consume_unit;
|
that.tableDatas[7][5] = data1.cen_consume_unit;
|
||||||
that.tableDatas[7][9] = consume_precen(
|
that.tableDatas[7][9] = this.consume_precen(
|
||||||
(that.tableDatas[7][8]-that.tableDatas[7][5]),
|
(that.tableDatas[7][8]-that.tableDatas[7][5]),
|
||||||
that.tableDatas[7][8]
|
that.tableDatas[7][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[8][5] = data1.elec_consume;
|
that.tableDatas[8][5] = data1.elec_consume;
|
||||||
that.tableDatas[8][9] = consume_precen(
|
that.tableDatas[8][9] = this.consume_precen(
|
||||||
(that.tableDatas[8][8]-that.tableDatas[8][5]),
|
(that.tableDatas[8][8]-that.tableDatas[8][5]),
|
||||||
that.tableDatas[8][8]
|
that.tableDatas[8][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[9][5] =
|
that.tableDatas[9][5] =
|
||||||
data1.production_cost_unit;
|
data1.production_cost_unit;
|
||||||
that.tableDatas[9][9] = consume_precen(
|
that.tableDatas[9][9] = this.consume_precen(
|
||||||
(that.tableDatas[9][8]-that.tableDatas[9][5]),
|
(that.tableDatas[9][8]-that.tableDatas[9][5]),
|
||||||
that.tableDatas[9][8]
|
that.tableDatas[9][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[10][5] = data1.ammonia_consume;
|
that.tableDatas[10][5] = data1.ammonia_consume;
|
||||||
that.tableDatas[10][9] = consume_precen(
|
that.tableDatas[10][9] = this.consume_precen(
|
||||||
that.tableDatas[10][8] - that.tableDatas[10][5],
|
that.tableDatas[10][8] - that.tableDatas[10][5],
|
||||||
that.tableDatas[10][8]
|
that.tableDatas[10][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[11][5] = (data1.ammonia_consume*1000/data1.total_production).toFixed(2);
|
that.tableDatas[11][5] = (data1.ammonia_consume*1000/data1.total_production).toFixed(2);
|
||||||
that.tableDatas[11][9] = consume_precen(
|
that.tableDatas[11][9] = this.consume_precen(
|
||||||
that.tableDatas[11][8] - that.tableDatas[11][5],
|
that.tableDatas[11][8] - that.tableDatas[11][5],
|
||||||
that.tableDatas[11][8]
|
that.tableDatas[11][8]
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -807,22 +807,7 @@ export default {
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
function precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = (a / b) * 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
function consume_precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = ((a / b)+1)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
let that = this;
|
let that = this;
|
||||||
var myDate = new Date();
|
var myDate = new Date();
|
||||||
let year = (that.year = myDate.getFullYear());
|
let year = (that.year = myDate.getFullYear());
|
||||||
|
|
@ -982,43 +967,43 @@ export default {
|
||||||
if (res1.length > 0) {
|
if (res1.length > 0) {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] = data1.total_production;
|
that.tableDatas[0][5] = data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] = data1.production_hour;
|
that.tableDatas[1][5] = data1.production_hour;
|
||||||
that.tableDatas[1][9] = precen(
|
that.tableDatas[1][9] = this.precen(
|
||||||
that.tableDatas[1][5],
|
that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.run_hour;
|
that.tableDatas[2][5] = data1.run_hour;
|
||||||
that.tableDatas[2][9] = precen(
|
that.tableDatas[2][9] = this.precen(
|
||||||
that.tableDatas[2][5],
|
that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] = data1.run_rate;
|
that.tableDatas[3][5] = data1.run_rate;
|
||||||
that.tableDatas[3][9] = precen(
|
that.tableDatas[3][9] = this.precen(
|
||||||
that.tableDatas[3][5],
|
that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][5] = data1.elec_consume_unit;
|
that.tableDatas[4][5] = data1.elec_consume_unit;
|
||||||
that.tableDatas[4][9] = consume_precen(
|
that.tableDatas[4][9] = this.consume_precen(
|
||||||
that.tableDatas[4][8]-that.tableDatas[4][5],
|
that.tableDatas[4][8]-that.tableDatas[4][5],
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][5] = data1.cen_consume_unit;
|
that.tableDatas[5][5] = data1.cen_consume_unit;
|
||||||
that.tableDatas[5][9] = consume_precen(
|
that.tableDatas[5][9] = this.consume_precen(
|
||||||
that.tableDatas[5][8]-that.tableDatas[5][5],
|
that.tableDatas[5][8]-that.tableDatas[5][5],
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][5] = data1.elec_consume;
|
that.tableDatas[6][5] = data1.elec_consume;
|
||||||
that.tableDatas[6][9] = consume_precen(
|
that.tableDatas[6][9] = this.consume_precen(
|
||||||
that.tableDatas[6][8]-that.tableDatas[6][5],
|
that.tableDatas[6][8]-that.tableDatas[6][5],
|
||||||
that.tableDatas[6][8]
|
that.tableDatas[6][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][5] =
|
that.tableDatas[7][5] =
|
||||||
data1.production_cost_unit;
|
data1.production_cost_unit;
|
||||||
that.tableDatas[7][9] = consume_precen(
|
that.tableDatas[7][9] = this.consume_precen(
|
||||||
that.tableDatas[7][8]-that.tableDatas[7][5],
|
that.tableDatas[7][8]-that.tableDatas[7][5],
|
||||||
that.tableDatas[7][8]
|
that.tableDatas[7][8]
|
||||||
);
|
);
|
||||||
|
|
@ -1036,43 +1021,43 @@ export default {
|
||||||
if (res2.length > 0) {
|
if (res2.length > 0) {
|
||||||
let data2 = res2[0];
|
let data2 = res2[0];
|
||||||
that.tableDatas[0][4] = data2.total_production;
|
that.tableDatas[0][4] = data2.total_production;
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] = data2.production_hour;
|
that.tableDatas[1][4] = data2.production_hour;
|
||||||
that.tableDatas[1][7] = precen(
|
that.tableDatas[1][7] = this.precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.run_hour;
|
that.tableDatas[2][4] = data2.run_hour;
|
||||||
that.tableDatas[2][7] = precen(
|
that.tableDatas[2][7] = this.precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][4] = data2.run_rate;
|
that.tableDatas[3][4] = data2.run_rate;
|
||||||
that.tableDatas[3][7] = precen(
|
that.tableDatas[3][7] = this.precen(
|
||||||
that.tableDatas[3][4],
|
that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][4] = data2.elec_consume_unit;
|
that.tableDatas[4][4] = data2.elec_consume_unit;
|
||||||
that.tableDatas[4][7] = consume_precen(
|
that.tableDatas[4][7] = this.consume_precen(
|
||||||
that.tableDatas[4][6]-that.tableDatas[4][4],
|
that.tableDatas[4][6]-that.tableDatas[4][4],
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][4] = data2.cen_consume_unit;
|
that.tableDatas[5][4] = data2.cen_consume_unit;
|
||||||
that.tableDatas[5][7] = consume_precen(
|
that.tableDatas[5][7] = this.consume_precen(
|
||||||
that.tableDatas[5][6]-that.tableDatas[5][4],
|
that.tableDatas[5][6]-that.tableDatas[5][4],
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][4] =
|
that.tableDatas[7][4] =
|
||||||
data2.production_cost_unit;
|
data2.production_cost_unit;
|
||||||
that.tableDatas[6][4] = data2.elec_consume;
|
that.tableDatas[6][4] = data2.elec_consume;
|
||||||
that.tableDatas[6][7] = consume_precen(
|
that.tableDatas[6][7] = this.consume_precen(
|
||||||
that.tableDatas[6][6]-that.tableDatas[6][4],
|
that.tableDatas[6][6]-that.tableDatas[6][4],
|
||||||
that.tableDatas[6][6]
|
that.tableDatas[6][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][7] = consume_precen(
|
that.tableDatas[7][7] = this.consume_precen(
|
||||||
that.tableDatas[7][6]-that.tableDatas[7][4],
|
that.tableDatas[7][6]-that.tableDatas[7][4],
|
||||||
that.tableDatas[7][6]
|
that.tableDatas[7][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1085,6 +1070,22 @@ export default {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = (a / b) * 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
consume_precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = ((a / b)+1)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
},
|
||||||
typeRadioChange() {
|
typeRadioChange() {
|
||||||
this.searchDate = "";
|
this.searchDate = "";
|
||||||
},
|
},
|
||||||
|
|
@ -1165,43 +1166,43 @@ export default {
|
||||||
if (res2.length > 0) {
|
if (res2.length > 0) {
|
||||||
let data2 = res2[0];
|
let data2 = res2[0];
|
||||||
that.tableDatas[0][4] = data2.total_production;
|
that.tableDatas[0][4] = data2.total_production;
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] = data2.production_hour;
|
that.tableDatas[1][4] = data2.production_hour;
|
||||||
that.tableDatas[1][7] = precen(
|
that.tableDatas[1][7] = this.precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.run_hour;
|
that.tableDatas[2][4] = data2.run_hour;
|
||||||
that.tableDatas[2][7] = precen(
|
that.tableDatas[2][7] = this.precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][4] = data2.run_rate;
|
that.tableDatas[3][4] = data2.run_rate;
|
||||||
that.tableDatas[3][7] = precen(
|
that.tableDatas[3][7] = this.precen(
|
||||||
that.tableDatas[3][4],
|
that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][4] = data2.elec_consume_unit;
|
that.tableDatas[4][4] = data2.elec_consume_unit;
|
||||||
that.tableDatas[4][7] = consume_precen(
|
that.tableDatas[4][7] = this.consume_precen(
|
||||||
that.tableDatas[4][6]-that.tableDatas[4][4],
|
that.tableDatas[4][6]-that.tableDatas[4][4],
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][4] = data2.cen_consume_unit;
|
that.tableDatas[5][4] = data2.cen_consume_unit;
|
||||||
that.tableDatas[5][7] = consume_precen(
|
that.tableDatas[5][7] = this.consume_precen(
|
||||||
that.tableDatas[5][6]-that.tableDatas[5][4],
|
that.tableDatas[5][6]-that.tableDatas[5][4],
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][4] =
|
that.tableDatas[7][4] =
|
||||||
data2.production_cost_unit;
|
data2.production_cost_unit;
|
||||||
that.tableDatas[6][4] = data2.elec_consume;
|
that.tableDatas[6][4] = data2.elec_consume;
|
||||||
that.tableDatas[6][7] = consume_precen(
|
that.tableDatas[6][7] = this.consume_precen(
|
||||||
that.tableDatas[6][6]-that.tableDatas[6][4],
|
that.tableDatas[6][6]-that.tableDatas[6][4],
|
||||||
that.tableDatas[6][6]
|
that.tableDatas[6][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][7] = consume_precen(
|
that.tableDatas[7][7] = this.consume_precen(
|
||||||
that.tableDatas[7][6]-that.tableDatas[7][4],
|
that.tableDatas[7][6]-that.tableDatas[7][4],
|
||||||
that.tableDatas[7][6]
|
that.tableDatas[7][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1219,43 +1220,43 @@ export default {
|
||||||
if (res1.length > 0) {
|
if (res1.length > 0) {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] = data1.total_production;
|
that.tableDatas[0][5] = data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] = data1.production_hour;
|
that.tableDatas[1][5] = data1.production_hour;
|
||||||
that.tableDatas[1][9] = precen(
|
that.tableDatas[1][9] = this.precen(
|
||||||
that.tableDatas[1][5],
|
that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.run_hour;
|
that.tableDatas[2][5] = data1.run_hour;
|
||||||
that.tableDatas[2][9] = precen(
|
that.tableDatas[2][9] = this.precen(
|
||||||
that.tableDatas[2][5],
|
that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] = data1.run_rate;
|
that.tableDatas[3][5] = data1.run_rate;
|
||||||
that.tableDatas[3][9] = precen(
|
that.tableDatas[3][9] = this.precen(
|
||||||
that.tableDatas[3][5],
|
that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][5] = data1.elec_consume_unit;
|
that.tableDatas[4][5] = data1.elec_consume_unit;
|
||||||
that.tableDatas[4][9] = consume_precen(
|
that.tableDatas[4][9] = this.consume_precen(
|
||||||
that.tableDatas[4][8]-that.tableDatas[4][5],
|
that.tableDatas[4][8]-that.tableDatas[4][5],
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][5] = data1.cen_consume_unit;
|
that.tableDatas[5][5] = data1.cen_consume_unit;
|
||||||
that.tableDatas[5][9] = consume_precen(
|
that.tableDatas[5][9] = this.consume_precen(
|
||||||
that.tableDatas[5][8]-that.tableDatas[5][5],
|
that.tableDatas[5][8]-that.tableDatas[5][5],
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][5] = data1.elec_consume;
|
that.tableDatas[6][5] = data1.elec_consume;
|
||||||
that.tableDatas[6][9] = consume_precen(
|
that.tableDatas[6][9] = this.consume_precen(
|
||||||
that.tableDatas[6][8]-that.tableDatas[6][5],
|
that.tableDatas[6][8]-that.tableDatas[6][5],
|
||||||
that.tableDatas[6][8]
|
that.tableDatas[6][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[7][5] =
|
that.tableDatas[7][5] =
|
||||||
data1.production_cost_unit;
|
data1.production_cost_unit;
|
||||||
that.tableDatas[7][9] = consume_precen(
|
that.tableDatas[7][9] = this.consume_precen(
|
||||||
that.tableDatas[7][8]-that.tableDatas[7][5],
|
that.tableDatas[7][8]-that.tableDatas[7][5],
|
||||||
that.tableDatas[7][8]
|
that.tableDatas[7][8]
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -920,22 +920,6 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
mounted() {
|
mounted() {
|
||||||
function precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = (a / b)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
function consume_precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = ((a / b)+1)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
let that = this;
|
let that = this;
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
var myDate = new Date();
|
var myDate = new Date();
|
||||||
|
|
@ -1081,34 +1065,34 @@ export default {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] =
|
that.tableDatas[0][5] =
|
||||||
data1.total_production;
|
data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] =
|
that.tableDatas[1][5] =
|
||||||
data1.production_hour;
|
data1.production_hour;
|
||||||
that.tableDatas[1][9] = precen(
|
that.tableDatas[1][9] = this.precen(
|
||||||
that.tableDatas[1][5],
|
that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.run_hour;
|
that.tableDatas[2][5] = data1.run_hour;
|
||||||
that.tableDatas[2][9] = precen(
|
that.tableDatas[2][9] = this.precen(
|
||||||
that.tableDatas[2][5],
|
that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] = data1.run_rate;
|
that.tableDatas[3][5] = data1.run_rate;
|
||||||
that.tableDatas[3][9] = precen(
|
that.tableDatas[3][9] = this.precen(
|
||||||
that.tableDatas[3][5],
|
that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][5] =
|
that.tableDatas[4][5] =
|
||||||
data1.elec_consume_unit;
|
data1.elec_consume_unit;
|
||||||
that.tableDatas[4][9] = consume_precen(
|
that.tableDatas[4][9] = this.consume_precen(
|
||||||
(that.tableDatas[4][8]-that.tableDatas[4][5]),
|
(that.tableDatas[4][8]-that.tableDatas[4][5]),
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][5] = data1.elec_consume;
|
that.tableDatas[5][5] = data1.elec_consume;
|
||||||
that.tableDatas[5][9] = consume_precen(
|
that.tableDatas[5][9] = this.consume_precen(
|
||||||
(that.tableDatas[5][8] - that.tableDatas[5][5]),
|
(that.tableDatas[5][8] - that.tableDatas[5][5]),
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
|
|
@ -1134,34 +1118,34 @@ export default {
|
||||||
) {
|
) {
|
||||||
that.wraning = true;
|
that.wraning = true;
|
||||||
}
|
}
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] =
|
that.tableDatas[1][4] =
|
||||||
data2.production_hour;
|
data2.production_hour;
|
||||||
that.tableDatas[1][7] = precen(
|
that.tableDatas[1][7] = this.precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.run_hour;
|
that.tableDatas[2][4] = data2.run_hour;
|
||||||
that.tableDatas[2][7] = precen(
|
that.tableDatas[2][7] = this.precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][4] = data2.run_rate;
|
that.tableDatas[3][4] = data2.run_rate;
|
||||||
that.tableDatas[3][7] = precen(
|
that.tableDatas[3][7] = this.precen(
|
||||||
that.tableDatas[3][4],
|
that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][4] =
|
that.tableDatas[4][4] =
|
||||||
data2.elec_consume_unit;
|
data2.elec_consume_unit;
|
||||||
that.tableDatas[4][7] = consume_precen(
|
that.tableDatas[4][7] = this.consume_precen(
|
||||||
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][4] = data2.elec_consume;
|
that.tableDatas[5][4] = data2.elec_consume;
|
||||||
that.tableDatas[5][7] = consume_precen(
|
that.tableDatas[5][7] = this.consume_precen(
|
||||||
(that.tableDatas[5][6] - that.tableDatas[5][4]),
|
(that.tableDatas[5][6] - that.tableDatas[5][4]),
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1176,6 +1160,22 @@ export default {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = (a / b)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
|
consume_precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = ((a / b)+1)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
typeRadioChange() {
|
typeRadioChange() {
|
||||||
this.searchDate = "";
|
this.searchDate = "";
|
||||||
},
|
},
|
||||||
|
|
@ -1259,23 +1259,23 @@ export default {
|
||||||
if (res2.length > 0) {
|
if (res2.length > 0) {
|
||||||
let data2 = res2[0];
|
let data2 = res2[0];
|
||||||
that.tableDatas[0][4] = data2.total_production;
|
that.tableDatas[0][4] = data2.total_production;
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] = data2.elec_consume_unit;
|
that.tableDatas[1][4] = data2.elec_consume_unit;
|
||||||
that.tableDatas[1][7] = consume_precen(
|
that.tableDatas[1][7] = this.consume_precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.elec_consume;
|
that.tableDatas[2][4] = data2.elec_consume;
|
||||||
that.tableDatas[3][4] =
|
that.tableDatas[3][4] =
|
||||||
data2.production_cost_unit;
|
data2.production_cost_unit;
|
||||||
that.tableDatas[3][7] = consume_precen(
|
that.tableDatas[3][7] = this.consume_precen(
|
||||||
that.tableDatas[3][3],
|
that.tableDatas[3][3],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][7] = consume_precen(
|
that.tableDatas[2][7] = this.consume_precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1283,13 +1283,13 @@ export default {
|
||||||
data2.imaterial_data.forEach((item) => {
|
data2.imaterial_data.forEach((item) => {
|
||||||
if (item.material_name == "湿电石渣消耗") {
|
if (item.material_name == "湿电石渣消耗") {
|
||||||
that.tableDatas[4][4] = (item.amount_consume).toFixed(2);
|
that.tableDatas[4][4] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[4][7] = precen(
|
that.tableDatas[4][7] = this.precen(
|
||||||
that.tableDatas[4][4],
|
that.tableDatas[4][4],
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
}else if(item.material_name == "湿电石渣进厂"){
|
}else if(item.material_name == "湿电石渣进厂"){
|
||||||
that.tableDatas[5][4] = (item.amount_consume).toFixed(2);
|
that.tableDatas[5][4] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[5][7] = precen(
|
that.tableDatas[5][7] = this.precen(
|
||||||
that.tableDatas[5][4],
|
that.tableDatas[5][4],
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1357,23 +1357,23 @@ export default {
|
||||||
if (res1.length > 0) {
|
if (res1.length > 0) {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] = data1.total_production;
|
that.tableDatas[0][5] = data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] = data1.elec_consume_unit;
|
that.tableDatas[1][5] = data1.elec_consume_unit;
|
||||||
that.tableDatas[1][9] = consume_precen(
|
that.tableDatas[1][9] = this.consume_precen(
|
||||||
that.tableDatas[1][8]-that.tableDatas[1][5],
|
that.tableDatas[1][8]-that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.elec_consume;
|
that.tableDatas[2][5] = data1.elec_consume;
|
||||||
that.tableDatas[2][9] = consume_precen(
|
that.tableDatas[2][9] = this.consume_precen(
|
||||||
that.tableDatas[2][8]-that.tableDatas[2][5],
|
that.tableDatas[2][8]-that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] =
|
that.tableDatas[3][5] =
|
||||||
data1.production_cost_unit;
|
data1.production_cost_unit;
|
||||||
that.tableDatas[3][9] = consume_precen(
|
that.tableDatas[3][9] = this.consume_precen(
|
||||||
that.tableDatas[3][8]-that.tableDatas[3][5],
|
that.tableDatas[3][8]-that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
|
|
@ -1381,13 +1381,13 @@ export default {
|
||||||
data1.imaterial_data.forEach((item) => {
|
data1.imaterial_data.forEach((item) => {
|
||||||
if (item.material_name == "湿电石渣消耗") {
|
if (item.material_name == "湿电石渣消耗") {
|
||||||
that.tableDatas[4][5] = (item.amount_consume).toFixed(2);
|
that.tableDatas[4][5] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[4][9] = precen(
|
that.tableDatas[4][9] = this.precen(
|
||||||
that.tableDatas[4][5],
|
that.tableDatas[4][5],
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
}else if(item.material_name == "湿电石渣进厂"){
|
}else if(item.material_name == "湿电石渣进厂"){
|
||||||
that.tableDatas[5][5] = (item.amount_consume).toFixed(2);
|
that.tableDatas[5][5] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[5][9] = precen(
|
that.tableDatas[5][9] = this.precen(
|
||||||
that.tableDatas[5][5],
|
that.tableDatas[5][5],
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -966,22 +966,6 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
mounted() {
|
mounted() {
|
||||||
function precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = (a / b)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
function consume_precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = ((a / b)+1)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
let that = this;
|
let that = this;
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
var myDate = new Date();
|
var myDate = new Date();
|
||||||
|
|
@ -1131,40 +1115,40 @@ export default {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] =
|
that.tableDatas[0][5] =
|
||||||
data1.total_production;
|
data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] =
|
that.tableDatas[1][5] =
|
||||||
data1.production_hour;
|
data1.production_hour;
|
||||||
that.tableDatas[1][9] = precen(
|
that.tableDatas[1][9] = this.precen(
|
||||||
that.tableDatas[1][5],
|
that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.run_hour;
|
that.tableDatas[2][5] = data1.run_hour;
|
||||||
that.tableDatas[2][9] = precen(
|
that.tableDatas[2][9] = this.precen(
|
||||||
that.tableDatas[2][5],
|
that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] = data1.run_rate;
|
that.tableDatas[3][5] = data1.run_rate;
|
||||||
that.tableDatas[3][9] = precen(
|
that.tableDatas[3][9] = this.precen(
|
||||||
that.tableDatas[3][5],
|
that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][5] =
|
that.tableDatas[4][5] =
|
||||||
data1.elec_consume_unit;
|
data1.elec_consume_unit;
|
||||||
that.tableDatas[4][9] = consume_precen(
|
that.tableDatas[4][9] = this.consume_precen(
|
||||||
(that.tableDatas[4][8] - that.tableDatas[4][5]),
|
(that.tableDatas[4][8] - that.tableDatas[4][5]),
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][5] = data1.elec_consume;
|
that.tableDatas[5][5] = data1.elec_consume;
|
||||||
that.tableDatas[5][9] = consume_precen(
|
that.tableDatas[5][9] = this.consume_precen(
|
||||||
(that.tableDatas[5][8] - that.tableDatas[5][5]),
|
(that.tableDatas[5][8] - that.tableDatas[5][5]),
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][5] =
|
that.tableDatas[6][5] =
|
||||||
data1.production_cost_unit;
|
data1.production_cost_unit;
|
||||||
that.tableDatas[6][9] = consume_precen(
|
that.tableDatas[6][9] = this.consume_precen(
|
||||||
(that.tableDatas[6][8] - that.tableDatas[6][5]),
|
(that.tableDatas[6][8] - that.tableDatas[6][5]),
|
||||||
that.tableDatas[6][8]
|
that.tableDatas[6][8]
|
||||||
);
|
);
|
||||||
|
|
@ -1189,40 +1173,40 @@ export default {
|
||||||
) {
|
) {
|
||||||
that.wraning = true;
|
that.wraning = true;
|
||||||
}
|
}
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] =
|
that.tableDatas[1][4] =
|
||||||
data2.production_hour;
|
data2.production_hour;
|
||||||
that.tableDatas[1][7] = precen(
|
that.tableDatas[1][7] = this.precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.run_hour;
|
that.tableDatas[2][4] = data2.run_hour;
|
||||||
that.tableDatas[2][7] = precen(
|
that.tableDatas[2][7] = this.precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][4] = data2.run_rate;
|
that.tableDatas[3][4] = data2.run_rate;
|
||||||
that.tableDatas[3][7] = precen(
|
that.tableDatas[3][7] = this.precen(
|
||||||
that.tableDatas[3][4],
|
that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][4] =
|
that.tableDatas[4][4] =
|
||||||
data2.elec_consume_unit;
|
data2.elec_consume_unit;
|
||||||
that.tableDatas[4][7] = consume_precen(
|
that.tableDatas[4][7] = this.consume_precen(
|
||||||
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][4] = data2.elec_consume;
|
that.tableDatas[5][4] = data2.elec_consume;
|
||||||
that.tableDatas[5][7] = consume_precen(
|
that.tableDatas[5][7] = this.consume_precen(
|
||||||
(that.tableDatas[5][6]-that.tableDatas[5][4]),
|
(that.tableDatas[5][6]-that.tableDatas[5][4]),
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][4] =
|
that.tableDatas[6][4] =
|
||||||
data2.production_cost_unit;
|
data2.production_cost_unit;
|
||||||
that.tableDatas[6][7] = consume_precen(
|
that.tableDatas[6][7] = this.consume_precen(
|
||||||
(that.tableDatas[6][6] - that.tableDatas[6][4]),
|
(that.tableDatas[6][6] - that.tableDatas[6][4]),
|
||||||
that.tableDatas[6][6]
|
that.tableDatas[6][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1236,6 +1220,22 @@ export default {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = (a / b)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
|
consume_precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = ((a / b)+1)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
typeRadioChange() {
|
typeRadioChange() {
|
||||||
this.searchDate = "";
|
this.searchDate = "";
|
||||||
},
|
},
|
||||||
|
|
@ -1318,40 +1318,40 @@ export default {
|
||||||
) {
|
) {
|
||||||
that.wraning = true;
|
that.wraning = true;
|
||||||
}
|
}
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] =
|
that.tableDatas[1][4] =
|
||||||
data2.production_hour;
|
data2.production_hour;
|
||||||
that.tableDatas[1][7] = precen(
|
that.tableDatas[1][7] = this.precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.run_hour;
|
that.tableDatas[2][4] = data2.run_hour;
|
||||||
that.tableDatas[2][7] = precen(
|
that.tableDatas[2][7] = this.precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][4] = data2.run_rate;
|
that.tableDatas[3][4] = data2.run_rate;
|
||||||
that.tableDatas[3][7] = precen(
|
that.tableDatas[3][7] = this.precen(
|
||||||
that.tableDatas[3][4],
|
that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][4] =
|
that.tableDatas[4][4] =
|
||||||
data2.elec_consume_unit;
|
data2.elec_consume_unit;
|
||||||
that.tableDatas[4][7] = consume_precen(
|
that.tableDatas[4][7] = this.consume_precen(
|
||||||
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
(that.tableDatas[4][6]-that.tableDatas[4][4]),
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][4] = data2.elec_consume;
|
that.tableDatas[5][4] = data2.elec_consume;
|
||||||
that.tableDatas[5][7] = consume_precen(
|
that.tableDatas[5][7] = this.consume_precen(
|
||||||
(that.tableDatas[5][6]-that.tableDatas[5][4]),
|
(that.tableDatas[5][6]-that.tableDatas[5][4]),
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][4] =
|
that.tableDatas[6][4] =
|
||||||
data2.production_cost_unit;
|
data2.production_cost_unit;
|
||||||
that.tableDatas[6][7] = consume_precen(
|
that.tableDatas[6][7] = this.consume_precen(
|
||||||
(that.tableDatas[6][6] - that.tableDatas[6][4]),
|
(that.tableDatas[6][6] - that.tableDatas[6][4]),
|
||||||
that.tableDatas[6][6]
|
that.tableDatas[6][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1426,40 +1426,40 @@ export default {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] =
|
that.tableDatas[0][5] =
|
||||||
data1.total_production;
|
data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] =
|
that.tableDatas[1][5] =
|
||||||
data1.production_hour;
|
data1.production_hour;
|
||||||
that.tableDatas[1][9] = precen(
|
that.tableDatas[1][9] = this.precen(
|
||||||
that.tableDatas[1][5],
|
that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.run_hour;
|
that.tableDatas[2][5] = data1.run_hour;
|
||||||
that.tableDatas[2][9] = precen(
|
that.tableDatas[2][9] = this.precen(
|
||||||
that.tableDatas[2][5],
|
that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] = data1.run_rate;
|
that.tableDatas[3][5] = data1.run_rate;
|
||||||
that.tableDatas[3][9] = precen(
|
that.tableDatas[3][9] = this.precen(
|
||||||
that.tableDatas[3][5],
|
that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[4][5] =
|
that.tableDatas[4][5] =
|
||||||
data1.elec_consume_unit;
|
data1.elec_consume_unit;
|
||||||
that.tableDatas[4][9] = consume_precen(
|
that.tableDatas[4][9] = this.consume_precen(
|
||||||
(that.tableDatas[4][8] - that.tableDatas[4][5]),
|
(that.tableDatas[4][8] - that.tableDatas[4][5]),
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[5][5] = data1.elec_consume;
|
that.tableDatas[5][5] = data1.elec_consume;
|
||||||
that.tableDatas[5][9] = consume_precen(
|
that.tableDatas[5][9] = this.consume_precen(
|
||||||
(that.tableDatas[5][8] - that.tableDatas[5][5]),
|
(that.tableDatas[5][8] - that.tableDatas[5][5]),
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[6][5] =
|
that.tableDatas[6][5] =
|
||||||
data1.production_cost_unit;
|
data1.production_cost_unit;
|
||||||
that.tableDatas[6][9] = precen(
|
that.tableDatas[6][9] = this.precen(
|
||||||
(that.tableDatas[6][8] - that.tableDatas[6][5]),
|
(that.tableDatas[6][8] - that.tableDatas[6][5]),
|
||||||
that.tableDatas[6][8]
|
that.tableDatas[6][8]
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -875,22 +875,6 @@ export default {
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
function precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = (a / b)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
function consume_precen(a, b) {
|
|
||||||
if (b !== 0 && b !== null && a !== null) {
|
|
||||||
let precen = ((a / b)+1)* 100;
|
|
||||||
return precen.toFixed(2) + "%";
|
|
||||||
} else {
|
|
||||||
return "/";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
let that = this;
|
let that = this;
|
||||||
var myDate = new Date();
|
var myDate = new Date();
|
||||||
let year = (that.year = myDate.getFullYear());
|
let year = (that.year = myDate.getFullYear());
|
||||||
|
|
@ -1032,23 +1016,23 @@ export default {
|
||||||
if (res1.length > 0) {
|
if (res1.length > 0) {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] = data1.total_production;
|
that.tableDatas[0][5] = data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] = data1.elec_consume_unit;
|
that.tableDatas[1][5] = data1.elec_consume_unit;
|
||||||
that.tableDatas[1][9] = consume_precen(
|
that.tableDatas[1][9] = this.consume_precen(
|
||||||
that.tableDatas[1][8]-that.tableDatas[1][5],
|
that.tableDatas[1][8]-that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.elec_consume;
|
that.tableDatas[2][5] = data1.elec_consume;
|
||||||
that.tableDatas[2][9] = consume_precen(
|
that.tableDatas[2][9] = this.consume_precen(
|
||||||
that.tableDatas[2][8]-that.tableDatas[2][5],
|
that.tableDatas[2][8]-that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] =
|
that.tableDatas[3][5] =
|
||||||
data1.production_cost_unit;
|
data1.production_cost_unit;
|
||||||
that.tableDatas[3][9] = consume_precen(
|
that.tableDatas[3][9] = this.consume_precen(
|
||||||
that.tableDatas[3][8]-that.tableDatas[3][5],
|
that.tableDatas[3][8]-that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
|
|
@ -1056,13 +1040,13 @@ export default {
|
||||||
data1.imaterial_data.forEach((item) => {
|
data1.imaterial_data.forEach((item) => {
|
||||||
if (item.material_name == "湿电石渣消耗") {
|
if (item.material_name == "湿电石渣消耗") {
|
||||||
that.tableDatas[4][5] = (item.amount_consume).toFixed(2);
|
that.tableDatas[4][5] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[4][9] = precen(
|
that.tableDatas[4][9] = this.precen(
|
||||||
that.tableDatas[4][5],
|
that.tableDatas[4][5],
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
}else if(item.material_name == "湿电石渣进厂"){
|
}else if(item.material_name == "湿电石渣进厂"){
|
||||||
that.tableDatas[5][5] = (item.amount_consume).toFixed(2);
|
that.tableDatas[5][5] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[5][9] = precen(
|
that.tableDatas[5][9] = this.precen(
|
||||||
that.tableDatas[5][5],
|
that.tableDatas[5][5],
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
|
|
@ -1082,23 +1066,23 @@ export default {
|
||||||
if (res2.length > 0) {
|
if (res2.length > 0) {
|
||||||
let data2 = res2[0];
|
let data2 = res2[0];
|
||||||
that.tableDatas[0][4] = data2.total_production;
|
that.tableDatas[0][4] = data2.total_production;
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] = data2.elec_consume_unit;
|
that.tableDatas[1][4] = data2.elec_consume_unit;
|
||||||
that.tableDatas[1][7] = consume_precen(
|
that.tableDatas[1][7] = this.consume_precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.elec_consume;
|
that.tableDatas[2][4] = data2.elec_consume;
|
||||||
that.tableDatas[3][4] =
|
that.tableDatas[3][4] =
|
||||||
data2.production_cost_unit;
|
data2.production_cost_unit;
|
||||||
that.tableDatas[3][7] = consume_precen(
|
that.tableDatas[3][7] = this.consume_precen(
|
||||||
that.tableDatas[3][6]-that.tableDatas[3][4],
|
that.tableDatas[3][6]-that.tableDatas[3][4],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][7] = consume_precen(
|
that.tableDatas[2][7] = this.consume_precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1106,13 +1090,13 @@ export default {
|
||||||
data2.imaterial_data.forEach((item) => {
|
data2.imaterial_data.forEach((item) => {
|
||||||
if (item.material_name == "湿电石渣消耗") {
|
if (item.material_name == "湿电石渣消耗") {
|
||||||
that.tableDatas[4][4] = (item.amount_consume).toFixed(2);
|
that.tableDatas[4][4] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[4][7] = precen(
|
that.tableDatas[4][7] = this.precen(
|
||||||
that.tableDatas[4][4],
|
that.tableDatas[4][4],
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
}else if(item.material_name == "湿电石渣进厂"){
|
}else if(item.material_name == "湿电石渣进厂"){
|
||||||
that.tableDatas[5][4] = (item.amount_consume).toFixed(2);
|
that.tableDatas[5][4] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[5][7] = precen(
|
that.tableDatas[5][7] = this.precen(
|
||||||
that.tableDatas[5][4],
|
that.tableDatas[5][4],
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1128,6 +1112,22 @@ export default {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = (a / b)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
|
consume_precen(a, b) {
|
||||||
|
if (b !== 0 && b !== null && a !== null) {
|
||||||
|
let precen = ((a / b)+1)* 100;
|
||||||
|
return precen.toFixed(2) + "%";
|
||||||
|
} else {
|
||||||
|
return "/";
|
||||||
|
}
|
||||||
|
},
|
||||||
typeRadioChange() {
|
typeRadioChange() {
|
||||||
this.searchDate = "";
|
this.searchDate = "";
|
||||||
},
|
},
|
||||||
|
|
@ -1185,38 +1185,42 @@ export default {
|
||||||
this.$API.enm.enstat.req(params2).then((res2) => {
|
this.$API.enm.enstat.req(params2).then((res2) => {
|
||||||
if (res2.length > 0) {
|
if (res2.length > 0) {
|
||||||
let data2 = res2[0];
|
let data2 = res2[0];
|
||||||
|
console.log('---data2---',data2)
|
||||||
that.tableDatas[0][4] = data2.total_production;
|
that.tableDatas[0][4] = data2.total_production;
|
||||||
that.tableDatas[0][7] = precen(
|
that.tableDatas[0][7] = this.precen(
|
||||||
that.tableDatas[0][4],
|
that.tableDatas[0][4],
|
||||||
that.tableDatas[0][6]
|
that.tableDatas[0][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][4] = data2.elec_consume_unit;
|
that.tableDatas[1][4] = data2.elec_consume_unit;
|
||||||
that.tableDatas[1][7] = consume_precen(
|
that.tableDatas[1][7] = this.consume_precen(
|
||||||
that.tableDatas[1][4],
|
that.tableDatas[1][4],
|
||||||
that.tableDatas[1][6]
|
that.tableDatas[1][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][4] = data2.elec_consume;
|
that.tableDatas[2][4] = data2.elec_consume;
|
||||||
that.tableDatas[3][4] =
|
that.tableDatas[3][4] =
|
||||||
data2.production_cost_unit;
|
data2.production_cost_unit;
|
||||||
that.tableDatas[3][7] = consume_precen(
|
that.tableDatas[3][7] = this.consume_precen(
|
||||||
that.tableDatas[3][3],
|
that.tableDatas[3][3],
|
||||||
that.tableDatas[3][6]
|
that.tableDatas[3][6]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][7] = consume_precen(
|
that.tableDatas[2][7] = this.consume_precen(
|
||||||
that.tableDatas[2][4],
|
that.tableDatas[2][4],
|
||||||
that.tableDatas[2][6]
|
that.tableDatas[2][6]
|
||||||
);
|
);
|
||||||
|
console.log('---data2---',data2)
|
||||||
if (data2.imaterial_data.length > 0) {
|
if (data2.imaterial_data.length > 0) {
|
||||||
data2.imaterial_data.forEach((item) => {
|
data2.imaterial_data.forEach((item) => {
|
||||||
if (item.material_name == "湿电石渣消耗") {
|
if (item.material_name == "湿电石渣消耗") {
|
||||||
that.tableDatas[4][4] = (item.amount_consume).toFixed(2);
|
that.tableDatas[4][4] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[4][7] = precen(
|
console.log('---4,4-----',item.amount_consume)
|
||||||
|
that.tableDatas[4][7] = this.precen(
|
||||||
that.tableDatas[4][4],
|
that.tableDatas[4][4],
|
||||||
that.tableDatas[4][6]
|
that.tableDatas[4][6]
|
||||||
);
|
);
|
||||||
}else if(item.material_name == "湿电石渣进厂"){
|
}else if(item.material_name == "湿电石渣进厂"){
|
||||||
that.tableDatas[5][4] = (item.amount_consume).toFixed(2);
|
that.tableDatas[5][4] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[5][7] = precen(
|
console.log('---5,4-----',item.amount_consume)
|
||||||
|
that.tableDatas[5][7] = this.precen(
|
||||||
that.tableDatas[5][4],
|
that.tableDatas[5][4],
|
||||||
that.tableDatas[5][6]
|
that.tableDatas[5][6]
|
||||||
);
|
);
|
||||||
|
|
@ -1284,23 +1288,23 @@ export default {
|
||||||
if (res1.length > 0) {
|
if (res1.length > 0) {
|
||||||
let data1 = res1[0];
|
let data1 = res1[0];
|
||||||
that.tableDatas[0][5] = data1.total_production;
|
that.tableDatas[0][5] = data1.total_production;
|
||||||
that.tableDatas[0][9] = precen(
|
that.tableDatas[0][9] = this.precen(
|
||||||
that.tableDatas[0][5],
|
that.tableDatas[0][5],
|
||||||
that.tableDatas[0][8]
|
that.tableDatas[0][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[1][5] = data1.elec_consume_unit;
|
that.tableDatas[1][5] = data1.elec_consume_unit;
|
||||||
that.tableDatas[1][9] = consume_precen(
|
that.tableDatas[1][9] = this.consume_precen(
|
||||||
that.tableDatas[1][8]-that.tableDatas[1][5],
|
that.tableDatas[1][8]-that.tableDatas[1][5],
|
||||||
that.tableDatas[1][8]
|
that.tableDatas[1][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[2][5] = data1.elec_consume;
|
that.tableDatas[2][5] = data1.elec_consume;
|
||||||
that.tableDatas[2][9] = consume_precen(
|
that.tableDatas[2][9] = this.consume_precen(
|
||||||
that.tableDatas[2][8]-that.tableDatas[2][5],
|
that.tableDatas[2][8]-that.tableDatas[2][5],
|
||||||
that.tableDatas[2][8]
|
that.tableDatas[2][8]
|
||||||
);
|
);
|
||||||
that.tableDatas[3][5] =
|
that.tableDatas[3][5] =
|
||||||
data1.production_cost_unit;
|
data1.production_cost_unit;
|
||||||
that.tableDatas[3][9] = consume_precen(
|
that.tableDatas[3][9] = this.consume_precen(
|
||||||
that.tableDatas[3][8]-that.tableDatas[3][5],
|
that.tableDatas[3][8]-that.tableDatas[3][5],
|
||||||
that.tableDatas[3][8]
|
that.tableDatas[3][8]
|
||||||
);
|
);
|
||||||
|
|
@ -1308,13 +1312,13 @@ export default {
|
||||||
data1.imaterial_data.forEach((item) => {
|
data1.imaterial_data.forEach((item) => {
|
||||||
if (item.material_name == "湿电石渣消耗") {
|
if (item.material_name == "湿电石渣消耗") {
|
||||||
that.tableDatas[4][5] = (item.amount_consume).toFixed(2);
|
that.tableDatas[4][5] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[4][9] = precen(
|
that.tableDatas[4][9] = this.precen(
|
||||||
that.tableDatas[4][5],
|
that.tableDatas[4][5],
|
||||||
that.tableDatas[4][8]
|
that.tableDatas[4][8]
|
||||||
);
|
);
|
||||||
}else if(item.material_name == "湿电石渣进厂"){
|
}else if(item.material_name == "湿电石渣进厂"){
|
||||||
that.tableDatas[5][5] = (item.amount_consume).toFixed(2);
|
that.tableDatas[5][5] = (item.amount_consume).toFixed(2);
|
||||||
that.tableDatas[5][9] = precen(
|
that.tableDatas[5][9] = this.precen(
|
||||||
that.tableDatas[5][5],
|
that.tableDatas[5][5],
|
||||||
that.tableDatas[5][8]
|
that.tableDatas[5][8]
|
||||||
);
|
);
|
||||||
|
|
|
||||||
|
|
@ -113,21 +113,6 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="检验" prop="count_tested" v-if="cate=='mainso'">
|
<el-table-column label="检验" prop="count_tested" v-if="cate=='mainso'">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="组合件信息" v-if="cate == 'good'&&project_code=='gzerp'" width="300">
|
|
||||||
<template #default="scope">
|
|
||||||
<div v-if="scope.row.assemb.length > 0">
|
|
||||||
<div v-for="item in scope.row.assemb" :key="item.id">
|
|
||||||
<div>
|
|
||||||
{{ item.material_name }}
|
|
||||||
<span style="color: gray;font-size: 12px;">批:</span>
|
|
||||||
{{ item.batch }}
|
|
||||||
<span style="color: gray;font-size: 12px;">比:</span>
|
|
||||||
{{ item.rate }}
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="不合格数量" prop="count_notok">
|
<el-table-column label="不合格数量" prop="count_notok">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="创建时间" prop="create_time" show-overflow-tooltip>
|
<el-table-column label="创建时间" prop="create_time" show-overflow-tooltip>
|
||||||
|
|
@ -655,8 +640,10 @@ export default {
|
||||||
//尺寸检验
|
//尺寸检验
|
||||||
if(index == 6){
|
if(index == 6){
|
||||||
propert = 'count';
|
propert = 'count';
|
||||||
}else if(index == 7){
|
}else if(index == 7&&this.mioObj.type == 'sale_out'&&this.project_code=='gx'){
|
||||||
propert = 'count_send';
|
propert = 'count_send';
|
||||||
|
}else if((index == 7||index == 8)&&column.label=='不合格数量'){
|
||||||
|
propert = 'count_notok';
|
||||||
}
|
}
|
||||||
if (propert!=='') {
|
if (propert!=='') {
|
||||||
const values = data.map((item) =>
|
const values = data.map((item) =>
|
||||||
|
|
@ -674,7 +661,7 @@ export default {
|
||||||
}, 0);
|
}, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if(index==8){
|
if(index==8&&this.mioObj.type == 'sale_out'&&this.project_code=='gx'){
|
||||||
if(sums[6]){
|
if(sums[6]){
|
||||||
if(sums[7]){
|
if(sums[7]){
|
||||||
sums[index] = sums[6]-sums[7];
|
sums[index] = sums[6]-sums[7];
|
||||||
|
|
|
||||||
|
|
@ -321,15 +321,21 @@ export default {
|
||||||
that.initChartOptions();
|
that.initChartOptions();
|
||||||
},
|
},
|
||||||
initChartOptions() {
|
initChartOptions() {
|
||||||
this.$API.bi.dataset.exec.req("materialCount", {query: {
|
let that = this;
|
||||||
|
let query = {
|
||||||
"select_dept": "",
|
"select_dept": "",
|
||||||
"groupby_dept": "",
|
"groupby_dept": "",
|
||||||
"material_types": this.params.type,
|
"material_types": this.params.type,
|
||||||
"select_material": "material.cate as cate",
|
"select_material": "",
|
||||||
"groupby_material": "material.cate",
|
"groupby_material": ""
|
||||||
"select_material_name": "",
|
};
|
||||||
"groupby_material_name": ""
|
if(that.params.type==40){
|
||||||
}}).then((res) => {
|
query.select_material="material.cate as cate";
|
||||||
|
query.groupby_material="material.cate";
|
||||||
|
query.select_material_name = "";
|
||||||
|
query.groupby_material_name = "";
|
||||||
|
}
|
||||||
|
this.$API.bi.dataset.exec.req("materialCount", {query:query }).then((res) => {
|
||||||
if (res.echart_options) {
|
if (res.echart_options) {
|
||||||
this.echartsOptions = JSON.parse(res.echart_options);
|
this.echartsOptions = JSON.parse(res.echart_options);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -434,8 +434,14 @@ export default {
|
||||||
that.totalCount = totalCount;
|
that.totalCount = totalCount;
|
||||||
},
|
},
|
||||||
showbw(index){
|
showbw(index){
|
||||||
this.bwIndex = index;
|
let that = this;
|
||||||
this.bwVisible = true;
|
that.bwIndex = index;
|
||||||
|
if(that.form.handoverb[index].handoverbw&&that.form.handoverb[index].handoverbw.length>0){
|
||||||
|
that.bwVisible = true;
|
||||||
|
}else{
|
||||||
|
that.$message.warning("正在加载,请稍后...");
|
||||||
|
that.bwVisible = true;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
bwVisibleClose(){
|
bwVisibleClose(){
|
||||||
this.bwVisible = false;
|
this.bwVisible = false;
|
||||||
|
|
@ -600,13 +606,21 @@ export default {
|
||||||
},
|
},
|
||||||
//显示
|
//显示
|
||||||
open(mode = "add",data,mtype) {
|
open(mode = "add",data,mtype) {
|
||||||
this.mode = mode;
|
let that = this;
|
||||||
this.mtype = mtype;
|
that.mode = mode;
|
||||||
|
that.mtype = mtype;
|
||||||
if(mtype==30){
|
if(mtype==30){
|
||||||
this.change_batch = true;
|
that.change_batch = true;
|
||||||
}
|
}
|
||||||
this.form.handoverb = data?data:[];
|
that.form.handoverb = data?data:[];
|
||||||
this.visible = true;
|
if(data&&data!==''&&data.length>0){
|
||||||
|
that.totalCount = 0;
|
||||||
|
data.forEach((item,index)=>{
|
||||||
|
that.totalCount += Number(item.count);
|
||||||
|
that.getWprList(item.wm,index);
|
||||||
|
})
|
||||||
|
}
|
||||||
|
that.visible = true;
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
clearSelect(){
|
clearSelect(){
|
||||||
|
|
@ -657,7 +671,7 @@ export default {
|
||||||
getWprList(id,index){
|
getWprList(id,index){
|
||||||
let that = this;
|
let that = this;
|
||||||
let handoverbw = [];
|
let handoverbw = [];
|
||||||
that.$API.wpm.wpr.list.req({wm:id,page:0,can_use:'yes'}).then((res) => {
|
that.$API.wpm.wpr.list.req({wm:id,page:0,can_use:'yes',query:'{id,number}'}).then((res) => {
|
||||||
res.forEach(wpritem=>{
|
res.forEach(wpritem=>{
|
||||||
let obj = {};
|
let obj = {};
|
||||||
obj.wpr = wpritem.id;
|
obj.wpr = wpritem.id;
|
||||||
|
|
|
||||||
|
|
@ -698,7 +698,7 @@ export default {
|
||||||
},
|
},
|
||||||
handleAddWpr(row){
|
handleAddWpr(row){
|
||||||
this.dialog.scrap = true;
|
this.dialog.scrap = true;
|
||||||
this.type = 10;
|
this.type = 50;
|
||||||
let obj = {};
|
let obj = {};
|
||||||
obj.wm = row.id;
|
obj.wm = row.id;
|
||||||
obj.batch = row.batch;
|
obj.batch = row.batch;
|
||||||
|
|
@ -708,7 +708,7 @@ export default {
|
||||||
obj.material_name = row.material_name;
|
obj.material_name = row.material_name;
|
||||||
this.wmItem = obj;
|
this.wmItem = obj;
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.$refs.scrapDialog.open("add",[],30);
|
this.$refs.scrapDialog.open("add");
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
handleWprSuccess(row){},
|
handleWprSuccess(row){},
|
||||||
|
|
|
||||||
|
|
@ -58,87 +58,20 @@
|
||||||
header="子工序操作记录"
|
header="子工序操作记录"
|
||||||
shadow="never"
|
shadow="never"
|
||||||
>
|
>
|
||||||
<el-button
|
<sc-form-table
|
||||||
type="primary"
|
hideDelete
|
||||||
icon="el-icon-plus"
|
:tableHeight="tableHeight"
|
||||||
@click="table_muser_add"
|
v-model="processLists"
|
||||||
style="position: absolute; left: 150px; top: 5px"
|
:addTemplate="addTemplate"
|
||||||
>新增</el-button>
|
placeholder="暂无数据"
|
||||||
<scTable
|
@add="rowAdd"
|
||||||
ref="tableMuser"
|
|
||||||
:apiObj="apiObjMuser"
|
|
||||||
row-key="id"
|
|
||||||
stripe
|
|
||||||
height="250px"
|
|
||||||
:params="paramsMuser"
|
|
||||||
hidePagination
|
|
||||||
>
|
|
||||||
<el-table-column type="index" width="50" />
|
|
||||||
<el-table-column label="工序" prop="process_name">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作人" prop="handle_user_name">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作日期" prop="handle_date">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="班次" prop="shift_name">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="创建时间"
|
|
||||||
prop="create_time"
|
|
||||||
show-overflow-tooltip
|
|
||||||
>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="操作"
|
|
||||||
fixed="right"
|
|
||||||
align="center"
|
|
||||||
width="100px"
|
|
||||||
>
|
>
|
||||||
|
<el-table-column label="工序">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
|
||||||
type="danger"
|
|
||||||
@click="table_muser_del(scope.row)"
|
|
||||||
>删除</el-button>
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
</scTable>
|
|
||||||
</el-card>
|
|
||||||
<!-- 日志操作记录编辑 -->
|
|
||||||
<el-dialog v-model="saveMuserDialog" title="子工序操作记录">
|
|
||||||
<el-form
|
|
||||||
:model="muserForm"
|
|
||||||
:rules="rules"
|
|
||||||
label-width="100px"
|
|
||||||
ref="saveInForm"
|
|
||||||
>
|
|
||||||
<el-row>
|
|
||||||
<el-col :span="23">
|
|
||||||
<el-form-item label="操作时间" prop="work_start_time">
|
|
||||||
<el-date-picker
|
|
||||||
v-model="muserForm.work_start_time"
|
|
||||||
type="datetime"
|
|
||||||
placeholder="操作时间"
|
|
||||||
value-format="YYYY-MM-DD HH:mm:ss"
|
|
||||||
style="width: 100%"
|
|
||||||
></el-date-picker>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="23">
|
|
||||||
<el-form-item label="操作人" prop="handle_user">
|
|
||||||
<ehsSelect
|
|
||||||
v-model="muserForm.handle_user"
|
|
||||||
:showName="muserForm.handle_user_name"
|
|
||||||
:apiObj="this.$API.system.user.list"
|
|
||||||
:params="{ depts: dept }"
|
|
||||||
class="width-100"
|
|
||||||
></ehsSelect>
|
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="23">
|
|
||||||
<el-form-item label="子工序" prop="process">
|
|
||||||
<el-select
|
<el-select
|
||||||
v-model="muserForm.process"
|
v-if="scope.row.isEdit"
|
||||||
placeholder="请选择"
|
v-model="scope.row.process"
|
||||||
|
placeholder="请选择子工序"
|
||||||
class="width-100"
|
class="width-100"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option
|
||||||
|
|
@ -148,29 +81,45 @@
|
||||||
:value="item.id"
|
:value="item.id"
|
||||||
></el-option>
|
></el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
<div v-else>
|
||||||
</el-col>
|
<span v-if="scope.row.process!==null">{{ scope.row.process_name}}</span>
|
||||||
<!-- <el-col :span="23">
|
</div>
|
||||||
<el-form-item label="关联班次" prop="shift">
|
</template>
|
||||||
<el-select
|
</el-table-column>
|
||||||
v-model="muserForm.shift"
|
<el-table-column label="操作人">
|
||||||
placeholder="班次"
|
<template #default="scope">
|
||||||
|
<ehsSelect
|
||||||
|
v-if="scope.row.isEdit"
|
||||||
|
v-model="scope.row.handle_user"
|
||||||
|
:showName="scope.row.handle_user_name"
|
||||||
|
:apiObj="this.$API.system.user.list"
|
||||||
|
:params="{ depts: dept }"
|
||||||
class="width-100"
|
class="width-100"
|
||||||
>
|
></ehsSelect>
|
||||||
<el-option
|
<div v-else>
|
||||||
v-for="item in shiftOtions"
|
<span v-if="scope.row.handle_user_name!==null">{{ scope.row.handle_user_name}}</span>
|
||||||
:key="item.id"
|
</div>
|
||||||
:label="item.name"
|
</template>
|
||||||
:value="item.id"
|
</el-table-column>
|
||||||
>
|
<el-table-column label="操作时间">
|
||||||
</el-option>
|
<template #default="scope">
|
||||||
</el-select>
|
<el-date-picker
|
||||||
</el-form-item>
|
v-if="scope.row.isEdit"
|
||||||
</el-col> -->
|
v-model="scope.row.work_start_time"
|
||||||
<el-col :span="23" v-if="route_code=='pengma'">
|
type="datetime"
|
||||||
<el-form-item label="使用设备" prop="equipment">
|
value-format="YYYY-MM-DD HH:mm"
|
||||||
|
formatter="YYYY-MM-DD HH:mm"
|
||||||
|
style="width: 100%;"
|
||||||
|
/>
|
||||||
|
<div v-else>
|
||||||
|
<span v-if="scope.row.work_start_time!==null">{{ scope.row.work_start_time}}</span>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-form-item v-if="route_code=='pengma'" label="使用设备" prop="equipment">
|
||||||
|
<template #default="scope">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="muserForm.equipment"
|
v-model="scope.row.equipment"
|
||||||
placeholder="设备"
|
placeholder="设备"
|
||||||
class="width-100"
|
class="width-100"
|
||||||
>
|
>
|
||||||
|
|
@ -182,18 +131,18 @@
|
||||||
>
|
>
|
||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
|
||||||
</el-col>
|
|
||||||
</el-row>
|
|
||||||
</el-form>
|
|
||||||
<template #footer>
|
|
||||||
<el-button
|
|
||||||
type="primary"
|
|
||||||
:loading="isSaveing"
|
|
||||||
@click="saveMuserSubmit()"
|
|
||||||
>保 存</el-button>
|
|
||||||
</template>
|
</template>
|
||||||
</el-dialog>
|
</el-form-item>
|
||||||
|
<el-table-column label="班次"></el-table-column>
|
||||||
|
<el-table-column label="创建时间"></el-table-column>
|
||||||
|
<el-table-column label="操作" fixed="right" align="center" width="150px">
|
||||||
|
<template #default="scope">
|
||||||
|
<el-button v-if="scope.row.isEdit" type="success" @click="saveMuserSubmit(scope.row)">保存</el-button>
|
||||||
|
<el-button v-else type="danger" @click="table_muser_del(scope.row)">删除</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</sc-form-table>
|
||||||
|
</el-card>
|
||||||
<!-- 输入物料 -->
|
<!-- 输入物料 -->
|
||||||
<el-card
|
<el-card
|
||||||
style="width: 100%; margin: 1vh 0;position: relative"
|
style="width: 100%; margin: 1vh 0;position: relative"
|
||||||
|
|
@ -486,7 +435,6 @@ export default {
|
||||||
loading: false,
|
loading: false,
|
||||||
//表单数据
|
//表单数据
|
||||||
form: {},
|
form: {},
|
||||||
muserForm:{},
|
|
||||||
dialog: {
|
dialog: {
|
||||||
save: false,
|
save: false,
|
||||||
edit: false,
|
edit: false,
|
||||||
|
|
@ -530,6 +478,7 @@ export default {
|
||||||
equipmentOtions:[],
|
equipmentOtions:[],
|
||||||
defectOptions:[],
|
defectOptions:[],
|
||||||
qct_testitems:[],
|
qct_testitems:[],
|
||||||
|
processLists:[],
|
||||||
processOptions:[],
|
processOptions:[],
|
||||||
test_file:'',
|
test_file:'',
|
||||||
deptId: "",
|
deptId: "",
|
||||||
|
|
@ -541,7 +490,6 @@ export default {
|
||||||
printVisible:false,
|
printVisible:false,
|
||||||
saveInDialog: false,
|
saveInDialog: false,
|
||||||
checkTableShow:false,
|
checkTableShow:false,
|
||||||
saveMuserDialog:false,
|
|
||||||
setFiltersVisible: false,
|
setFiltersVisible: false,
|
||||||
rules: {
|
rules: {
|
||||||
count_use: [{required: true,message: "请输入领取数量",trigger: "blur"}],
|
count_use: [{required: true,message: "请输入领取数量",trigger: "blur"}],
|
||||||
|
|
@ -564,9 +512,11 @@ export default {
|
||||||
apiObjPrint:this.$API.cm.labelmat.fromWm,
|
apiObjPrint:this.$API.cm.labelmat.fromWm,
|
||||||
printer_name:localStorage.getItem("printer_name"),
|
printer_name:localStorage.getItem("printer_name"),
|
||||||
addTemplate:{
|
addTemplate:{
|
||||||
defect: "",
|
mlog: "",
|
||||||
count: 1,
|
process: "",
|
||||||
mlogb: "",
|
handle_user: "",
|
||||||
|
handle_user_name: "",
|
||||||
|
work_start_time: "",
|
||||||
isEdit: true,
|
isEdit: true,
|
||||||
},
|
},
|
||||||
qct:null,
|
qct:null,
|
||||||
|
|
@ -588,6 +538,11 @@ export default {
|
||||||
this.paramsIn.mlog = this.mlogId;
|
this.paramsIn.mlog = this.mlogId;
|
||||||
this.paramsOut.mlog = this.mlogId;
|
this.paramsOut.mlog = this.mlogId;
|
||||||
this.apiObj = this.$API.wpm.mlogb.list;
|
this.apiObj = this.$API.wpm.mlogb.list;
|
||||||
|
let userInfo = that.$TOOL.data.get("USER_INFO");
|
||||||
|
that.addTemplate.mlog = that.mlogItem.id;
|
||||||
|
that.addTemplate.handle_user = userInfo.id;
|
||||||
|
that.addTemplate.handle_user_name = userInfo.name;
|
||||||
|
that.addTemplate.work_start_time = this.$TOOL.dateFormat(new Date());
|
||||||
that.$API.wpm.mlogb.list.req(that.paramsIn).then((res) => {
|
that.$API.wpm.mlogb.list.req(that.paramsIn).then((res) => {
|
||||||
that.tableData = res;
|
that.tableData = res;
|
||||||
})
|
})
|
||||||
|
|
@ -595,6 +550,7 @@ export default {
|
||||||
that.getPreocess();
|
that.getPreocess();
|
||||||
that.getShift();
|
that.getShift();
|
||||||
that.getEquipment();
|
that.getEquipment();
|
||||||
|
that.getProcessList();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
open() {
|
open() {
|
||||||
|
|
@ -664,6 +620,12 @@ export default {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
getProcessList(){
|
||||||
|
let that = this;
|
||||||
|
that.$API.wpm.mloguser.list.req({page:0,mlog:that.mlogId}).then((res) => {
|
||||||
|
that.processLists = res;
|
||||||
|
})
|
||||||
|
},
|
||||||
getShift(){
|
getShift(){
|
||||||
let that = this;
|
let that = this;
|
||||||
that.$API.mtm.shift.list.req({ page: 0 }).then((res) => {
|
that.$API.mtm.shift.list.req({ page: 0 }).then((res) => {
|
||||||
|
|
@ -917,23 +879,13 @@ export default {
|
||||||
that.isSaveing = false;
|
that.isSaveing = false;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
table_muser_add(){
|
saveMuserSubmit(row){
|
||||||
let that = this;
|
|
||||||
let userInfo = that.$TOOL.data.get("USER_INFO");
|
|
||||||
that.muserForm.mlog = that.mlogItem.id;
|
|
||||||
that.muserForm.handle_user = userInfo.id;
|
|
||||||
that.muserForm.handle_user_name = userInfo.name;
|
|
||||||
that.muserForm.work_start_time = this.$TOOL.dateFormat(new Date());
|
|
||||||
that.saveMuserDialog = true;
|
|
||||||
},
|
|
||||||
saveMuserSubmit (){
|
|
||||||
let that = this;
|
let that = this;
|
||||||
that.isSaveing = true;
|
that.isSaveing = true;
|
||||||
that.$API.wpm.mloguser.create.req(that.muserForm).then((res) => {
|
that.$API.wpm.mloguser.create.req(that.addTemplate).then((res) => {
|
||||||
that.isSaveing = false;
|
that.isSaveing = false;
|
||||||
that.saveMuserDialog = false;
|
|
||||||
that.$message.success("操作成功");
|
that.$message.success("操作成功");
|
||||||
that.$refs.tableMuser.refresh();
|
that.getProcessList();
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
that.isSaveing = false;
|
that.isSaveing = false;
|
||||||
})
|
})
|
||||||
|
|
@ -947,6 +899,14 @@ export default {
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
table_muser_edit(row){
|
||||||
|
let that = this;
|
||||||
|
console.log('row',row);
|
||||||
|
let index = that.processLists.indexOf(row);
|
||||||
|
console.log('index',index);
|
||||||
|
that.processLists[index].isEdit = true;
|
||||||
|
|
||||||
|
},
|
||||||
handleSaveSuccess() {
|
handleSaveSuccess() {
|
||||||
this.$refs.tableIn.refresh();
|
this.$refs.tableIn.refresh();
|
||||||
if(this.mlogItem.material_out_&&this.mlogItem.material_out_.tracking==10){
|
if(this.mlogItem.material_out_&&this.mlogItem.material_out_.tracking==10){
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,10 @@
|
||||||
<table id="mlogbwlist" class="tables">
|
<table id="mlogbwlist" class="tables">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th class="w_30 inlineBlock"></th>
|
<th class="w_30 inlineBlock">
|
||||||
|
<input type="checkbox" v-model="selectedAll" :value="selectedAll" style="width: 18px;" @change="selectAllChange">
|
||||||
|
</th>
|
||||||
|
<th class="w_30 inlineBlock">序号</th>
|
||||||
<th class="w_140 inlineBlock">物料批次</th>
|
<th class="w_140 inlineBlock">物料批次</th>
|
||||||
<th class="w_140 inlineBlock">物料编号</th>
|
<th class="w_140 inlineBlock">物料编号</th>
|
||||||
<th class="w_80 inlineBlock" v-for="item in qct_testitems" :key="item.id">{{ item.testitem_name }}</th>
|
<th class="w_80 inlineBlock" v-for="item in qct_testitems" :key="item.id">{{ item.testitem_name }}</th>
|
||||||
|
|
@ -38,6 +41,9 @@
|
||||||
<td class="w_30 inlineBlock padding_4">
|
<td class="w_30 inlineBlock padding_4">
|
||||||
<input type="checkbox" v-model="selectedindexes" :value="row.id" @change="selectChange">
|
<input type="checkbox" v-model="selectedindexes" :value="row.id" @change="selectChange">
|
||||||
</td>
|
</td>
|
||||||
|
<td class="w_30 inlineBlock padding_4">
|
||||||
|
{{ index + 1 }}
|
||||||
|
</td>
|
||||||
<td class="w_140 inlineBlock">
|
<td class="w_140 inlineBlock">
|
||||||
<input v-if="row.isEdit" v-model="row.mlogb__batch" placeholder="物料批次">
|
<input v-if="row.isEdit" v-model="row.mlogb__batch" placeholder="物料批次">
|
||||||
<span v-else>{{ row.mlogb__batch }}</span>
|
<span v-else>{{ row.mlogb__batch }}</span>
|
||||||
|
|
@ -66,7 +72,7 @@
|
||||||
<span v-else style="width: 100%;height: 100%;display: inline-block;">{{ row.note }}</span>
|
<span v-else style="width: 100%;height: 100%;display: inline-block;">{{ row.note }}</span>
|
||||||
</td>
|
</td>
|
||||||
<td class="w_180 inlineBlock" v-if="!isSubmit">
|
<td class="w_180 inlineBlock" v-if="!isSubmit">
|
||||||
<button v-if="row.isEdit" type="button" class="btn btn_blue" @click="formTableSave(row,index)">保存</button>
|
<button v-if="row.isEdit" type="button" class="btn btn_green" @click="formTableSave(row,index)">保存</button>
|
||||||
<button v-if="row.isEdit && row.id" type="button" class="btn btn_red" @click="formTableCancel(row,index)">取消</button>
|
<button v-if="row.isEdit && row.id" type="button" class="btn btn_red" @click="formTableCancel(row,index)">取消</button>
|
||||||
<button v-if="row.isEdit && setForm.cd_req_addr !== null" type="button" class="btn btn_yellow" @click="getEqData(index)">重取数据</button>
|
<button v-if="row.isEdit && setForm.cd_req_addr !== null" type="button" class="btn btn_yellow" @click="getEqData(index)">重取数据</button>
|
||||||
<button v-if="!row.isEdit" type="button" class="btn btn_blue" @click="formTableEdit(index)">编辑</button>
|
<button v-if="!row.isEdit" type="button" class="btn btn_blue" @click="formTableEdit(index)">编辑</button>
|
||||||
|
|
@ -198,7 +204,7 @@
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-col v-for="item2 in defectlists" :key="item2.id" :span="12">
|
<el-col v-for="item2 in defectlists" :key="item2.id" :span="12">
|
||||||
<el-form-item :label="item2.defect_name">
|
<el-form-item :label="item2.defect_name">
|
||||||
<el-switch v-model="item2.value"></el-switch>
|
<el-switch v-model="item2.value" @change="defect_change(item2)"></el-switch>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col>
|
<el-col>
|
||||||
|
|
@ -210,11 +216,13 @@
|
||||||
</el-row>
|
</el-row>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-row>
|
<el-row>
|
||||||
<el-table :data="selectWpr" border>
|
<el-table :data="selectWprList" border>
|
||||||
<el-table-column type="index"></el-table-column>
|
<el-table-column type="index"></el-table-column>
|
||||||
<el-table-column prop="number" label="物料编号"></el-table-column>
|
<el-table-column prop="number" label="物料编号"></el-table-column>
|
||||||
<el-table-column v-for="item2 in defectlists" :key="item2.id" :label="item2.defect_name">
|
<el-table-column v-for="item2 in defectlists" :key="item2.id" :label="item2.defect_name">
|
||||||
<el-switch v-model="item2.value" disabled></el-switch>
|
<template #default="scope">
|
||||||
|
<el-switch v-model="scope.row[item2.defect_name]" disabled></el-switch>
|
||||||
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="操作" width="90" align="center" fixed="right">
|
<el-table-column label="操作" width="90" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
|
|
@ -225,7 +233,7 @@
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-footer>
|
<el-footer>
|
||||||
<el-button type="primary" :loading="isSaveing" @click.stop="saveSetting" save>保存</el-button>
|
<el-button type="primary" :loading="isSaveing" @click.stop="saveSetting" save>保存</el-button>
|
||||||
<el-button @click="saveCancel">取消</el-button>
|
<el-button @click="saveSettingCancel">取消</el-button>
|
||||||
</el-footer>
|
</el-footer>
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
|
|
@ -318,6 +326,7 @@ export default {
|
||||||
route_code:"",
|
route_code:"",
|
||||||
wprInputText:"",
|
wprInputText:"",
|
||||||
canMultiple:false,
|
canMultiple:false,
|
||||||
|
selectedAll:false,
|
||||||
checkAll: false,
|
checkAll: false,
|
||||||
hideAdd: false,
|
hideAdd: false,
|
||||||
visible: false,
|
visible: false,
|
||||||
|
|
@ -359,7 +368,6 @@ export default {
|
||||||
selectWprList:[],
|
selectWprList:[],
|
||||||
selectedindexes:[],
|
selectedindexes:[],
|
||||||
qct_defects_origin:[],
|
qct_defects_origin:[],
|
||||||
selectWpr:[],
|
|
||||||
tableHeight:500,
|
tableHeight:500,
|
||||||
apiObjPrint:this.$API.cm.labelmat.fromWm,
|
apiObjPrint:this.$API.cm.labelmat.fromWm,
|
||||||
printer_name:localStorage.getItem("printer_name")
|
printer_name:localStorage.getItem("printer_name")
|
||||||
|
|
@ -402,17 +410,23 @@ export default {
|
||||||
selectChange(){
|
selectChange(){
|
||||||
let that = this;
|
let that = this;
|
||||||
that.selectWprList = [];
|
that.selectWprList = [];
|
||||||
console.log('selectedindexes',that.selectedindexes);
|
|
||||||
that.mlogbwlist.forEach((item) => {
|
that.mlogbwlist.forEach((item) => {
|
||||||
if(that.selectedindexes.indexOf(item.id)>-1){
|
if(that.selectedindexes.indexOf(item.id)>-1){
|
||||||
that.selectWprList.push(item);
|
that.selectWprList.push(item);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
console.log('selectWprList',that.selectWprList);
|
|
||||||
},
|
},
|
||||||
selectAllChange(datas){
|
selectAllChange(){
|
||||||
let that = this;
|
let that = this;
|
||||||
that.selectWprList = datas;
|
if(that.selectedAll){
|
||||||
|
that.mlogbwlist.forEach((item) => {
|
||||||
|
that.selectedindexes.push(item.id);
|
||||||
|
that.selectWprList.push(item);
|
||||||
|
})
|
||||||
|
}else{
|
||||||
|
that.selectedindexes=[];
|
||||||
|
that.selectWprList=[];
|
||||||
|
}
|
||||||
},
|
},
|
||||||
getEquipment4() {
|
getEquipment4() {
|
||||||
let that = this;
|
let that = this;
|
||||||
|
|
@ -475,15 +489,6 @@ export default {
|
||||||
that.options = res;
|
that.options = res;
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
optionChange(row){
|
|
||||||
let that = this;
|
|
||||||
that.options.forEach((item) => {
|
|
||||||
if(item.id == row.wpr){
|
|
||||||
let index = that.mlogbwlist.indexOf(row);
|
|
||||||
that.mlogbwlist[index].number = item.number;
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
getList(){
|
getList(){
|
||||||
let that = this;
|
let that = this;
|
||||||
let params = {};
|
let params = {};
|
||||||
|
|
@ -527,7 +532,6 @@ export default {
|
||||||
}
|
}
|
||||||
that.mlogbwlist.push(obj);
|
that.mlogbwlist.push(obj);
|
||||||
})
|
})
|
||||||
// console.log('that.mlogbwlist',that.mlogbwlist);
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
@ -624,7 +628,7 @@ export default {
|
||||||
let getEd = false;
|
let getEd = false;
|
||||||
if(that.qct_testitems.length>0){
|
if(that.qct_testitems.length>0){
|
||||||
for(let i=0;i<that.qct_testitems.length;i++){
|
for(let i=0;i<that.qct_testitems.length;i++){
|
||||||
if(that.qct_testitems[i].cd_expr!=null){
|
if(that.qct_testitems[i].testitem_cd_expr!=null&&that.qct_testitems[i].testitem_cd_expr!=''&&that.qct_testitems[i].testitem_cd_expr!==undefined){
|
||||||
getEd = true;
|
getEd = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -754,7 +758,7 @@ export default {
|
||||||
that.qct_defects.forEach(item => {
|
that.qct_defects.forEach(item => {
|
||||||
if(that.form.defectids.indexOf(item.defect) > -1){
|
if(that.form.defectids.indexOf(item.defect) > -1){
|
||||||
item.canEdit = true;
|
item.canEdit = true;
|
||||||
item.value=null;
|
item.value=false;
|
||||||
that.defectlists.push(item);
|
that.defectlists.push(item);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
@ -771,7 +775,7 @@ export default {
|
||||||
if(that.checkAll){
|
if(that.checkAll){
|
||||||
that.qct_defects.forEach(item => {
|
that.qct_defects.forEach(item => {
|
||||||
item.canEdit = true;
|
item.canEdit = true;
|
||||||
item.value=null;
|
item.value=false;
|
||||||
that.defectlists.push(item);
|
that.defectlists.push(item);
|
||||||
that.form.defectids.push(item.defect);
|
that.form.defectids.push(item.defect);
|
||||||
})
|
})
|
||||||
|
|
@ -811,7 +815,6 @@ export default {
|
||||||
that.qct_testitems = [];
|
that.qct_testitems = [];
|
||||||
that.qct_testitems = that.testitemlists;
|
that.qct_testitems = that.testitemlists;
|
||||||
that.tableHeight = document.getElementById('mlogbwMain').clientHeight-80;
|
that.tableHeight = document.getElementById('mlogbwMain').clientHeight-80;
|
||||||
// that.getList();
|
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
that.isSaveing = false;
|
that.isSaveing = false;
|
||||||
})
|
})
|
||||||
|
|
@ -826,14 +829,11 @@ export default {
|
||||||
this.form.defectids = [];
|
this.form.defectids = [];
|
||||||
this.checkVisible = false;
|
this.checkVisible = false;
|
||||||
},
|
},
|
||||||
|
//批量操作
|
||||||
check_set(){
|
check_set(){
|
||||||
this.wprNumber = "";
|
let that = this;
|
||||||
this.selectWpr = [];
|
that.wprNumber = "";
|
||||||
if(this.selectWprList.length>0){
|
that.setVisible=true;
|
||||||
this.selectWpr = this.selectWprList;
|
|
||||||
}
|
|
||||||
console.log('this.selectWpr',this.selectWpr);
|
|
||||||
this.setVisible=true;
|
|
||||||
},
|
},
|
||||||
//扫描物料将这一行放到第一行并编辑这一行
|
//扫描物料将这一行放到第一行并编辑这一行
|
||||||
wprinputChange(){
|
wprinputChange(){
|
||||||
|
|
@ -847,12 +847,13 @@ export default {
|
||||||
that.wprInputText = "";
|
that.wprInputText = "";
|
||||||
that.mlogbwlist.unshift(obj);
|
that.mlogbwlist.unshift(obj);
|
||||||
that.$nextTick(() => {
|
that.$nextTick(() => {
|
||||||
that.$refs.mlogbwTable.setCurrentRows(obj); // 选中第一行
|
that.selectedindexes.push(obj.id);
|
||||||
|
that.selectWprList.push(item);
|
||||||
})
|
})
|
||||||
let getEd = false;
|
let getEd = false;
|
||||||
if(that.qct_testitems.length>0){
|
if(that.qct_testitems.length>0){
|
||||||
for(let i=0;i<that.qct_testitems.length;i++){
|
for(let i=0;i<that.qct_testitems.length;i++){
|
||||||
if(that.qct_testitems[i].cd_expr!=null){
|
if(that.qct_testitems[i].testitem_cd_expr!=null&&that.qct_testitems[i].testitem_cd_expr!=''&&that.qct_testitems[i].testitem_cd_expr!==undefined){
|
||||||
getEd = true;
|
getEd = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -889,7 +890,6 @@ export default {
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
console.log(err);
|
|
||||||
this.$notify.error({
|
this.$notify.error({
|
||||||
title: '获取数据失败',
|
title: '获取数据失败',
|
||||||
message: err.data
|
message: err.data
|
||||||
|
|
@ -901,45 +901,48 @@ export default {
|
||||||
let that = this;
|
let that = this;
|
||||||
that.mlogbwlist.forEach(item => {
|
that.mlogbwlist.forEach(item => {
|
||||||
if(item.number == wprNumber){
|
if(item.number == wprNumber){
|
||||||
that.selectWpr.push(item);
|
that.selectWprList.push(item);
|
||||||
that.wprNumber = "";
|
that.wprNumber = "";
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
selectWprDel(row){
|
selectWprDel(row){
|
||||||
let that = this;
|
let that = this;
|
||||||
that.selectWpr.forEach((item,index) => {
|
that.selectWprList.forEach((item,index) => {
|
||||||
if(item.number == row.number){
|
if(item.number == row.number){
|
||||||
that.selectWpr.splice(index,1);
|
that.selectWprList.splice(index,1);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
defect_change(item){
|
||||||
|
let that = this;
|
||||||
|
that.selectWprList.forEach(row => {
|
||||||
|
row[item.defect_name] = item.value;
|
||||||
|
});
|
||||||
|
},
|
||||||
saveSetting(){
|
saveSetting(){
|
||||||
let that = this;
|
let that = this;
|
||||||
that.$refs.dialogForm.validate((valid) => {
|
that.$refs.dialogForm.validate((valid) => {
|
||||||
if (valid) {
|
if (valid) {
|
||||||
that.selectWpr.forEach(item => {
|
that.selectWprList.forEach(item => {
|
||||||
|
if(!item.ftest){
|
||||||
|
item.ftest = {};
|
||||||
|
}
|
||||||
item.ftest.ftestdefects = [];
|
item.ftest.ftestdefects = [];
|
||||||
if(that.defectlists.length>0){
|
if(that.defectlists.length>0){
|
||||||
that.defectlists.forEach((item1) => {
|
that.defectlists.forEach((item1) => {
|
||||||
let obj = {};
|
let obj = {};
|
||||||
obj.defect = item1.defect;
|
obj.defect = item1.defect;
|
||||||
obj.has = item1.value;
|
obj.has = item[item1.defect_name]?item[item1.defect_name]:false;
|
||||||
item.ftest.ftestdefects.push(obj);
|
item.ftest.ftestdefects.push(obj);
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// item.ftest.ftestdefects.forEach(defect => {
|
|
||||||
// let defectindex = that.setForm.defectids.indexOf(defect.defect);
|
|
||||||
// if(defectindex > -1){
|
|
||||||
// defect.has = that.defectlists[defectindex].value;
|
|
||||||
// }
|
|
||||||
// })
|
|
||||||
});
|
});
|
||||||
that.$API.wpm.mlogbw.update.req("bulk",that.selectWpr).then((res) => {
|
that.$API.wpm.mlogbw.update.req("bulk",that.selectWprList).then((res) => {
|
||||||
that.setVisible = false;
|
that.setVisible = false;
|
||||||
|
that.selectedAll = false;
|
||||||
that.selectWprList = [];
|
that.selectWprList = [];
|
||||||
that.$refs.mlogbwTable.clearSelection();
|
that.selectedindexes = [];
|
||||||
that.defectlists.forEach(item => {
|
that.defectlists.forEach(item => {
|
||||||
item.value = false;
|
item.value = false;
|
||||||
});
|
});
|
||||||
|
|
@ -950,6 +953,16 @@ export default {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
saveSettingCancel(){
|
||||||
|
let that = this;
|
||||||
|
that.setVisible = false;
|
||||||
|
that.selectedAll = false;
|
||||||
|
that.selectWprList = [];
|
||||||
|
that.selectedindexes = [];
|
||||||
|
// that.defectlists.forEach(item => {
|
||||||
|
// item.value = false;
|
||||||
|
// });
|
||||||
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue