diff client/src/store/gauges.js @ 2775:2feb9f8f6c66

client: waterlevel diagram: implemented display of forecast data
author Markus Kottlaender <markus@intevation.de>
date Fri, 22 Mar 2019 13:00:10 +0100
parents f0846d200ce4
children 2b79c0871138
line wrap: on
line diff
--- a/client/src/store/gauges.js	Fri Mar 22 12:45:53 2019 +0100
+++ b/client/src/store/gauges.js	Fri Mar 22 13:00:10 2019 +0100
@@ -17,6 +17,8 @@
 
 let dateFrom = new Date();
 dateFrom.setDate(dateFrom.getDate() - 30);
+let dateTo = new Date();
+dateTo.setDate(dateTo.getDate() + 3);
 
 const init = () => {
   return {
@@ -26,7 +28,7 @@
     meanWaterlevels: [],
     nashSutcliffe: null,
     dateFrom: dateFrom,
-    dateTo: new Date()
+    dateTo: dateTo
   };
 };
 
@@ -163,27 +165,6 @@
         })
           .then(response => {
             commit("nashSutcliffe", response.data);
-            // dest data
-            // commit("nashSutcliffe", {
-            //   when: "2019-03-20T10:38:05.687",
-            //   coeffs: [
-            //     {
-            //       value: 0.814,
-            //       samples: 18,
-            //       hours: 24
-            //     },
-            //     {
-            //       value: 0.319,
-            //       samples: 36,
-            //       hours: 48
-            //     },
-            //     {
-            //       value: -0.20546757,
-            //       samples: 54,
-            //       hours: 72
-            //     }
-            //   ]
-            // });
             resolve(response.data);
           })
           .catch(error => {