Isolatioswiderstand Chart abhängig von dropdown menu select name und nicht von Titel

This commit is contained in:
ISA
2025-08-12 12:11:47 +02:00
parent 31a54deb2d
commit b8b5c36a60
7 changed files with 23 additions and 11 deletions

View File

@@ -6,6 +6,6 @@ NEXT_PUBLIC_USE_MOCK_BACKEND_LOOP_START=false
NEXT_PUBLIC_EXPORT_STATIC=false NEXT_PUBLIC_EXPORT_STATIC=false
NEXT_PUBLIC_USE_CGI=false NEXT_PUBLIC_USE_CGI=false
# App-Versionsnummer # App-Versionsnummer
NEXT_PUBLIC_APP_VERSION=1.6.698 NEXT_PUBLIC_APP_VERSION=1.6.699
NEXT_PUBLIC_CPL_MODE=json # json (Entwicklungsumgebung) oder jsSimulatedProd (CPL ->CGI-Interface-Simulator) oder production (CPL-> CGI-Interface Platzhalter) NEXT_PUBLIC_CPL_MODE=json # json (Entwicklungsumgebung) oder jsSimulatedProd (CPL ->CGI-Interface-Simulator) oder production (CPL-> CGI-Interface Platzhalter)

View File

@@ -5,5 +5,5 @@ NEXT_PUBLIC_CPL_API_PATH=/CPL
NEXT_PUBLIC_EXPORT_STATIC=true NEXT_PUBLIC_EXPORT_STATIC=true
NEXT_PUBLIC_USE_CGI=true NEXT_PUBLIC_USE_CGI=true
# App-Versionsnummer # App-Versionsnummer
NEXT_PUBLIC_APP_VERSION=1.6.698 NEXT_PUBLIC_APP_VERSION=1.6.699
NEXT_PUBLIC_CPL_MODE=production NEXT_PUBLIC_CPL_MODE=production

View File

@@ -1,3 +1,8 @@
## [1.6.699] 2025-08-12
- chore(eslint): ignore irregular whitespace in comments (keep rule strict for code)
---
## [1.6.698] 2025-08-12 ## [1.6.698] 2025-08-12
- fetchCableData.mjs - fetchCableData.mjs

View File

@@ -288,7 +288,11 @@ const IsoChartActionBar: React.FC = () => {
<div className="flex items-center space-x-2"> <div className="flex items-center space-x-2">
{/* DateRangePicker für beide Ansichten sichtbar, da Meldungen auch datumsabhängig sind */} {/* DateRangePicker für beide Ansichten sichtbar, da Meldungen auch datumsabhängig sind */}
<div> <div
style={{
visibility: chartTitle === "Messkurve" ? "visible" : "hidden",
}}
>
<DateRangePicker /> <DateRangePicker />
</div> </div>
@@ -362,6 +366,9 @@ const IsoChartActionBar: React.FC = () => {
{/* Daten laden Button lädt je nach Ansicht Messkurve oder Meldungen */} {/* Daten laden Button lädt je nach Ansicht Messkurve oder Meldungen */}
<button <button
style={{
visibility: chartTitle === "Messkurve" ? "visible" : "hidden",
}}
onClick={handleFetchData} onClick={handleFetchData}
className="px-4 py-1 bg-littwin-blue text-white rounded text-sm" className="px-4 py-1 bg-littwin-blue text-white rounded text-sm"
> >

View File

@@ -180,9 +180,7 @@ const IsoChartView: React.FC<IsoChartViewProps> = ({
}} }}
> >
<div className="flex justify-between items-center mb-2 pr-24"> <div className="flex justify-between items-center mb-2 pr-24">
<h3 className="text-lg font-semibold"> <h3 className="text-lg font-semibold">Isolationswiderstand</h3>
{chartTitle === "Messkurve" ? "Isolationswiderstand" : "Meldungen"}
</h3>
<Listbox <Listbox
value={chartTitle} value={chartTitle}
onChange={(value: "Messkurve" | "Meldungen") => onChange={(value: "Messkurve" | "Meldungen") =>
@@ -191,7 +189,9 @@ const IsoChartView: React.FC<IsoChartViewProps> = ({
> >
<div className="relative w-40"> <div className="relative w-40">
<Listbox.Button className="w-full border px-3 py-1 rounded text-left bg-white flex justify-between items-center text-sm"> <Listbox.Button className="w-full border px-3 py-1 rounded text-left bg-white flex justify-between items-center text-sm">
<span>{chartTitle}</span> <span>
{chartTitle === "Meldungen" ? "Meldungen" : "Messkurve"}
</span>
<svg <svg
className="w-5 h-5 text-gray-400" className="w-5 h-5 text-gray-400"
viewBox="0 0 20 20" viewBox="0 0 20 20"
@@ -225,7 +225,7 @@ const IsoChartView: React.FC<IsoChartViewProps> = ({
}` }`
} }
> >
{option} {option === "Meldungen" ? "Meldungen" : "Messkurve"}
</Listbox.Option> </Listbox.Option>
))} ))}
</Listbox.Options> </Listbox.Options>

4
package-lock.json generated
View File

@@ -1,12 +1,12 @@
{ {
"name": "cpl-v4", "name": "cpl-v4",
"version": "1.6.698", "version": "1.6.699",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "cpl-v4", "name": "cpl-v4",
"version": "1.6.698", "version": "1.6.699",
"dependencies": { "dependencies": {
"@fontsource/roboto": "^5.1.0", "@fontsource/roboto": "^5.1.0",
"@headlessui/react": "^2.2.4", "@headlessui/react": "^2.2.4",

View File

@@ -1,6 +1,6 @@
{ {
"name": "cpl-v4", "name": "cpl-v4",
"version": "1.6.698", "version": "1.6.699",
"private": true, "private": true,
"scripts": { "scripts": {
"dev": "next dev", "dev": "next dev",