changeset 4290:6aa8cd8da224

Display observation start time in measurement station tree
author Björn Ricks <bjoern.ricks@intevation.de>
date Mon, 29 Oct 2012 10:04:56 +0100
parents 3fffd7d5d67d
children 6589f1c95101
files flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.java flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.properties flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_de.properties flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_en.properties flys-client/src/main/java/de/intevation/flys/client/client/ui/MeasurementStationTree.java
diffstat 5 files changed, 16 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.java	Mon Oct 29 10:00:17 2012 +0100
+++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.java	Mon Oct 29 10:04:56 2012 +0100
@@ -1070,6 +1070,8 @@
 
     String measurement_station_operator();
 
+    String measurement_station_start_time();
+
     String discharge_timeranges();
 
     String discharge_chart();
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.properties	Mon Oct 29 10:00:17 2012 +0100
+++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants.properties	Mon Oct 29 10:04:56 2012 +0100
@@ -558,3 +558,4 @@
 
 measurement_station_type = Type of Measurement Station
 measurement_station_operator = Operator
+measurement_station_start_time = Observation Start Time
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_de.properties	Mon Oct 29 10:00:17 2012 +0100
+++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_de.properties	Mon Oct 29 10:04:56 2012 +0100
@@ -556,3 +556,4 @@
 
 measurement_station_type = Typ der Messstelle
 measurement_station_operator = Operator
+measurement_station_start_time = Beobachtungsstart
--- a/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_en.properties	Mon Oct 29 10:00:17 2012 +0100
+++ b/flys-client/src/main/java/de/intevation/flys/client/client/FLYSConstants_en.properties	Mon Oct 29 10:04:56 2012 +0100
@@ -557,3 +557,4 @@
 
 measurement_station_type = Type of Measurement Station
 measurement_station_operator = Operator
+measurement_station_start_time = Observation Start Time
--- a/flys-client/src/main/java/de/intevation/flys/client/client/ui/MeasurementStationTree.java	Mon Oct 29 10:00:17 2012 +0100
+++ b/flys-client/src/main/java/de/intevation/flys/client/client/ui/MeasurementStationTree.java	Mon Oct 29 10:04:56 2012 +0100
@@ -1,8 +1,11 @@
 package de.intevation.flys.client.client.ui;
 
+import java.util.Date;
+
 import com.google.gwt.core.client.GWT;
 import com.google.gwt.event.dom.client.ClickEvent;
 import com.google.gwt.event.dom.client.ClickHandler;
+import com.google.gwt.i18n.client.DateTimeFormat;
 import com.google.gwt.i18n.client.NumberFormat;
 import com.google.gwt.user.client.ui.Anchor;
 import com.google.gwt.user.client.ui.DecoratorPanel;
@@ -195,6 +198,14 @@
                 grid.setText(2, 1, moperator);
             }
 
+            DateTimeFormat df = DateTimeFormat.getMediumDateFormat();
+
+            Date starttime = station.getStartTime();
+            if (starttime != null) {
+               grid.setText(3, 0, MSG.measurement_station_start_time());
+               grid.setText(3, 1, df.format(starttime));
+            }
+
             setWidget(grid);
         }
     }

http://dive4elements.wald.intevation.org