diff --git a/.env.development b/.env.development index 590c68a..0d2cf46 100644 --- a/.env.development +++ b/.env.development @@ -6,6 +6,6 @@ NEXT_PUBLIC_USE_MOCK_BACKEND_LOOP_START=false NEXT_PUBLIC_EXPORT_STATIC=false NEXT_PUBLIC_USE_CGI=false # App-Versionsnummer -NEXT_PUBLIC_APP_VERSION=1.6.657 +NEXT_PUBLIC_APP_VERSION=1.6.658 NEXT_PUBLIC_CPL_MODE=json # json (Entwicklungsumgebung) oder jsSimulatedProd (CPL ->CGI-Interface-Simulator) oder production (CPL-> CGI-Interface Platzhalter) diff --git a/.env.production b/.env.production index 1fba4cd..ccd910d 100644 --- a/.env.production +++ b/.env.production @@ -5,5 +5,5 @@ NEXT_PUBLIC_CPL_API_PATH=/CPL NEXT_PUBLIC_EXPORT_STATIC=true NEXT_PUBLIC_USE_CGI=true # App-Versionsnummer -NEXT_PUBLIC_APP_VERSION=1.6.657 +NEXT_PUBLIC_APP_VERSION=1.6.658 NEXT_PUBLIC_CPL_MODE=production \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 309112a..2c0aebc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,8 @@ +## [1.6.658] – 2025-07-31 + +- feat; in KÜ Chart RSL und ISO start button + +--- ## [1.6.657] – 2025-07-28 - deat: KVz anzeigen diff --git a/components/main/kabelueberwachung/kue705FO/Charts/IsoMeasurementChart/IsoChartActionBar.tsx b/components/main/kabelueberwachung/kue705FO/Charts/IsoMeasurementChart/IsoChartActionBar.tsx index 6d99a43..5a3be62 100644 --- a/components/main/kabelueberwachung/kue705FO/Charts/IsoMeasurementChart/IsoChartActionBar.tsx +++ b/components/main/kabelueberwachung/kue705FO/Charts/IsoMeasurementChart/IsoChartActionBar.tsx @@ -237,14 +237,13 @@ const IsoChartActionBar: React.FC = () => { - {/* ISO starten button*/} - ISO starten - + { - + {/* Schleife starten button*/} RSL starten @@ -269,7 +269,7 @@ const LoopChartActionBar: React.FC = () => { Daten laden diff --git a/components/main/kabelueberwachung/kue705FO/Kue705FO.tsx b/components/main/kabelueberwachung/kue705FO/Kue705FO.tsx index 75c4cd2..a86b880 100644 --- a/components/main/kabelueberwachung/kue705FO/Kue705FO.tsx +++ b/components/main/kabelueberwachung/kue705FO/Kue705FO.tsx @@ -78,6 +78,7 @@ const Kue705FO: React.FC = ({ kueAlarm2: kueAlarm2Raw, kueOverflow: kueOverflowRaw, kuePSTmMinus96V, // <- richtig, weil so im State vorhanden + tdrActive, // <- TDR aktiv Status hinzugefügt } = useSelector((state: RootState) => state.kueDataSlice); //--------------------------------------------- @@ -168,10 +169,6 @@ const Kue705FO: React.FC = ({ const openKvzModal = () => { setShowKvzPanel(!showKvzPanel); }; - - const closeKvzModal = () => { - setShowKvzPanel(false); - }; //---------------------------------- //hooks einbinden const kueVersion = useKueVersion(slotIndex, reduxKueVersion); @@ -227,6 +224,9 @@ const Kue705FO: React.FC = ({ activeButton ); + // TDR aktiv Status für diesen Slot prüfen + const isTdrActiveForSlot = tdrActive?.[slotIndex] === 1; + // Removed useChartData(loopMeasurementCurveChartData) as the state was unused //--------------------------------- @@ -392,12 +392,15 @@ const Kue705FO: React.FC = ({ {/* TDR and KVz Buttons */} - - TDR - + {/* TDR Button - nur anzeigen wenn TDR aktiv ist */} + {isTdrActiveForSlot && ( + + TDR + + )} = ({ slotIndex={slotIndex} /> - {/* TDR Chart Modal */} - + {/* TDR Chart Modal - nur wenn TDR aktiv ist */} + {isTdrActiveForSlot && ( + + )} > )} diff --git a/components/main/kabelueberwachung/kue705FO/modals/TdrEinstellung.tsx b/components/main/kabelueberwachung/kue705FO/modals/TdrEinstellung.tsx index 6850779..24402f5 100644 --- a/components/main/kabelueberwachung/kue705FO/modals/TdrEinstellung.tsx +++ b/components/main/kabelueberwachung/kue705FO/modals/TdrEinstellung.tsx @@ -12,8 +12,9 @@ declare global { } import React, { useState } from "react"; -import { useSelector } from "react-redux"; +import { useSelector, useDispatch } from "react-redux"; import { RootState } from "../../../../../redux/store"; +import { setKueData } from "../../../../../redux/slices/kueDataSlice"; import { useAdminAuth } from "../../../settingsPageComponents/hooks/useAdminAuth"; @@ -24,6 +25,7 @@ interface Props { export default function TdrEinstellung({ slot, onClose }: Props) { const { isAdminLoggedIn } = useAdminAuth(true); + const dispatch = useDispatch(); const tdrSlice = useSelector((state: RootState) => state.kueDataSlice); const cacheKey = `slot_${slot}`; @@ -126,6 +128,11 @@ export default function TdrEinstellung({ slot, onClose }: Props) { setTdrActive(newState); updateCache(tdrData, newState); + // Redux State sofort aktualisieren für UI-Update + const updatedTdrActive = [...(tdrSlice.tdrActive || [])]; + updatedTdrActive[slot] = newState ? 1 : 0; + dispatch(setKueData({ tdrActive: updatedTdrActive })); + const isDev = window.location.hostname === "localhost"; const slotParam = `KTX${slot}=${newState ? 1 : 0}`; diff --git a/package-lock.json b/package-lock.json index 68855fb..96dc33c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "cpl-v4", - "version": "1.6.657", + "version": "1.6.658", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "cpl-v4", - "version": "1.6.657", + "version": "1.6.658", "dependencies": { "@fontsource/roboto": "^5.1.0", "@headlessui/react": "^2.2.4", diff --git a/package.json b/package.json index fba8450..0ad538c 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "cpl-v4", - "version": "1.6.657", + "version": "1.6.658", "private": true, "scripts": { "dev": "next dev",