|
@@ -202,7 +202,6 @@ import LineChart from "@/components/Echarts/LineChart.vue";
|
|
|
import PieChart from "@/components/Echarts/PieChart.vue";
|
|
|
import BarChart from "@/components/Echarts/BarChart.vue";
|
|
|
import echarts from "echarts";
|
|
|
-import {carbonEmissionStatistics, energyForYear} from "@/api/screen/service";
|
|
|
import {
|
|
|
|
|
|
thisWeekElectricity,todayElectricity,monthElectricity,roomLoad,warnDevice,warnEvent,waterState
|
|
@@ -250,11 +249,9 @@ export default {
|
|
|
//楼宇每月用电量
|
|
|
this.monthElectricity()
|
|
|
|
|
|
- //碳排放量月度变化趋势图
|
|
|
- this.carbonEmissionStatistics();
|
|
|
|
|
|
- //年度累计综合能耗
|
|
|
- this.energyForYear();
|
|
|
+
|
|
|
+
|
|
|
},
|
|
|
destroyed() {},
|
|
|
beforeDestroy() {},
|
|
@@ -268,8 +265,8 @@ export default {
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
-
|
|
|
-
|
|
|
+
|
|
|
+
|
|
|
//楼宇今日总用电量
|
|
|
todayElectricity() {
|
|
|
todayElectricity(this.$props.appOrg).then((res) => {
|
|
@@ -354,7 +351,7 @@ export default {
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
-
|
|
|
+
|
|
|
//楼宇每月用电量
|
|
|
monthElectricity() {
|
|
|
monthElectricity(this.$props.appOrg).then((res) => {
|
|
@@ -468,89 +465,9 @@ export default {
|
|
|
},
|
|
|
|
|
|
|
|
|
- //碳排放量月度变化趋势图
|
|
|
- carbonEmissionStatistics() {
|
|
|
- carbonEmissionStatistics().then((res) => {
|
|
|
- if (Number(res.code) === 200) {
|
|
|
- this.energyRateLineData = [
|
|
|
- {
|
|
|
- name: "2024年",
|
|
|
- type: "line",
|
|
|
- areaStyle: {
|
|
|
- opacity: 0.8,
|
|
|
- color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
|
|
|
- {
|
|
|
- offset: 0,
|
|
|
- color: "rgba(214, 124, 21, 0.1804)",
|
|
|
- },
|
|
|
- {
|
|
|
- offset: 1,
|
|
|
- color: "rgba(255, 255, 255, 0)",
|
|
|
- },
|
|
|
- ]),
|
|
|
- },
|
|
|
- smooth: true,
|
|
|
- lineStyle: {
|
|
|
- width: 2, // 设置线宽
|
|
|
- color: res.data.year2024.color, // 设置线的颜色
|
|
|
- },
|
|
|
- data: res.data.year2024.dataList,
|
|
|
- },
|
|
|
- {
|
|
|
- name: "2023年",
|
|
|
- type: "line",
|
|
|
- areaStyle: {
|
|
|
- opacity: 0.8,
|
|
|
- color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
|
|
|
- {
|
|
|
- offset: 0.03,
|
|
|
- color: "rgba(30, 240, 215, 0.4196)",
|
|
|
- },
|
|
|
- {
|
|
|
- offset: 0.68,
|
|
|
- color: "rgba(23, 240, 240, 0)",
|
|
|
- },
|
|
|
- ]),
|
|
|
- },
|
|
|
- lineStyle: {
|
|
|
- width: 2, // 设置线宽
|
|
|
- color: res.data.year2023.color, // 设置线的颜色
|
|
|
- },
|
|
|
- smooth: true,
|
|
|
- data: res.data.year2023.dataList,
|
|
|
- },
|
|
|
- ];
|
|
|
- this.energyRateLineAxis = {
|
|
|
- type: "category",
|
|
|
- data: res.data.xList,
|
|
|
- axisLabel: {
|
|
|
- color: "white", // 设置横坐标轴字体颜色为红色
|
|
|
- },
|
|
|
- axisLine: {
|
|
|
- show: true,
|
|
|
- lineStyle:{
|
|
|
- color:"#08595B"
|
|
|
- }
|
|
|
- },
|
|
|
- axisTick: {
|
|
|
- show: false,
|
|
|
- },
|
|
|
- splitArea: false,
|
|
|
- };
|
|
|
- }
|
|
|
- });
|
|
|
- },
|
|
|
|
|
|
- //年度累计综合能耗
|
|
|
- energyForYear() {
|
|
|
- energyForYear().then((res) => {
|
|
|
- if (Number(res.code) === 200) {
|
|
|
- this.yearAllChangeData.energyNum = res.data.energyNum.value;
|
|
|
- this.yearAllChangeData.reduceName = res.data.reduceNum.name;
|
|
|
- this.yearAllChangeData.reduceNum = Math.abs(res.data.reduceNum.value);
|
|
|
- }
|
|
|
- });
|
|
|
- },
|
|
|
+
|
|
|
+
|
|
|
},
|
|
|
};
|
|
|
</script>
|