[Dive4elements-commits] [PATCH] flys/issue1183: Default from date form fields (fix)

Wald Commits scm-commit at wald.intevation.org
Mon Mar 25 10:08:59 CET 2013


# HG changeset patch
# User Felix Wolfsteller <felix.wolfsteller at intevation.de>
# Date 1364202994 -3600
# Node ID d449b502602bcaa5b709d16f4955af45e0632324
# Parent  6ff45b7b834c555d709e363be5a62cc5b81b871c
flys/issue1183: Default from date form fields (fix).

diff -r 6ff45b7b834c -r d449b502602b flys-client/src/main/java/de/intevation/flys/client/client/ui/GaugeTimeRangePanel.java
--- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/GaugeTimeRangePanel.java	Fri Mar 22 12:33:28 2013 +0100
+++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/GaugeTimeRangePanel.java	Mon Mar 25 10:16:34 2013 +0100
@@ -124,18 +124,15 @@
     }
 
 
+    /** Put defaults in form. */
     @Override
     protected void initDefaults(DataList dataList) {
         RangeData data = findRangeData(dataList);
 
-        if(data != null) {
-            GWT.log("data: " + data);
+        if (data != null) {
+            dateRange.setFromDate(new Date((Long)data.getLower()));
         }
 
-        // TODO understand why this does get set too late
-        if (getMaxLower() != null)
-            dateRange.setFromDate(new Date((Long)getMaxLower()));
-
         dateRange.setToDate(new Date());
     }
 


More information about the Dive4elements-commits mailing list