|
@@ -11,9 +11,9 @@
|
|
|
<ul class="MicrYaHei">
|
|
|
<div style="min-width:300px;"></div>
|
|
|
<div>
|
|
|
- <li :class="{current: num == 1}" @click="change(1)">室内温度</li>
|
|
|
- <li :class="{current: num==2}" @click="change(2)">节能率</li>
|
|
|
- <li :class="{current: num==3}" @click="change(3)">执行率</li>
|
|
|
+ <li :class="{current: num == 1}" @click="changeNum(1)">室内温度</li>
|
|
|
+ <li :class="{current: num==2}" @click="changeNum(2)">节能率</li>
|
|
|
+ <li :class="{current: num==3}" @click="changeNum(3)">执行率</li>
|
|
|
</div>
|
|
|
<div class="count-top-right">
|
|
|
<date-temp v-if="date" @pickerVal="pickerVal" :date="date"></date-temp>
|
|
@@ -76,7 +76,8 @@ import {
|
|
|
energyDayQuery,
|
|
|
querychiller,
|
|
|
querySpace,
|
|
|
- queryHisdataQueryPeriodData
|
|
|
+ queryHisdataQueryPeriodData,
|
|
|
+ queryTdbDay
|
|
|
} from "@/api/evaluate/evaluate.js";
|
|
|
import { queryChillerExecuteInfo } from "@/api/appeal/appeal.js";
|
|
|
|
|
@@ -84,23 +85,19 @@ export default {
|
|
|
data() {
|
|
|
return {
|
|
|
headText: "运行评价",
|
|
|
- num: 1,
|
|
|
+ num: 1, //tab @
|
|
|
+ date: "", // 传过来的日期@
|
|
|
+ type: "", //传过来的日期 @
|
|
|
value2: true,
|
|
|
- current: {},
|
|
|
- similarDay: {},
|
|
|
- samples: [],
|
|
|
- maxArr: [],
|
|
|
- chillerExecuteRate: "", //略执行率
|
|
|
- isExecutedNum: "", //已执行数量
|
|
|
- allReceivedNum: "", //共收到数量
|
|
|
- dataList: [], //室内温度满足率
|
|
|
- energySaving: "", //节能量
|
|
|
- tindoorOverrunDegree: "", //超限程度
|
|
|
- tindoorFillRate: "", //室内温度满足率
|
|
|
+ current: {}, //本日概况 @
|
|
|
+ similarDay: {}, //相似日概况 @
|
|
|
+ samples: [], //相似日列表 @
|
|
|
+ maxArr: [], // @
|
|
|
+ dataList: [], //室内温度满足率@
|
|
|
+ tindoorFillRate: "", //室内温度满足率@
|
|
|
energySavingRate: "", //节能率
|
|
|
- cardList: [],
|
|
|
- date: "",
|
|
|
- dateVal: ""
|
|
|
+ cardList: [], //执行率@
|
|
|
+ dateVal: "" //@
|
|
|
};
|
|
|
},
|
|
|
components: {
|
|
@@ -114,127 +111,115 @@ export default {
|
|
|
DateTemp
|
|
|
},
|
|
|
mounted() {
|
|
|
- this.querychillerMethod();
|
|
|
- this.querySpaceMethod();
|
|
|
- this.queryHisdataQueryPeriodDataMethod();
|
|
|
- this.start(this.dateVal);
|
|
|
- this.queryRunDataQury(this.dateVal);
|
|
|
- this.type = this.$route.query.type;
|
|
|
- this.date = this.$route.query.name;
|
|
|
- if (this.type == 1) {
|
|
|
- this.num = 1;
|
|
|
- // querychillerMethod();
|
|
|
- } else if (this.type == 2) {
|
|
|
- this.num = 2;
|
|
|
- this.queryEnergyDayQuery(this.dateVal);
|
|
|
- } else if (this.type == 3) {
|
|
|
- this.num = 3;
|
|
|
- this.queryimplement(this.dateVal);
|
|
|
- }
|
|
|
+ this.init();
|
|
|
},
|
|
|
methods: {
|
|
|
- queryHisdataQueryPeriodDataMethod() {
|
|
|
- let params = {
|
|
|
- postParams: {
|
|
|
- projectId: this.$store.state.projectId,
|
|
|
- funcids: ["Tdb"], //固定值
|
|
|
- period: 60, //固定值
|
|
|
- startTime: "20200225000000", //开始时间 yyyyMMddH24miss
|
|
|
- endTime: "20200225235959", //结束时间 yyyyMMddH24miss
|
|
|
- objectId: "Sp4413030001388657a6b77e4605880b85767e4eaddd" //空间id
|
|
|
- }
|
|
|
- };
|
|
|
- queryHisdataQueryPeriodData(params).then(res => {
|
|
|
- console.log(res);
|
|
|
- });
|
|
|
+ init() {
|
|
|
+ this.type = this.$route.query.type;
|
|
|
+ this.date = this.$route.query.name;
|
|
|
+ if (this.type) {
|
|
|
+ this.num = this.type;
|
|
|
+ }
|
|
|
+ if (this.date) {
|
|
|
+ this.date = this.formatterStr3(
|
|
|
+ new Date().getFullYear() + this.formatterStr2(this.date)
|
|
|
+ );
|
|
|
+ }
|
|
|
+ if (this.num && this.date) {
|
|
|
+ this.changeNumMethod();
|
|
|
+ }
|
|
|
},
|
|
|
- // 查询一天的运行评价-室内温度页面左上角温度满足率
|
|
|
- querySpaceMethod() {
|
|
|
- let params = {
|
|
|
- postParams: {
|
|
|
- criteria: {
|
|
|
- projectId: this.$store.sate.projectId,
|
|
|
- // isChillerMonitor: 1 //是否冷站智控监测 1:是 0:不是
|
|
|
- }
|
|
|
- }
|
|
|
- };
|
|
|
- querySpace(params).then(res => {
|
|
|
- console.log(res);
|
|
|
- });
|
|
|
+ // @
|
|
|
+ formatterStr2(str) {
|
|
|
+ if (str) {
|
|
|
+ return str.substring(0, 2) + "" + str.substring(3, 5);
|
|
|
+ }
|
|
|
},
|
|
|
- // 室内温度位置详情-室内温度页面中间的空间列表
|
|
|
- querychillerMethod() {
|
|
|
+ // 室内温度table @
|
|
|
+ queryTdbDayMethod(date) {
|
|
|
this.dataList = [];
|
|
|
- let params = {
|
|
|
- postParams: {
|
|
|
- criteria: {
|
|
|
- projectId: this.$store.state.projectId,
|
|
|
- date: "20200226"
|
|
|
- }
|
|
|
+ let arr1 = [],
|
|
|
+ arr2 = [];
|
|
|
+ queryTdbDay(date, {}).then(res => {
|
|
|
+ this.tindoorFillRate = res.tindoorFillRate;
|
|
|
+ console.log("室内温度满足率", res);
|
|
|
+ let content = res.content;
|
|
|
+ if (content.length > 0) {
|
|
|
+ content.forEach(item => {
|
|
|
+ arr1.push(item.spaceDayRpt.floorLocalName);
|
|
|
+ });
|
|
|
+ arr1 = Array.from(new Set(arr1));
|
|
|
+ arr1.forEach(el => {
|
|
|
+ let obj = {
|
|
|
+ floor: el,
|
|
|
+ floorArr: []
|
|
|
+ };
|
|
|
+ arr2.push(obj);
|
|
|
+ });
|
|
|
+ content.forEach(item2 => {
|
|
|
+ arr2.forEach(item => {
|
|
|
+ if (item2.spaceDayRpt.floorLocalName == item.floor) {
|
|
|
+ item.floorArr.push(item2.spaceDayRpt);
|
|
|
+ }
|
|
|
+ });
|
|
|
+ });
|
|
|
}
|
|
|
- };
|
|
|
- querychiller(params).then(res => {
|
|
|
- this.tindoorFillRate = res.content[0].tindoorFillRate || 0; //室内温度满足率 = res.content ? res.content : [];
|
|
|
+ this.dataList = arr2;
|
|
|
console.log(this.dataList);
|
|
|
});
|
|
|
},
|
|
|
+ // @
|
|
|
+ formatterStr3(str) {
|
|
|
+ if (str) {
|
|
|
+ return str.substring(0, 4) + str.substring(4, 6) + str.substring(6, 8);
|
|
|
+ }
|
|
|
+ },
|
|
|
+ // 执行率@
|
|
|
queryimplement(date) {
|
|
|
let params = {
|
|
|
postParams: {
|
|
|
criteria: {
|
|
|
date: date
|
|
|
- // "id":15582 //指令id
|
|
|
}
|
|
|
}
|
|
|
};
|
|
|
queryChillerExecuteInfo(params).then(res => {
|
|
|
this.cardList = res.data ? res.data : [];
|
|
|
+ console.log("执行率", res);
|
|
|
});
|
|
|
},
|
|
|
- change: function(index) {
|
|
|
- this.num = index;
|
|
|
- this.start(this.dateVal);
|
|
|
- },
|
|
|
- start(date) {
|
|
|
+ // 根据tab @
|
|
|
+ changeNumMethod() {
|
|
|
if (this.num == 1) {
|
|
|
- // this.querychillerMethod();
|
|
|
- // this.queryRunDataQury(date);
|
|
|
+ this.queryTdbDayMethod(this.date);
|
|
|
} else if (this.num == 2) {
|
|
|
- this.queryEnergyDayQuery(date);
|
|
|
+ this.queryEnergyDayQuery(this.date);
|
|
|
} else if (this.num == 3) {
|
|
|
- this.queryimplement(date);
|
|
|
+ this.queryimplement(this.date);
|
|
|
}
|
|
|
},
|
|
|
+ // 点击tab @
|
|
|
+ changeNum(index) {
|
|
|
+ this.num = index;
|
|
|
+ this.changeNumMethod();
|
|
|
+ },
|
|
|
+ // @
|
|
|
formatterStr(str) {
|
|
|
if (str) {
|
|
|
return str.substring(0, 4) + str.substring(5, 7) + str.substring(8, 10);
|
|
|
}
|
|
|
},
|
|
|
+ // @
|
|
|
pickerVal(val) {
|
|
|
if (val) {
|
|
|
this.dateVal = this.formatterStr(val);
|
|
|
- this.start(this.dateVal);
|
|
|
}
|
|
|
},
|
|
|
+ // @
|
|
|
jumpIndex() {
|
|
|
this.$router.push("/evaluate");
|
|
|
},
|
|
|
- queryRunDataQury(date) {
|
|
|
- this.runDataQuryArr = [];
|
|
|
- runDataQury(date, {}).then(res => {
|
|
|
- if (res.result == "success") {
|
|
|
- this.chillerExecuteRate = res.chillerExecuteRate; //略执行率
|
|
|
- this.isExecutedNum = res.isExecutedNum; //已执行数量
|
|
|
- this.allReceivedNum = res.allReceivedNum; //共收到数量
|
|
|
- this.dataList = res.dataList ? res.dataList : []; //室内温度满足率
|
|
|
- this.energySaving = res.energySaving; //节能量
|
|
|
- this.tindoorOverrunDegree = res.tindoorOverrunDegree; //超限程度
|
|
|
-
|
|
|
- this.energySavingRate = res.energySavingRate; //节能率
|
|
|
- }
|
|
|
- });
|
|
|
- },
|
|
|
- // 节能率
|
|
|
+ // 节能率@
|
|
|
queryEnergyDayQuery(date) {
|
|
|
energyDayQuery(date, {}).then(res => {
|
|
|
if (res.result == "success") {
|
|
@@ -263,6 +248,7 @@ export default {
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
+ // @
|
|
|
sortMethod(arr) {
|
|
|
if (arr instanceof Array) {
|
|
|
return arr.sort(function(num1, num2) {
|
|
@@ -272,6 +258,7 @@ export default {
|
|
|
return 1;
|
|
|
}
|
|
|
},
|
|
|
+ // @
|
|
|
maxMethod(arr) {
|
|
|
if (arr instanceof Array) {
|
|
|
return eval(arr[arr.length - 1]);
|