diff client/src/store/fairway.js @ 2540:3c17d401fbd4

client: cross profiles: moved waterlevel select to Profiles dialog aaaand also switched to the popup component as confirmation mechanism for deleting saved profiles
author Markus Kottlaender <markus@intevation.de>
date Thu, 07 Mar 2019 15:19:16 +0100
parents 123e7f43b676
children 9bf6b767a56a
line wrap: on
line diff
--- a/client/src/store/fairway.js	Thu Mar 07 14:59:03 2019 +0100
+++ b/client/src/store/fairway.js	Thu Mar 07 15:19:16 2019 +0100
@@ -78,10 +78,10 @@
       // https://vuejs.org/v2/guide/reactivity.html#Change-Detection-Caveats
       const entry = {
         date: when,
-        vaule: value
+        value: value
       };
-      Vue.set(state.waterLevels, when, entry);
-      if (state.selectedWaterLevel === "") state.selectedWaterLevel = entry;
+      state.waterLevels = { [when]: entry };
+      state.selectedWaterLevel = entry;
       Vue.set(state.currentProfile, surveyDate, {
         points: result.points,
         length: result.lengthPolyLine