[Webflysuesk-commits] r65 - in webflysuesk/branches/openlayers-integration: . webflys/src/main/webapp/pages

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Thu Jul 16 09:43:33 CEST 2009


Author: iweinzierl
Date: 2009-07-16 09:43:33 +0200 (Thu, 16 Jul 2009)
New Revision: 65

Modified:
   webflysuesk/branches/openlayers-integration/ChangeLog.txt
   webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/app.jsp
   webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/karte.js
Log:
The time which a request took for fetching one/all jobs is displayed below the map.

Modified: webflysuesk/branches/openlayers-integration/ChangeLog.txt
===================================================================
--- webflysuesk/branches/openlayers-integration/ChangeLog.txt	2009-07-15 15:30:57 UTC (rev 64)
+++ webflysuesk/branches/openlayers-integration/ChangeLog.txt	2009-07-16 07:43:33 UTC (rev 65)
@@ -1,3 +1,9 @@
+2009-07-16  Ingo Weinzierl <ingo.weinzierl at intevation.de>
+
+	* webflys/src/main/webapp/pages/karte.js,
+	  webflys/src/main/webapp/pages/app.jsp: After fetching all/one job, the
+	  time the request took is displayed below the map.
+
 2009-07-15  Ingo Weinzierl <ingo.weinzierl at intevation.de>
 
 	* webflys/src/main/resources/MessageResources_de.properties,

Modified: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/app.jsp
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/app.jsp	2009-07-15 15:30:57 UTC (rev 64)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/app.jsp	2009-07-16 07:43:33 UTC (rev 65)
@@ -200,8 +200,13 @@
         </div><%-- end of map (Wrapper) --%>
 
 
-        <div style="width: 15px; float: left;">&nbsp;</div>
+        <%-- <div style="width: 15px; float: left;">&nbsp;</div> --%>
 
+        <div>
+            <div id="parsing"></div>
+            <div id="jobloading"></div>
+        </div>
+
         <%-- div container to lock the window while ajax requests loading --%>
         <div id="loadingWindow" style="visibility: hidden; background-color: grey; z-index: 9999;">
             <img src="./OpenLayers/theme/default/img/loading.gif"

Modified: webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/karte.js
===================================================================
--- webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/karte.js	2009-07-15 15:30:57 UTC (rev 64)
+++ webflysuesk/branches/openlayers-integration/webflys/src/main/webapp/pages/karte.js	2009-07-16 07:43:33 UTC (rev 65)
@@ -332,6 +332,11 @@
         'xmlns:wfs="http://www.opengis.net/wfs" service="WFS" version="1.0.0"'+ 
         ' maxFeatures="100" outputFormat="GML2"><wfs:Query ' +
         'typeName="usk_gf_ergebnis">';
+        /*
+        'typeName="usk_gf_ergebnis">' +
+        '<wfs:PropertyName>job_id</wfs:PropertyName>'
+        '<wfs:PropertyName>description</wfs:PropertyName>';
+        */
     var filterFoot = '</wfs:Query></wfs:GetFeature>';
     var filterBody;
 
@@ -374,6 +379,8 @@
     var final_filter = filterHead+filterBody+filterFoot;
 
     increaseAjaxCounter();
+    jobDuration = new Date().getTime();
+    parseDuration = new Date().getTime();
     var req = new OpenLayers.Request.POST({
         method  : 'POST',
         url     : 'http://beige.rgb:8080/geoserver/wfs',
@@ -393,6 +400,9 @@
  */
 function addResults(response) {
 
+    $j('#jobloading').html(null);
+    $j('#jobloading').append('Laden eines Ergebnisses dauerte: ' + (new Date().getTime() - jobDuration)/1000 + ' sek');
+
     // read all features of the response
     var features = new OpenLayers.Format.GML().read(response.responseText);
 
@@ -446,7 +456,6 @@
  * response - {XMLHttpResponse} Response of a wfs GetFeatureRequest
  */
 function refreshResultPanel(response) {
-
     // cleaning old results
     $j('#results').html(null);
 
@@ -487,6 +496,9 @@
         var content = '<font color="red">Keine Berechnungsergebnisse für den aktuellen Benutzer vorhanden.</font>';
         $j('#results').append(content);
     }
+
+    $j('#parsing').html(null);
+    $j('#parsing').append('Laden aller Ergebnisse dauerte: ' + (new Date().getTime() - parseDuration)/1000 + ' sek');
     decreaseAjaxCounter();
 }
 



More information about the Webflysuesk-commits mailing list