master
parent
6777ad0953
commit
7a89a54b28
Binary file not shown.
|
@ -6,7 +6,7 @@ interface idInfo {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 设备树 0 一级服务
|
|
||||||
// 全部的能量调节页面的接口-统计可调资源
|
// 全部的能量调节页面的接口-统计可调资源
|
||||||
export function sourcInfoApi(data: any) {
|
export function sourcInfoApi(data: any) {
|
||||||
return request({
|
return request({
|
||||||
|
@ -15,4 +15,13 @@ export function sourcInfoApi(data: any) {
|
||||||
data
|
data
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
// 负载率预测
|
||||||
|
export function forceRateApi(data: any) {
|
||||||
|
return request({
|
||||||
|
url: '/api/wwpm/biz/v1/load_rate_forecast',
|
||||||
|
method: 'POST',
|
||||||
|
data
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -153,10 +153,8 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="info3">
|
<div class="info3">
|
||||||
<rateLine_will
|
<!-- <rateLine_will :rateDate="rateDate_will"></rateLine_will> -->
|
||||||
:rateDate="rateDate_will"
|
<!-- -->
|
||||||
:keysv="keyechart"
|
|
||||||
></rateLine_will>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="capAjust_box content_bg" v-else>
|
<div class="capAjust_box content_bg" v-else>
|
||||||
|
@ -216,6 +214,7 @@
|
||||||
:rateDate="rateDate_cur"
|
:rateDate="rateDate_cur"
|
||||||
:keysv="keyechart"
|
:keysv="keyechart"
|
||||||
v-if="rateDate_curFlag"
|
v-if="rateDate_curFlag"
|
||||||
|
:key="refreshkey"
|
||||||
></rateLine>
|
></rateLine>
|
||||||
<!-- <rateLine
|
<!-- <rateLine
|
||||||
:rateDate="rateDate_cur"
|
:rateDate="rateDate_cur"
|
||||||
|
@ -262,9 +261,12 @@
|
||||||
|
|
||||||
</div> -->
|
</div> -->
|
||||||
<div class="info3">
|
<div class="info3">
|
||||||
|
11
|
||||||
<rateLine_will
|
<rateLine_will
|
||||||
|
v-if="rateDate_willFlag"
|
||||||
:rateDate="rateDate_will"
|
:rateDate="rateDate_will"
|
||||||
:keysv="keyechart"
|
:keysv="keyechart"
|
||||||
|
:key="refreshkey"
|
||||||
></rateLine_will>
|
></rateLine_will>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -474,9 +476,10 @@ import { number } from "echarts";
|
||||||
import rateJSONData from "@/assets/json/Ajust_rate.json";
|
import rateJSONData from "@/assets/json/Ajust_rate.json";
|
||||||
import ajustsource from "@/assets/json/Ajustsoure.json";
|
import ajustsource from "@/assets/json/Ajustsoure.json";
|
||||||
import Ajust_strategy from "@/assets/json/Ajust_strategy.json";
|
import Ajust_strategy from "@/assets/json/Ajust_strategy.json";
|
||||||
import { sourcInfoApi } from "@/api/ajust/ajust.ts";
|
import { sourcInfoApi, forceRateApi } from "@/api/ajust/ajust.ts";
|
||||||
import { getSourceMapRange } from "typescript";
|
import { getSourceMapRange } from "typescript";
|
||||||
import { ITEM_RENDER_EVT } from "element-plus/es/components/virtual-list/src/defaults.mjs";
|
import { ITEM_RENDER_EVT } from "element-plus/es/components/virtual-list/src/defaults.mjs";
|
||||||
|
import { deflateRawSync } from "zlib";
|
||||||
|
|
||||||
// onMounted(async () => {
|
// onMounted(async () => {
|
||||||
// getRateDate(); //获取负载率
|
// getRateDate(); //获取负载率
|
||||||
|
@ -502,7 +505,7 @@ const getAllSourceAjust = () => {
|
||||||
sourcInfoApi(datainput).then((res) => {
|
sourcInfoApi(datainput).then((res) => {
|
||||||
// handelSourceTable(res.data);
|
// handelSourceTable(res.data);
|
||||||
// tablepvData.value=res?.data
|
// tablepvData.value=res?.data
|
||||||
let counts=res.data
|
let counts = res.data;
|
||||||
for (const [type, count] of Object.entries(counts)) {
|
for (const [type, count] of Object.entries(counts)) {
|
||||||
const item = sourceLArr.find((item) => item.type === type);
|
const item = sourceLArr.find((item) => item.type === type);
|
||||||
if (item) {
|
if (item) {
|
||||||
|
@ -524,9 +527,10 @@ const getAllSourceAjust_Line = (mrid: string) => {
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
let treeAreaId = ref(""); //点击设备树二级服务获取的台区id去获取台区负载率
|
let treeNodeKey = ref(""); //点击设备树二级服务获取的台区id去获取台区负载率
|
||||||
// 设备树传来的设备树节点id treeNode是节点数据
|
// 设备树传来的设备树节点id treeNode是节点数据
|
||||||
const getTreeKey = (treeNode: any) => {
|
const getTreeKey = (treeNode: any) => {
|
||||||
|
treeNodeKey.value = treeNode.key; //线路的id
|
||||||
allFlag.value = false;
|
allFlag.value = false;
|
||||||
if (treeNode.level === 3) {
|
if (treeNode.level === 3) {
|
||||||
console.log(treeNode.level, "3");
|
console.log(treeNode.level, "3");
|
||||||
|
@ -607,7 +611,11 @@ let keyechart = ref<number>(2);
|
||||||
let rateDate_cur = reactive<RateDateInfo[]>([]); //当前的负载率
|
let rateDate_cur = reactive<RateDateInfo[]>([]); //当前的负载率
|
||||||
let rateDate_will = reactive<RateDateInfo[]>([]); //预测负载率
|
let rateDate_will = reactive<RateDateInfo[]>([]); //预测负载率
|
||||||
let rateDate_curFlag = ref(false);
|
let rateDate_curFlag = ref(false);
|
||||||
|
let rateDate_willFlag = ref(false);
|
||||||
|
|
||||||
const getRateDate = (treeAreaId: string) => {
|
const getRateDate = (treeAreaId: string) => {
|
||||||
|
refreshkey.value += 1;
|
||||||
|
rateDate_cur = [];
|
||||||
// 定时15分钟获取接口数据
|
// 定时15分钟获取接口数据
|
||||||
// console.log(treeAreaId, treeAreaId.value,"treeAreaId==========");
|
// console.log(treeAreaId, treeAreaId.value,"treeAreaId==========");
|
||||||
|
|
||||||
|
@ -617,10 +625,9 @@ const getRateDate = (treeAreaId: string) => {
|
||||||
orgID: "8af8470a47aad8e20147aad92e400335",
|
orgID: "8af8470a47aad8e20147aad92e400335",
|
||||||
}).then((res) => {
|
}).then((res) => {
|
||||||
console.log(res, "res");
|
console.log(res, "res");
|
||||||
|
|
||||||
if (res.data.result.length > 0) {
|
if (res.data.result.length > 0) {
|
||||||
rateDate_cur = res?.data.result;
|
rateDate_cur = res?.data.result;
|
||||||
keyechart.value++;
|
refreshkey.value += 1;
|
||||||
rateDate_curFlag.value = true;
|
rateDate_curFlag.value = true;
|
||||||
// console.log(res, "res");
|
// console.log(res, "res");
|
||||||
} else {
|
} else {
|
||||||
|
@ -953,7 +960,20 @@ const handleSaveDate = () => {
|
||||||
ite.isEdit = false; //所有的编辑状态全部为假
|
ite.isEdit = false; //所有的编辑状态全部为假
|
||||||
});
|
});
|
||||||
console.log(adjustTableData, "adjustTableData");
|
console.log(adjustTableData, "adjustTableData");
|
||||||
|
refreshkey.value += 1;
|
||||||
|
rateDate_will=[]
|
||||||
|
//保存后要进行负载率预测
|
||||||
|
forceRateApi({
|
||||||
|
orgID: "8af8470a47aad8e20147aad92e400335",
|
||||||
|
mrid: treeNodeKey.value,
|
||||||
|
regulateNumber: 22,
|
||||||
|
}).then((res) => {
|
||||||
|
console.log(res, "1------------res");
|
||||||
|
rateDate_will = res.data.result;
|
||||||
|
if(res.data.result.length>0){
|
||||||
|
rateDate_willFlag.value = true;
|
||||||
|
}
|
||||||
|
});
|
||||||
// 赋值给一个数组给下发指令的接口用
|
// 赋值给一个数组给下发指令的接口用
|
||||||
newAjustTableData = adjustTableData;
|
newAjustTableData = adjustTableData;
|
||||||
// console.log(newAjustTableData, "newAjustTableData1-1-1-");
|
// console.log(newAjustTableData, "newAjustTableData1-1-1-");
|
||||||
|
@ -1743,6 +1763,45 @@ const styleVar = computed(() => {
|
||||||
border: transparent !important;
|
border: transparent !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
.table_box {
|
||||||
|
.tableTitle {
|
||||||
|
div:nth-child(1) {
|
||||||
|
width: 23%;
|
||||||
|
}
|
||||||
|
|
||||||
|
div:nth-child(2) {
|
||||||
|
width: 23%;
|
||||||
|
}
|
||||||
|
|
||||||
|
div:nth-child(3) {
|
||||||
|
width: 23%;
|
||||||
|
}
|
||||||
|
|
||||||
|
div:nth-child(4) {
|
||||||
|
width: 30%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.el-carousel {
|
||||||
|
.th {
|
||||||
|
div:nth-child(1) {
|
||||||
|
width: 23%;
|
||||||
|
}
|
||||||
|
|
||||||
|
div:nth-child(2) {
|
||||||
|
width: 23%;
|
||||||
|
}
|
||||||
|
|
||||||
|
div:nth-child(3) {
|
||||||
|
width: 23%;
|
||||||
|
}
|
||||||
|
|
||||||
|
div:nth-child(4) {
|
||||||
|
width: 30%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -14,12 +14,12 @@ import {
|
||||||
} from "vue";
|
} from "vue";
|
||||||
import transformFontSize from "@/hooks/transFormSize.ts";
|
import transformFontSize from "@/hooks/transFormSize.ts";
|
||||||
import "echarts/lib/component/dataZoom";
|
import "echarts/lib/component/dataZoom";
|
||||||
interface RateDateInfo {
|
interface RateDateInfo_will {
|
||||||
loadRate?: string;
|
measValue?: string;
|
||||||
dataTime?: string;
|
datetime?: string;
|
||||||
}
|
}
|
||||||
const props = defineProps<{
|
const props = defineProps<{
|
||||||
rateDate: RateDateInfo[];
|
rateDate: RateDateInfo_will[];
|
||||||
keysv?: Number;
|
keysv?: Number;
|
||||||
}>();
|
}>();
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
|
@ -112,8 +112,8 @@ const drawOneLine = (rateArr: RateDateInfo[]) => {
|
||||||
// return param.split(' ')[1].split(':')[0] + ':' + param.split(' ')[1].split(':')[1]
|
// return param.split(' ')[1].split(':')[0] + ':' + param.split(' ')[1].split(':')[1]
|
||||||
// },
|
// },
|
||||||
},
|
},
|
||||||
// data: (rateArr.map((rtime) => rtime?.dataTime.slice(-8))),
|
data: (rateArr.map((rtime) => rtime?.datetime.slice(-8))),
|
||||||
data: ["03:00", "06:00", "09:00", "12:00", "15:00", "18:00", "24:00"],
|
// data: ["03:00", "06:00", "09:00", "12:00", "15:00", "18:00", "24:00"],
|
||||||
},
|
},
|
||||||
yAxis: {
|
yAxis: {
|
||||||
splitLine: {
|
splitLine: {
|
||||||
|
@ -170,7 +170,7 @@ const drawOneLine = (rateArr: RateDateInfo[]) => {
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
// data: [20, 32, 35, 26, 24, 20, 8],
|
// data: [20, 32, 35, 26, 24, 20, 8],
|
||||||
// data: rateArr.map((rload) => rload.loadRate),
|
data: rateArr.map((rload) => rload.measValue),
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue