|
@@ -312,6 +312,12 @@ onMounted(() => {
|
|
|
state.typeVal = route.params.typeVal || "booststation";
|
|
|
}
|
|
|
state.isshowwindturbineName = state.typeVal == "booststation" ? false : true;
|
|
|
+ if (route.params.ts) {
|
|
|
+ state.dateTime = [
|
|
|
+ `${dayjs(Number(route.params.ts)).format("YYYY-MM-DD")} 00:00:00`,
|
|
|
+ dayjs(Number(route.params.ts)).format("YYYY-MM-DD HH:mm:ss"),
|
|
|
+ ];
|
|
|
+ }
|
|
|
getStationList();
|
|
|
getequipmentmodel_list();
|
|
|
getfetchRelatePart();
|
|
@@ -394,6 +400,7 @@ const state = reactive({
|
|
|
endDate: null,
|
|
|
tableData: [],
|
|
|
isshowwindturbineName: true,
|
|
|
+ ts: "",
|
|
|
tableHeader: [
|
|
|
{ title: "时间", code: "ts", width: "150" },
|
|
|
{ title: "场站", code: "stationname", width: "150" },
|
|
@@ -452,6 +459,9 @@ const getStationList = async () => {
|
|
|
} else {
|
|
|
state.stationId = data[0]?.id;
|
|
|
}
|
|
|
+
|
|
|
+ state.stationId = route.params.stationId || state.stationId;
|
|
|
+ route.params.stationId ? (state.modelId = modelList?.[0]?.id || "") : "";
|
|
|
};
|
|
|
|
|
|
watch(
|
|
@@ -476,12 +486,14 @@ watch(
|
|
|
state.typeVal = route.params.typeVal || "windturbine";
|
|
|
} else {
|
|
|
state.stationName = route.params.deviceId;
|
|
|
+ state.stationId = route.params.stationId;
|
|
|
state.deviceId = "";
|
|
|
state.alarmId = route.params.alarmId || "";
|
|
|
state.typeVal = route.params.typeVal || "booststation";
|
|
|
}
|
|
|
state.isshowwindturbineName =
|
|
|
state.typeVal == "booststation" ? false : true;
|
|
|
+ getStationList();
|
|
|
},
|
|
|
{
|
|
|
deep: true,
|
|
@@ -562,7 +574,7 @@ const getAlarmHistoryt = async () => {
|
|
|
: ele.alarmType === "inverter"
|
|
|
? "光伏"
|
|
|
: "";
|
|
|
- ele.endtsName = formatTime(ele.endts);
|
|
|
+ ele.endtsName = ele.endts > 0 ? formatTime(ele.endts) : "";
|
|
|
});
|
|
|
state.tableData = data?.ls;
|
|
|
};
|