2020 :height =" stepperHeightVh"
2121 :all-visible-messstellen =" allVisibleMessstellen"
2222 :preset-data =" presetData"
23+ @reset-chart =" resetChart"
2324 />
2425 <v-spacer />
2526 <v-card-actions >
@@ -97,8 +98,16 @@ import type MessstelleAuswertungIdDTO from "@/types/messstelle/auswertung/Messst
9798import type MessstelleAuswertungOptionsDTO from " @/types/messstelle/auswertung/MessstelleAuswertungOptionsDTO" ;
9899import type LadeZaehldatenSteplineDTO from " @/types/zaehlung/zaehldaten/LadeZaehldatenSteplineDTO" ;
99100
100- import { cloneDeep , head , isEmpty , isNil , toArray , valuesIn } from " lodash" ;
101- import { computed , onMounted , ref } from " vue" ;
101+ import {
102+ cloneDeep ,
103+ head ,
104+ isEmpty ,
105+ isEqual ,
106+ isNil ,
107+ toArray ,
108+ valuesIn ,
109+ } from " lodash" ;
110+ import { computed , onMounted , ref , watch } from " vue" ;
102111import { useDisplay } from " vuetify" ;
103112
104113import { ApiError , Levels } from " @/api/error" ;
@@ -120,8 +129,6 @@ import { useReportTools } from "@/util/ReportTools";
120129const NUMBER_OF_MAX_XAXIS_ELEMENTS_TO_SHOW = 96 ;
121130const NUMBER_OF_MAX_MST_TO_SHOW = 10 ;
122131
123- const minWidth = 600 ;
124-
125132const reportTools = useReportTools ();
126133const display = useDisplay ();
127134const downloadUtils = useDownloadUtils ();
@@ -157,6 +164,28 @@ onMounted(() => {
157164 auswertungLoaded .value = presetData .value ;
158165});
159166
167+ watch (
168+ auswertungsOptions ,
169+ () => {
170+ resetChart ();
171+ },
172+ { deep: true , immediate: true }
173+ );
174+
175+ function resetChart() {
176+ if (
177+ auswertungLoaded .value &&
178+ ! isEqual (
179+ auswertungsOptions .value ,
180+ gesamtauswertungStore .getAuswertungMessstelleOptions
181+ )
182+ ) {
183+ zaehldatenMessstellen .value =
184+ DefaultObjectCreator .createDefaultLadeZaehldatenSteplineDTO ();
185+ auswertungLoaded .value = false ;
186+ }
187+ }
188+
160189const textForNonShownDiagram = computed (() => {
161190 const text = [];
162191 if (! isNumberOfChosenMstShowable .value ) {
0 commit comments