diff gwt-client/src/main/webapp/images/FLYS_Karte_interactive.html @ 6134:69f95a016308

Handle special highlighting for fix analysis.
author Raimund Renkert <rrenkert@intevation.de>
date Thu, 30 May 2013 15:15:02 +0200
parents 0b9f0d37fe6e
children 0a6e486e21c4
line wrap: on
line diff
--- a/gwt-client/src/main/webapp/images/FLYS_Karte_interactive.html	Thu May 30 15:08:29 2013 +0200
+++ b/gwt-client/src/main/webapp/images/FLYS_Karte_interactive.html	Thu May 30 15:15:02 2013 +0200
@@ -2,9 +2,21 @@
   <head>
     <script type="text/javascript">
       var highlighted = "";
+      function stripRiver(name) {
+        var module = getModule();
+        if (module === 'fixanalysis') {
+          if (name.contains('Donau') ||
+              name.contains('Main') ||
+              name.contains('Neckar')) {
+            return name.split(' ')[0];
+          }
+        }
+        return name;
+      }
       function highlight(name){
         unHighlight(highlighted);
         var river;
+        name = stripRiver(name);
         if (availableRiver(name)) {
           river = document.getElementById(name);
         }
@@ -17,10 +29,12 @@
         }
       }
       function highlightList(name) {
-          highlightRiver(name);
+        name = stripRiver(name);
+        highlightRiver(name);
       }
       function unHighlight(name) {
         var river;
+        name = stripRiver(name);
         if (availableRiver(name)) {
           river = document.getElementById(name);
         }
@@ -32,7 +46,8 @@
         }
       }
       function unHighlightList(name) {
-          unHighlightRiver(name);
+        name = stripRiver(name);
+        unHighlightRiver(name);
       }
     </script>
   </head>

http://dive4elements.wald.intevation.org