fix:主要设备单位电耗和生产报告筛选条件修正

This commit is contained in:
shijing 2024-07-25 16:09:27 +08:00
parent e67532d958
commit 8d6b620123
7 changed files with 66 additions and 68 deletions

View File

@ -628,9 +628,9 @@ export default {
} }
}); });
}); });
that.getHourData(); that.getHourData(year, month, days);
that.getDayData(); that.getDayData(year, month);
that.getMonthData(); that.getMonthData(year);
}); });
}, },
methods: { methods: {
@ -653,13 +653,13 @@ export default {
} }
}, },
// //
getHourData() { getHourData(year, month, days) {
let that = this; let that = this;
let query = {}; let query = {};
query.page = 0; query.page = 0;
query.year_s = that.year; query.year_s = year;
query.month_s = that.month; query.month_s = month;
query.day_s = that.days; query.day_s = days;
query.type = "hour_s"; query.type = "hour_s";
query.mgroup = that.query.mgroup; query.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query).then((response) => { this.$API.enm.enstat.req(query).then((response) => {
@ -690,12 +690,12 @@ export default {
}); });
}, },
// //
getDayData() { getDayData(year, month) {
let that = this; let that = this;
let query1 = {}; let query1 = {};
query1.page = 0; query1.page = 0;
query1.year_s = that.year; query1.year_s = year;
query1.month_s = that.month; query1.month_s = month;
query1.type = "day_s"; query1.type = "day_s";
query1.mgroup = this.query.mgroup; query1.mgroup = this.query.mgroup;
this.$API.enm.enstat.req(query1).then((response) => { this.$API.enm.enstat.req(query1).then((response) => {
@ -726,11 +726,11 @@ export default {
}); });
}, },
// //
getMonthData() { getMonthData(year) {
let that = this; let that = this;
let query2 = {}; let query2 = {};
query2.page = 0; query2.page = 0;
query2.year_s = that.year; query2.year_s = year;
query2.type = "month_s"; query2.type = "month_s";
query2.mgroup = that.query.mgroup; query2.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query2).then((response) => { this.$API.enm.enstat.req(query2).then((response) => {

View File

@ -892,9 +892,9 @@ export default {
} }
}); });
}); });
that.getHourData(); that.getHourData(year, month, days);
that.getDayData(); that.getDayData(year, month);
that.getMonthData(); that.getMonthData(year);
}); });
}, },
methods: { methods: {
@ -917,13 +917,13 @@ export default {
} }
}, },
// //
getHourData() { getHourData(year, month, days) {
let that = this; let that = this;
let query = {}; let query = {};
query.page = 0; query.page = 0;
query.year_s = that.year; query.year_s = year;
query.month_s = that.month; query.month_s = month;
query.day_s = that.days; query.day_s = days;
query.type = "hour_s"; query.type = "hour_s";
query.mgroup = that.query.mgroup; query.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query).then((response) => { this.$API.enm.enstat.req(query).then((response) => {
@ -960,12 +960,12 @@ export default {
}); });
}, },
// //
getDayData() { getDayData(year, month) {
let that = this; let that = this;
let query1 = {}; let query1 = {};
query1.page = 0; query1.page = 0;
query1.year_s = that.year; query1.year_s = year;
query1.month_s = that.month; query1.month_s = month;
query1.type = "day_s"; query1.type = "day_s";
query1.mgroup = this.query.mgroup; query1.mgroup = this.query.mgroup;
this.$API.enm.enstat.req(query1).then((response) => { this.$API.enm.enstat.req(query1).then((response) => {
@ -1002,11 +1002,11 @@ export default {
}); });
}, },
// //
getMonthData() { getMonthData(year) {
let that = this; let that = this;
let query2 = {}; let query2 = {};
query2.page = 0; query2.page = 0;
query2.year_s = that.year; query2.year_s = year;
query2.type = "month_s"; query2.type = "month_s";
query2.mgroup = that.query.mgroup; query2.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query2).then((response) => { this.$API.enm.enstat.req(query2).then((response) => {

View File

@ -803,9 +803,9 @@ export default {
} }
}); });
}); });
that.getHourData(); that.getHourData(year, month, days);
that.getDayData(); that.getDayData(year, month);
that.getMonthData(); that.getMonthData(year);
}); });
}, },
methods: { methods: {
@ -829,13 +829,13 @@ export default {
this.searchDate; this.searchDate;
}, },
// //
getHourData() { getHourData(year, month, days) {
let that = this; let that = this;
let query = {}; let query = {};
query.page = 0; query.page = 0;
query.year_s = that.year; query.year_s = year;
query.month_s = that.month; query.month_s = month;
query.day_s = that.days; query.day_s = days;
query.type = "hour_s"; query.type = "hour_s";
query.mgroup = that.query.mgroup; query.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query).then((response) => { this.$API.enm.enstat.req(query).then((response) => {
@ -870,12 +870,12 @@ export default {
}); });
}, },
// //
getDayData() { getDayData(year, month) {
let that = this; let that = this;
let query1 = {}; let query1 = {};
query1.page = 0; query1.page = 0;
query1.year_s = that.year; query1.year_s = year;
query1.month_s = that.month; query1.month_s = month;
query1.type = "day_s"; query1.type = "day_s";
query1.mgroup = this.query.mgroup; query1.mgroup = this.query.mgroup;
this.$API.enm.enstat.req(query1).then((response) => { this.$API.enm.enstat.req(query1).then((response) => {
@ -909,11 +909,11 @@ export default {
}); });
}, },
// //
getMonthData() { getMonthData(year) {
let that = this; let that = this;
let query2 = {}; let query2 = {};
query2.page = 0; query2.page = 0;
query2.year_s = that.year; query2.year_s = year;
query2.type = "month_s"; query2.type = "month_s";
query2.mgroup = that.query.mgroup; query2.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query2).then((response) => { this.$API.enm.enstat.req(query2).then((response) => {

View File

@ -545,8 +545,8 @@ export default {
} }
}); });
}); });
that.getDayData(); that.getDayData(year, month);
that.getMonthData(); that.getMonthData(year);
}); });
}, },
methods: { methods: {
@ -565,12 +565,12 @@ export default {
this.searchDate; this.searchDate;
}, },
// //
getDayData() { getDayData(year, month) {
let that = this; let that = this;
let query1 = {}; let query1 = {};
query1.page = 0; query1.page = 0;
query1.year_s = that.year; query1.year_s = year;
query1.month_s = that.month; query1.month_s = month;
query1.type = "day_s"; query1.type = "day_s";
query1.mgroup = this.query.mgroup; query1.mgroup = this.query.mgroup;
this.$API.enm.enstat.req(query1).then((response) => { this.$API.enm.enstat.req(query1).then((response) => {
@ -596,11 +596,11 @@ export default {
}); });
}, },
// //
getMonthData() { getMonthData(year) {
let that = this; let that = this;
let query2 = {}; let query2 = {};
query2.page = 0; query2.page = 0;
query2.year_s = that.year; query2.year_s = year;
query2.type = "month_s"; query2.type = "month_s";
query2.mgroup = that.query.mgroup; query2.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query2).then((response) => { this.$API.enm.enstat.req(query2).then((response) => {

View File

@ -999,9 +999,9 @@ export default {
} }
}); });
}); });
that.getHourData(); that.getHourData(year, month, days);
that.getDayData(); that.getDayData(year, month);
that.getMonthData(); that.getMonthData(year);
}); });
}); });
}, },
@ -1025,13 +1025,13 @@ export default {
} }
}, },
// //
getHourData() { getHourData(year, month, days) {
let that = this; let that = this;
let query = {}; let query = {};
query.page = 0; query.page = 0;
query.year_s = that.year; query.year_s = year;
query.month_s = that.month; query.month_s = month;
query.day_s = that.days; query.day_s = days;
query.type = "hour_s"; query.type = "hour_s";
query.mgroup = that.query.mgroup; query.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query).then((response) => { this.$API.enm.enstat.req(query).then((response) => {
@ -1066,12 +1066,12 @@ export default {
}); });
}, },
// //
getDayData() { getDayData(year, month) {
let that = this; let that = this;
let query1 = {}; let query1 = {};
query1.page = 0; query1.page = 0;
query1.year_s = that.year; query1.year_s = year;
query1.month_s = that.month; query1.month_s = month;
query1.type = "day_s"; query1.type = "day_s";
query1.mgroup = this.query.mgroup; query1.mgroup = this.query.mgroup;
this.$API.enm.enstat.req(query1).then((response) => { this.$API.enm.enstat.req(query1).then((response) => {
@ -1105,11 +1105,11 @@ export default {
}); });
}, },
// //
getMonthData() { getMonthData(year) {
let that = this; let that = this;
let query2 = {}; let query2 = {};
query2.page = 0; query2.page = 0;
query2.year_s = that.year; query2.year_s = year;
query2.type = "month_s"; query2.type = "month_s";
query2.mgroup = that.query.mgroup; query2.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query2).then((response) => { this.$API.enm.enstat.req(query2).then((response) => {

View File

@ -322,14 +322,10 @@ export default {
}, },
dateChange(val) { dateChange(val) {
console.log(val); console.log(val);
if (this.typeRadio == "day") { if (this.typeRadio == "month") {
let year = val.split("-")[0];
let month = val.split("-")[1];
let days = val.split("-")[2];
this.getHourData(year, month, days);
} else if (this.typeRadio == "month") {
let year = val.split("-")[0]; let year = val.split("-")[0];
let month = val.split("-")[1]; let month = val.split("-")[1];
month = Number(month);
this.getDayData(year, month); this.getDayData(year, month);
} else { } else {
this.getMonthData(val); this.getMonthData(val);

View File

@ -563,8 +563,8 @@ export default {
} }
}); });
}); });
that.getDayData(); that.getDayData(year, month);
that.getMonthData(); that.getMonthData(year);
}); });
}, },
methods: { methods: {
@ -572,22 +572,24 @@ export default {
this.searchDate = ""; this.searchDate = "";
}, },
dateChange(val) { dateChange(val) {
let that = this;
console.log(val); console.log(val);
if (this.typeRadio == "month") { if (this.typeRadio == "month") {
let year = val.split("-")[0]; let year = val.split("-")[0];
let month = val.split("-")[1]; let month = val.split("-")[1];
month = Number(month);
this.getDayData(year, month); this.getDayData(year, month);
} else { } else {
this.getMonthData(val); this.getMonthData(val);
} }
}, },
// //
getDayData() { getDayData(year, month) {
let that = this; let that = this;
let query1 = {}; let query1 = {};
query1.page = 0; query1.page = 0;
query1.year_s = that.year; query1.year_s = year;
query1.month_s = that.month; query1.month_s = month;
query1.type = "day_s"; query1.type = "day_s";
query1.mgroup = this.query.mgroup; query1.mgroup = this.query.mgroup;
this.$API.enm.enstat.req(query1).then((response) => { this.$API.enm.enstat.req(query1).then((response) => {
@ -615,11 +617,11 @@ export default {
}); });
}, },
// //
getMonthData() { getMonthData(year) {
let that = this; let that = this;
let query2 = {}; let query2 = {};
query2.page = 0; query2.page = 0;
query2.year_s = that.year; query2.year_s = year;
query2.type = "month_s"; query2.type = "month_s";
query2.mgroup = that.query.mgroup; query2.mgroup = that.query.mgroup;
this.$API.enm.enstat.req(query2).then((response) => { this.$API.enm.enstat.req(query2).then((response) => {