adjust sensor name (and tooltip regexp) again
authorgregor herrmann <gregor@toastfreeware.priv.at>
Thu, 9 Aug 2018 12:56:54 +0000 (14:56 +0200)
committergregor herrmann <gregor@toastfreeware.priv.at>
Thu, 9 Aug 2018 12:56:54 +0000 (14:56 +0200)
web/static/seepark_web.js

index a9d4756..2944e90 100644 (file)
@@ -13,9 +13,9 @@ function dayschart(element, title, days, xtickformat) {
                                        '0416a1bab9ff': '0416a1bab9ff_x'
                                },
                                names: {
-                                       '0416a1ac66ff': 'Wassertemperatur in 30 cm Tiefe',
-                                       '0516a207a4ff': 'Wassertemperatur in 50 cm Tiefe',
-                                       '0416a1bab9ff': 'Wassertemperatur in 1 m Tiefe'
+                                       '0416a1ac66ff': 'Wassertemperatur 30cm Tiefe',
+                                       '0516a207a4ff': 'Wassertemperatur 50cm Tiefe',
+                                       '0416a1bab9ff': 'Wassertemperatur 1m Tiefe'
                                },
                                xFormat: '%Y-%m-%d %H:%M:%S',
                                colors: {
@@ -109,7 +109,7 @@ function dayschart(element, title, days, xtickformat) {
                                name: function (name, ratio, id, index) {
                                        var prefix = '';
                                        if (element.substr(0, 7) == 'chart_w') {
-                                               var re = /\d+ c?m/;
+                                               var re = /\d+ ?c?m/;
                                                prefix = 'Wasser ';
                                        } else {
                                                var re = /Luft/;