Isolationwswert in isoDisplay statt Schleifenwert

This commit is contained in:
ISA
2024-11-08 08:33:27 +01:00
parent f978e4cf90
commit 9050cf05a6

View File

@@ -40,9 +40,7 @@ function Kue705FO({
const [isoGreaterThan200, setIsoGreaterThan200] = useState(">200 MOhm"); const [isoGreaterThan200, setIsoGreaterThan200] = useState(">200 MOhm");
const [loading, setLoading] = useState(false); const [loading, setLoading] = useState(false);
const [currentDisplayValue, setCurrentDisplayValue] = useState( const [isoDisplayValue, setIsoDisplayValue] = useState(isolationswert);
schleifenwiderstand || "0"
);
const [showModal, setShowModal] = useState(false); const [showModal, setShowModal] = useState(false);
const [showChartModal, setShowChartModal] = useState(false); const [showChartModal, setShowChartModal] = useState(false);
const [chartData, setChartData] = useState(null); const [chartData, setChartData] = useState(null);
@@ -355,7 +353,7 @@ function Kue705FO({
// Funktion zum Blinken des Textes oder Icons // Funktion zum Blinken des Textes oder Icons
const setBlinkingText = (text) => { const setBlinkingText = (text) => {
intervalId = setInterval(() => { intervalId = setInterval(() => {
setCurrentDisplayValue((prevValue) => setIsoDisplayValue((prevValue) =>
prevValue === text ? ( prevValue === text ? (
<i <i
className="bi bi-exclamation-triangle" className="bi bi-exclamation-triangle"
@@ -386,10 +384,10 @@ function Kue705FO({
setBlinkingText(loopFaultDisplayText); setBlinkingText(loopFaultDisplayText);
} else if (kueOverflow?.[slotIndex] === 1) { } else if (kueOverflow?.[slotIndex] === 1) {
clearInterval(intervalId); clearInterval(intervalId);
setCurrentDisplayValue(isoGreaterThan200); setIsoDisplayValue(isoGreaterThan200);
} else { } else {
clearInterval(intervalId); clearInterval(intervalId);
setCurrentDisplayValue(isolationswert); // Standardanzeige setIsoDisplayValue(isolationswert); // Standardanzeige
} }
// Cleanup bei Änderungen des Status oder Schließen des Effekts // Cleanup bei Änderungen des Status oder Schließen des Effekts
@@ -486,7 +484,7 @@ function Kue705FO({
: "" : ""
} }
> >
{currentDisplayValue} {isoDisplayValue}
</span> </span>
{kuePSTmMinus96V?.[slotIndex] !== 1 && {kuePSTmMinus96V?.[slotIndex] !== 1 &&