|
@@ -1,7 +1,7 @@
|
|
<template>
|
|
<template>
|
|
<div class="body">
|
|
<div class="body">
|
|
<div class="title-bar">
|
|
<div class="title-bar">
|
|
- <headerNav :remove="false" @firstRender="firstRender" />
|
|
|
|
|
|
+ <HomeNav :type="-1" @firstRender="firstRender" />
|
|
<div class="right-bar">
|
|
<div class="right-bar">
|
|
<div
|
|
<div
|
|
:class="currentDay === 'r' ? 'type-button-on' : 'day-button'"
|
|
:class="currentDay === 'r' ? 'type-button-on' : 'day-button'"
|
|
@@ -288,9 +288,7 @@
|
|
</div>
|
|
</div>
|
|
<div class="indicator-content">
|
|
<div class="indicator-content">
|
|
<div class="content-item1">
|
|
<div class="content-item1">
|
|
- <div class="item-title">
|
|
|
|
- {{ staType == -2 ? "系统效率" : "复位及时率" }}
|
|
|
|
- </div>
|
|
|
|
|
|
+ <div class="item-title">复位及时率</div>
|
|
<div class="percent" style="color: #ffffff">
|
|
<div class="percent" style="color: #ffffff">
|
|
{{ allData.zbl?.currFwjsl.toFixed(2) }}
|
|
{{ allData.zbl?.currFwjsl.toFixed(2) }}
|
|
</div>
|
|
</div>
|
|
@@ -337,9 +335,7 @@
|
|
</div>
|
|
</div>
|
|
<div class="content-dashe"></div>
|
|
<div class="content-dashe"></div>
|
|
<div class="content-item1">
|
|
<div class="content-item1">
|
|
- <div class="item-title">
|
|
|
|
- {{ staType == -2 ? "离散率" : "状态转换率" }}
|
|
|
|
- </div>
|
|
|
|
|
|
+ <div class="item-title">状态转换率</div>
|
|
<div class="percent" style="color: #ffffff">
|
|
<div class="percent" style="color: #ffffff">
|
|
{{ allData.zbl?.currZtzhl.toFixed(2) }}
|
|
{{ allData.zbl?.currZtzhl.toFixed(2) }}
|
|
</div>
|
|
</div>
|
|
@@ -386,9 +382,7 @@
|
|
</div>
|
|
</div>
|
|
<div class="content-dashe"></div>
|
|
<div class="content-dashe"></div>
|
|
<div class="content-item1">
|
|
<div class="content-item1">
|
|
- <div class="item-title">
|
|
|
|
- {{ staType == -2 ? "转换效率" : "消缺及时率" }}
|
|
|
|
- </div>
|
|
|
|
|
|
+ <div class="item-title">消缺及时率</div>
|
|
<div class="percent" style="color: #ffffff">
|
|
<div class="percent" style="color: #ffffff">
|
|
{{ allData.zbl?.currXqjsl.toFixed(2) }}
|
|
{{ allData.zbl?.currXqjsl.toFixed(2) }}
|
|
</div>
|
|
</div>
|
|
@@ -596,7 +590,9 @@
|
|
<div class="left-analysis">
|
|
<div class="left-analysis">
|
|
<div class="analysis-item">
|
|
<div class="analysis-item">
|
|
<div class="progess">
|
|
<div class="progess">
|
|
- <div class="wind-rate"> {{ staType == -2 ? "光能利用率" : "风能利用率" }}</div>
|
|
|
|
|
|
+ <div class="wind-rate">
|
|
|
|
+ {{ staType == -2 ? "光能利用率" : "风能利用率" }}
|
|
|
|
+ </div>
|
|
<div class="rate-value">
|
|
<div class="rate-value">
|
|
{{ allData?.fdlinfo?.fnlyl === 0 ? 0 : allData?.fdlinfo?.fnlyl }}%
|
|
{{ allData?.fdlinfo?.fnlyl === 0 ? 0 : allData?.fdlinfo?.fnlyl }}%
|
|
</div>
|
|
</div>
|
|
@@ -875,7 +871,7 @@
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script>
|
|
<script>
|
|
-import headerNav from "@/components/headerNav";
|
|
|
|
|
|
+import HomeNav from "@/components/headerNavE";
|
|
import progressItem from "./components/progress.vue";
|
|
import progressItem from "./components/progress.vue";
|
|
import LineCharts from "./components/lineCharts.vue";
|
|
import LineCharts from "./components/lineCharts.vue";
|
|
import PieChart from "./components/pieChart.vue";
|
|
import PieChart from "./components/pieChart.vue";
|
|
@@ -888,7 +884,7 @@ import api from "@api/economy";
|
|
export default {
|
|
export default {
|
|
name: "homePage", //首页
|
|
name: "homePage", //首页
|
|
components: {
|
|
components: {
|
|
- headerNav,
|
|
|
|
|
|
+ HomeNav,
|
|
progressItem,
|
|
progressItem,
|
|
LineCharts,
|
|
LineCharts,
|
|
PieChart,
|
|
PieChart,
|
|
@@ -949,7 +945,7 @@ export default {
|
|
this.barHeight = "110px";
|
|
this.barHeight = "110px";
|
|
this.barHeights = "220px";
|
|
this.barHeights = "220px";
|
|
}
|
|
}
|
|
- this.pointCodeList();
|
|
|
|
|
|
+ // this.pointCodeList();
|
|
window.onresize = () => {
|
|
window.onresize = () => {
|
|
return (() => {
|
|
return (() => {
|
|
window.screenHeight = window.innerHeight;
|
|
window.screenHeight = window.innerHeight;
|
|
@@ -958,17 +954,18 @@ export default {
|
|
};
|
|
};
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- handleClick() {
|
|
|
|
- this.getPointRanking(true);
|
|
|
|
- },
|
|
|
|
- handleMapClick() {
|
|
|
|
- this.getPointRanking(true, "fnlyl");
|
|
|
|
|
|
+ firstRender(headerIndex, nodeCode, stationCode) {
|
|
|
|
+ // if (d) {
|
|
|
|
+ // this.svgImg = d;
|
|
|
|
+ // }
|
|
|
|
+ this.staType = headerIndex;
|
|
|
|
+ this.foreignKeyId = stationCode ? stationCode : nodeCode;
|
|
|
|
+ this.pointCodeList();
|
|
},
|
|
},
|
|
pointCodeList() {
|
|
pointCodeList() {
|
|
api.pointCodeList().then((res) => {
|
|
api.pointCodeList().then((res) => {
|
|
if (res.data) {
|
|
if (res.data) {
|
|
-
|
|
|
|
- res.data = res.data.map((item) => {
|
|
|
|
|
|
+ res.data = res.data.map((item) => {
|
|
if (this.staType == -2) {
|
|
if (this.staType == -2) {
|
|
if (item.nemCode == "fnlyl") {
|
|
if (item.nemCode == "fnlyl") {
|
|
item.description = "光能利用率";
|
|
item.description = "光能利用率";
|
|
@@ -978,7 +975,7 @@ export default {
|
|
item.description = "风能利用率";
|
|
item.description = "风能利用率";
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- return item
|
|
|
|
|
|
+ return item;
|
|
});
|
|
});
|
|
this.pointList = res.data;
|
|
this.pointList = res.data;
|
|
this.getHomePageData();
|
|
this.getHomePageData();
|
|
@@ -986,59 +983,18 @@ export default {
|
|
}
|
|
}
|
|
});
|
|
});
|
|
},
|
|
},
|
|
- getPointRanking(popup, pointValue) {
|
|
|
|
- api
|
|
|
|
- .pointRanking({
|
|
|
|
- foreignKeyId: this.foreignKeyId || "SD_RGN",
|
|
|
|
- pointCode: pointValue ? "fnlyl" : this.pointValue,
|
|
|
|
- dateType: this.currentDay || "r",
|
|
|
|
- popup: popup,
|
|
|
|
- staType: this.staType || 0,
|
|
|
|
- })
|
|
|
|
- .then((res) => {
|
|
|
|
- if (res) {
|
|
|
|
- let zbphl = [
|
|
|
|
- {
|
|
|
|
- name: "发电量",
|
|
|
|
- children: [],
|
|
|
|
- date: [],
|
|
|
|
- },
|
|
|
|
- ];
|
|
|
|
- res.data.forEach((item) => {
|
|
|
|
- zbphl[0].name = item.description;
|
|
|
|
- zbphl[0].date.push(item.stationname);
|
|
|
|
- zbphl[0].children.push(item.value);
|
|
|
|
- });
|
|
|
|
- if (popup) {
|
|
|
|
- this.allZbphl = zbphl;
|
|
|
|
- this.displayPhb = true;
|
|
|
|
- } else {
|
|
|
|
- this.zbphl = zbphl;
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- });
|
|
|
|
- },
|
|
|
|
- firstRender(headerIndex, nodeCode, a, b, c, d) {
|
|
|
|
- if (d) {
|
|
|
|
- this.svgImg = d;
|
|
|
|
- }
|
|
|
|
- this.staType = headerIndex;
|
|
|
|
- this.foreignKeyId = nodeCode;
|
|
|
|
- this.pointCodeList();
|
|
|
|
- },
|
|
|
|
getHomePageData() {
|
|
getHomePageData() {
|
|
api
|
|
api
|
|
.homePage({
|
|
.homePage({
|
|
regionId: "",
|
|
regionId: "",
|
|
- staType: this.staType || 0,
|
|
|
|
|
|
+ staType: this.staType,
|
|
dateType: this.currentDay || "f",
|
|
dateType: this.currentDay || "f",
|
|
pointCode: this.pointValue,
|
|
pointCode: this.pointValue,
|
|
- foreignKeyId: this.foreignKeyId || "SD_RGN",
|
|
|
|
|
|
+ foreignKeyId: this.foreignKeyId || "JS_RGN",
|
|
companyId: "",
|
|
companyId: "",
|
|
})
|
|
})
|
|
.then((res) => {
|
|
.then((res) => {
|
|
if (res) {
|
|
if (res) {
|
|
- // console.log(999);
|
|
|
|
this.allData = res.data;
|
|
this.allData = res.data;
|
|
let arr = [];
|
|
let arr = [];
|
|
if (this.staType != -2) {
|
|
if (this.staType != -2) {
|
|
@@ -1169,11 +1125,49 @@ export default {
|
|
obj.yPoint = Number(item.yPoint);
|
|
obj.yPoint = Number(item.yPoint);
|
|
stationinfo.push(obj);
|
|
stationinfo.push(obj);
|
|
});
|
|
});
|
|
- console.log(999, stationinfo);
|
|
|
|
this.stationinfo = stationinfo;
|
|
this.stationinfo = stationinfo;
|
|
}
|
|
}
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
+ getPointRanking(popup, pointValue) {
|
|
|
|
+ api
|
|
|
|
+ .pointRanking({
|
|
|
|
+ foreignKeyId: this.foreignKeyId || "JS_RGN",
|
|
|
|
+ pointCode: pointValue ? "fnlyl" : this.pointValue,
|
|
|
|
+ dateType: this.currentDay || "r",
|
|
|
|
+ popup: popup,
|
|
|
|
+ staType: this.staType,
|
|
|
|
+ })
|
|
|
|
+ .then((res) => {
|
|
|
|
+ if (res) {
|
|
|
|
+ let zbphl = [
|
|
|
|
+ {
|
|
|
|
+ name: "发电量",
|
|
|
|
+ children: [],
|
|
|
|
+ date: [],
|
|
|
|
+ },
|
|
|
|
+ ];
|
|
|
|
+ res.data.forEach((item) => {
|
|
|
|
+ zbphl[0].name = item.description;
|
|
|
|
+ zbphl[0].date.push(item.stationname);
|
|
|
|
+ zbphl[0].children.push(item.value);
|
|
|
|
+ });
|
|
|
|
+ if (popup) {
|
|
|
|
+ this.allZbphl = zbphl;
|
|
|
|
+ this.displayPhb = true;
|
|
|
|
+ } else {
|
|
|
|
+ this.zbphl = zbphl;
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ },
|
|
|
|
+ handleClick() {
|
|
|
|
+ this.getPointRanking(true);
|
|
|
|
+ },
|
|
|
|
+ handleMapClick() {
|
|
|
|
+ this.getPointRanking(true, "fnlyl");
|
|
|
|
+ },
|
|
|
|
+
|
|
handleChangeType(val) {
|
|
handleChangeType(val) {
|
|
this.current = val;
|
|
this.current = val;
|
|
this.getHomePageData();
|
|
this.getHomePageData();
|