feat: isChartOpen wird beim Öffnen des Chart-Modals gesetzt
- `setChartOpen(true)` in `handleOpenChartModal` hinzugefügt. - Redux-Import von `setChartOpen` in `Kue705FO.tsx` sichergestellt. - Dadurch bleibt `isChartOpen` nicht mehr `false`, wenn das Modal geöffnet wird. - Status wird nun korrekt aktualisiert, wenn `Messkurve` geklickt wird.
This commit is contained in:
@@ -26,12 +26,6 @@ const ChartSwitcher: React.FC<ChartSwitcherProps> = ({ isOpen, onClose }) => {
|
||||
onClose(); // Originale Schließen-Funktion aufrufen
|
||||
};
|
||||
|
||||
useEffect(() => {
|
||||
if (isOpen) {
|
||||
dispatch(setChartOpen(true));
|
||||
}
|
||||
}, [isOpen]);
|
||||
|
||||
return (
|
||||
<ReactModal
|
||||
isOpen={isOpen}
|
||||
|
||||
@@ -53,7 +53,6 @@ const LoopChartActionBar: React.FC = () => {
|
||||
const lastDate = new Date(jsonData[0].t);
|
||||
dispatch(setVonDatum(firstDate.toISOString().split("T")[0]));
|
||||
dispatch(setBisDatum(lastDate.toISOString().split("T")[0]));
|
||||
dispatch(setChartOpen(true)); // Setze den Schalter auf "geöffnet"
|
||||
}
|
||||
} else {
|
||||
console.error("Erwartetes Array, aber erhalten:", jsonData);
|
||||
|
||||
@@ -24,6 +24,7 @@ import { setActiveMode } from "../../../../redux/slices/chartDataSlice";
|
||||
import LoopMeasurementChart from "./Charts/LoopMeasurementChart/LoopMeasurementChart";
|
||||
import TDRChart from "./Charts/TDRChart/TDRChart";
|
||||
import handleButtonClick from "./kue705FO-Funktionen/handleButtonClick";
|
||||
import { setChartOpen } from "../../../../redux/slices/kabelueberwachungChartSlice";
|
||||
|
||||
const Kue705FO: React.FC<Kue705FOProps> = ({
|
||||
isolationswert,
|
||||
@@ -96,6 +97,7 @@ const Kue705FO: React.FC<Kue705FOProps> = ({
|
||||
|
||||
const handleOpenChartModal = () => {
|
||||
setShowChartModal(true);
|
||||
dispatch(setChartOpen(true));
|
||||
|
||||
if (activeButton === "TDR") {
|
||||
dispatch(setActiveMode("TDR"));
|
||||
|
||||
@@ -6,5 +6,5 @@
|
||||
2: Patch oder Hotfix (Bugfixes oder kleine Änderungen).
|
||||
|
||||
*/
|
||||
const webVersion = "1.6.82";
|
||||
const webVersion = "1.6.83";
|
||||
export default webVersion;
|
||||
|
||||
Reference in New Issue
Block a user