Bu işleme şunda yer alıyor:
lb 2023-11-09 16:30:27 +08:00
ebeveyn 96aab1bea1
işleme c16a52a20e

Dosyayı Görüntüle

@ -4,6 +4,7 @@ import { useSelector } from "react-redux";
import { stateNameMap } from "../../../store/features/kilnSlice";
import { useEffect } from "react";
import { useDispatch } from "react-redux";
export default function Kiln() {
const kilnInfo = useSelector((state) => state.kiln);
const dispatch = useDispatch();
@ -15,21 +16,21 @@ export default function Kiln() {
}));
useEffect(() => {
setTimeout(() => {
setInterval(() => {
dispatch({
type: "kiln/setKilnInfo",
payload: {
kilnPressure: "100Pa",
waterTemp: "100℃",
waterFlow: "100m³/h",
waterPressure: "100Pa",
combustionAirPressure: "100Pa",
topTemp: "100℃",
compressedAirPressure: "100Pa",
meltTemp: "100℃",
kilnPressure: Math.ceil(Math.random() * 100) + "Pa",
waterTemp: Math.ceil(Math.random() * 100) + "℃",
waterFlow: Math.ceil(Math.random() * 100) + "m³/h",
waterPressure: Math.ceil(Math.random() * 100) + "Pa",
combustionAirPressure: Math.ceil(Math.random() * 100) + "Pa",
topTemp: Math.ceil(Math.random() * 100) + "℃",
compressedAirPressure: Math.ceil(Math.random() * 100) + "Pa",
meltTemp: Math.ceil(Math.random() * 100) + "℃",
},
});
}, 3000);
}, 30000);
}, []);
// const infos = [