From 6c768ab562fc1d33e94fa5996f94271341aa765c Mon Sep 17 00:00:00 2001 From: Sven Reifschneider <9088619+neoground@users.noreply.github.com> Date: Fri, 12 Mar 2021 18:03:16 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9E=20Displaying=20missing=20data=20in?= =?UTF-8?q?=20charts=20correctly=20with=20"null"=20value=20on=20all=20page?= =?UTF-8?q?s.=20Disabled=20animations=20due=20to=20this.=20Fixes=20#3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.md | 13 ++++++++----- src/graph_area_config.inc | 3 +++ src/graph_bar_config.inc | 3 +++ src/graph_radar_config.inc | 3 +++ src/index.html.tmpl | 30 +++++++++++++++--------------- src/month.html.tmpl | 30 +++++++++++++++--------------- src/week.html.tmpl | 30 +++++++++++++++--------------- src/year.html.tmpl | 32 ++++++++++++++++---------------- src/yesterday.html.tmpl | 30 +++++++++++++++--------------- 9 files changed, 93 insertions(+), 81 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 158238c..ee1a8fd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,18 +9,21 @@ ### Changed -- Removed graph animations on yearly + monthly archive pages due to - high amount of data which increases performance a lot -- Month charts now show the same layout as year charts in the archive - (full date, better performance) +- Month archive charts now show the same layout as year + charts in the archive (full date, better performance) ### Fixed - Barometer trend can now also be None without throwing an error - Max value of radiation is now shown correctly -- Partly missing data on an archive page will now result in a correct +- Partly missing data on a page will now result in a correct graph with "null" values instead of just ignoring missing data +### Removed + +- Graph animations due to high amount of data / problems with + displaying "null" values which increases performance a lot + ## 1.4 (2021-03-08) diff --git a/src/graph_area_config.inc b/src/graph_area_config.inc index 550ccae..9cf4e11 100644 --- a/src/graph_area_config.inc +++ b/src/graph_area_config.inc @@ -29,6 +29,9 @@ chart: { #include raw "js/vendor/apexcharts/locales/" + $Extras.language + ".json" ], defaultLocale: '$Extras.language', + animations: { + enabled: false + }, }, dataLabels: { enabled: false diff --git a/src/graph_bar_config.inc b/src/graph_bar_config.inc index 65f5115..63c2b2e 100644 --- a/src/graph_bar_config.inc +++ b/src/graph_bar_config.inc @@ -29,6 +29,9 @@ #include raw "js/vendor/apexcharts/locales/" + $Extras.language + ".json" ], defaultLocale: '$Extras.language', + animations: { + enabled: false + }, }, dataLabels: { enabled: false diff --git a/src/graph_radar_config.inc b/src/graph_radar_config.inc index 253994b..721b18b 100644 --- a/src/graph_radar_config.inc +++ b/src/graph_radar_config.inc @@ -28,6 +28,9 @@ #include raw "js/vendor/apexcharts/locales/" + $Extras.language + ".json" ], defaultLocale: '$Extras.language', + animations: { + enabled: false + }, }, dataLabels: { enabled: false diff --git a/src/index.html.tmpl b/src/index.html.tmpl index cf4cebb..3f00ac2 100644 --- a/src/index.html.tmpl +++ b/src/index.html.tmpl @@ -502,7 +502,7 @@ name: "$obs.label.outTemp", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.outTemp.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.outTemp.avg.format(add_label=False, localize=False, None_string="null")], #end for ] }, @@ -510,7 +510,7 @@ name: "$obs.label.dewpoint", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.dewpoint.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.dewpoint.avg.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -539,7 +539,7 @@ name: "$obs.label.windchill", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.windchill.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.windchill.avg.format(add_label=False, localize=False, None_string="null")], #end for ] }, @@ -547,7 +547,7 @@ name: "$obs.label.heatindex", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.heatindex.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.heatindex.avg.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -575,7 +575,7 @@ name: "$obs.label.barometer", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.barometer.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.barometer.avg.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -603,7 +603,7 @@ name: "$obs.label.rain", data: [ #for $record in $span($day_delta=1).spans(interval=3600) - [$record.start.raw, $record.rain.sum.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.rain.sum.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -631,7 +631,7 @@ name: "$obs.label.windSpeed", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.windSpeed.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.windSpeed.max.format(add_label=False, localize=False, None_string="null")], #end for ] }, @@ -639,7 +639,7 @@ name: "$obs.label.windGust", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.windGust.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.windGust.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -667,7 +667,7 @@ name: "$obs.label.outHumidity", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.outHumidity.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.outHumidity.avg.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -808,7 +808,7 @@ name: "$obs.label.UV", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -834,7 +834,7 @@ name: "$obs.label.ET", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -860,7 +860,7 @@ name: "$obs.label.radiation", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -890,7 +890,7 @@ name: "$obs.label.extraTemp1", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -916,7 +916,7 @@ name: "$obs.label.extraTemp2", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -942,7 +942,7 @@ name: "$obs.label.extraTemp3", data: [ #for $record in $span($day_delta=1).spans(interval=600) - [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, localize=False, None_string="null")], #end for ] } diff --git a/src/month.html.tmpl b/src/month.html.tmpl index e895e4d..e4b5e3e 100644 --- a/src/month.html.tmpl +++ b/src/month.html.tmpl @@ -477,13 +477,13 @@ var seriesdata1 = [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.outTemp.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.outTemp.avg.format(add_label=False, $localize=False, None_string="null")], #end for ]; var seriesdata2 = [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.dewpoint.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.dewpoint.avg.format(add_label=False, $localize=False, None_string="null")], #end for ]; @@ -518,13 +518,13 @@ seriesdata1 = [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.windchill.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.windchill.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] seriesdata2 = [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.heatindex.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.heatindex.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -558,7 +558,7 @@ seriesdata1 = [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.barometer.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.barometer.avg.format(add_label=False, $localize=False, None_string="null")], #end for ]; @@ -588,7 +588,7 @@ seriesdata1 = [ #for $record in $span($month_delta=1).spans(interval=86400) - [$record.start.raw, $record.rain.sum.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.rain.sum.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -618,13 +618,13 @@ seriesdata1 = [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.windSpeed.max.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.windSpeed.max.format(add_label=False, $localize=False, None_string="null")], #end for ] seriesdata2 = [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.windGust.max.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.windGust.max.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -658,7 +658,7 @@ seriesdata1 = [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.outHumidity.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.outHumidity.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -813,7 +813,7 @@ name: "$obs.label.UV", data: [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -839,7 +839,7 @@ name: "$obs.label.ET", data: [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -865,7 +865,7 @@ name: "$obs.label.radiation", data: [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -895,7 +895,7 @@ name: "$obs.label.extraTemp1", data: [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] } @@ -921,7 +921,7 @@ name: "$obs.label.extraTemp2", data: [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] } @@ -947,7 +947,7 @@ name: "$obs.label.extraTemp3", data: [ #for $record in $span($month_delta=1).spans(interval=21600) - [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] } diff --git a/src/week.html.tmpl b/src/week.html.tmpl index f2976f4..f6ce80d 100644 --- a/src/week.html.tmpl +++ b/src/week.html.tmpl @@ -476,13 +476,13 @@ var seriesdata1 = [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.outTemp.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.outTemp.avg.format(add_label=False, $localize=False, None_string="null")], #end for ]; var seriesdata2 = [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.dewpoint.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.dewpoint.avg.format(add_label=False, $localize=False, None_string="null")], #end for ]; @@ -517,13 +517,13 @@ seriesdata1 = [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.windchill.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.windchill.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] seriesdata2 = [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.heatindex.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.heatindex.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -557,7 +557,7 @@ seriesdata1 = [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.barometer.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.barometer.avg.format(add_label=False, $localize=False, None_string="null")], #end for ]; @@ -587,7 +587,7 @@ seriesdata1 = [ #for $record in $span($week_delta=1).spans(interval=21600) - [$record.start.raw, $record.rain.sum.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.rain.sum.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -617,13 +617,13 @@ seriesdata1 = [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.windSpeed.max.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.windSpeed.max.format(add_label=False, $localize=False, None_string="null")], #end for ] seriesdata2 = [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.windGust.max.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.windGust.max.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -657,7 +657,7 @@ seriesdata1 = [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.outHumidity.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.outHumidity.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -812,7 +812,7 @@ name: "$obs.label.UV", data: [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -838,7 +838,7 @@ name: "$obs.label.ET", data: [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -864,7 +864,7 @@ name: "$obs.label.radiation", data: [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -894,7 +894,7 @@ name: "$obs.label.extraTemp1", data: [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] } @@ -920,7 +920,7 @@ name: "$obs.label.extraTemp2", data: [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] } @@ -946,7 +946,7 @@ name: "$obs.label.extraTemp3", data: [ #for $record in $span($week_delta=1).spans(interval=14400) - [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] } diff --git a/src/year.html.tmpl b/src/year.html.tmpl index 0a9dec8..39152d5 100644 --- a/src/year.html.tmpl +++ b/src/year.html.tmpl @@ -478,7 +478,7 @@ var seriesdata1 = [ #for $record in $span($year_delta=1).spans(interval=86400) #if $record.outTemp.has_data - [$record.start.raw, $record.outTemp.min.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.outTemp.min.format(add_label=False, $localize=False, None_string="null")], #end if #end for ]; @@ -486,7 +486,7 @@ var seriesdata1a = [ #for $record in $span($year_delta=1).spans(interval=86400) #if $record.outTemp.has_data - [$record.dateTime.raw, $record.outTemp.max.format(add_label=False, $localize=False, None_string="")], + [$record.dateTime.raw, $record.outTemp.max.format(add_label=False, $localize=False, None_string="null")], #end if #end for ]; @@ -494,7 +494,7 @@ var seriesdata2 = [ #for $record in $span($year_delta=1).spans(interval=86400) #if $record.dewpoint.has_data - [$record.start.raw, $record.dewpoint.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.dewpoint.avg.format(add_label=False, $localize=False, None_string="null")], #end if #end for ]; @@ -535,7 +535,7 @@ seriesdata1 = [ #for $record in $span($year_delta=1).spans(interval=86400) #if $record.windchill.has_data - [$record.start.raw, $record.windchill.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.windchill.avg.format(add_label=False, $localize=False, None_string="null")], #end if #end for ] @@ -543,7 +543,7 @@ seriesdata2 = [ #for $record in $span($year_delta=1).spans(interval=86400) #if $record.heatindex.has_data - [$record.start.raw, $record.heatindex.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.heatindex.avg.format(add_label=False, $localize=False, None_string="null")], #end if #end for ] @@ -579,7 +579,7 @@ seriesdata1 = [ #for $record in $span($year_delta=1).spans(interval=86400) #if $record.barometer.has_data - [$record.start.raw, $record.barometer.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.barometer.avg.format(add_label=False, $localize=False, None_string="null")], #end if #end for ]; @@ -610,7 +610,7 @@ seriesdata1 = [ #for $record in $span($year_delta=1).spans(interval=604800) - [$record.start.raw, $record.rain.sum.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.rain.sum.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -640,13 +640,13 @@ seriesdata1 = [ #for $record in $span($year_delta=1).spans(interval=86400) - [$record.start.raw, $record.windSpeed.max.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.windSpeed.max.format(add_label=False, $localize=False, None_string="null")], #end for ] seriesdata2 = [ #for $record in $span($year_delta=1).spans(interval=86400) - [$record.start.raw, $record.windGust.max.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.windGust.max.format(add_label=False, $localize=False, None_string="null")], #end for ] @@ -681,7 +681,7 @@ seriesdata1 = [ #for $record in $span($year_delta=1).spans(interval=86400) #if $record.outHumidity.has_data - [$record.start.raw, $record.outHumidity.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.outHumidity.avg.format(add_label=False, $localize=False, None_string="null")], #end if #end for ] @@ -837,7 +837,7 @@ name: "$obs.label.UV", data: [ #for $record in $span($year_delta=1).spans(interval=86400) - [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -863,7 +863,7 @@ name: "$obs.label.ET", data: [ #for $record in $span($year_delta=1).spans(interval=86400) - [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -889,7 +889,7 @@ name: "$obs.label.radiation", data: [ #for $record in $span($year_delta=1).spans(interval=86400) - [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -919,7 +919,7 @@ name: "$obs.label.extraTemp1", data: [ #for $record in $span($year_delta=1).spans(interval=86400) - [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] } @@ -945,7 +945,7 @@ name: "$obs.label.extraTemp2", data: [ #for $record in $span($year_delta=1).spans(interval=86400) - [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] } @@ -971,7 +971,7 @@ name: "$obs.label.extraTemp3", data: [ #for $record in $span($year_delta=1).spans(interval=86400) - [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, $localize=False, None_string="")], + [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, $localize=False, None_string="null")], #end for ] } diff --git a/src/yesterday.html.tmpl b/src/yesterday.html.tmpl index 7f0566f..e49a834 100644 --- a/src/yesterday.html.tmpl +++ b/src/yesterday.html.tmpl @@ -477,14 +477,14 @@ var seriesdata1 = [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.outTemp.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.outTemp.avg.format(add_label=False, localize=False, None_string="null")], #end for ]; var half_length1 = Math.ceil(seriesdata1.length / 2); var seriesdata2 = [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.dewpoint.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.dewpoint.avg.format(add_label=False, localize=False, None_string="null")], #end for ]; var half_length2 = Math.ceil(seriesdata2.length / 2); @@ -520,14 +520,14 @@ seriesdata1 = [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.windchill.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.windchill.avg.format(add_label=False, localize=False, None_string="null")], #end for ]; half_length1 = Math.ceil(seriesdata1.length / 2); seriesdata2 = [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.heatindex.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.heatindex.avg.format(add_label=False, localize=False, None_string="null")], #end for ]; half_length2 = Math.ceil(seriesdata2.length / 2); @@ -562,7 +562,7 @@ seriesdata1 = [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.barometer.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.barometer.avg.format(add_label=False, localize=False, None_string="null")], #end for ]; half_length1 = Math.ceil(seriesdata1.length / 2); @@ -593,7 +593,7 @@ seriesdata1 = [ #for $record in $span($hour_delta=48).spans(interval=3600) - [$record.start.raw, $record.rain.sum.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.rain.sum.format(add_label=False, localize=False, None_string="null")], #end for ]; half_length1 = Math.ceil(seriesdata1.length / 2); @@ -624,14 +624,14 @@ seriesdata1 = [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.windSpeed.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.windSpeed.max.format(add_label=False, localize=False, None_string="null")], #end for ]; half_length1 = Math.ceil(seriesdata1.length / 2); seriesdata2 = [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.windGust.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.windGust.max.format(add_label=False, localize=False, None_string="null")], #end for ]; half_length2 = Math.ceil(seriesdata2.length / 2); @@ -666,7 +666,7 @@ seriesdata1 = [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.outHumidity.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.outHumidity.avg.format(add_label=False, localize=False, None_string="null")], #end for ]; half_length1 = Math.ceil(seriesdata1.length / 2); @@ -825,7 +825,7 @@ name: "$obs.label.UV", data: [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.UV.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -851,7 +851,7 @@ name: "$obs.label.ET", data: [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.ET.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -877,7 +877,7 @@ name: "$obs.label.radiation", data: [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.radiation.max.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -907,7 +907,7 @@ name: "$obs.label.extraTemp1", data: [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.extraTemp1.avg.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -933,7 +933,7 @@ name: "$obs.label.extraTemp2", data: [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.extraTemp2.avg.format(add_label=False, localize=False, None_string="null")], #end for ] } @@ -959,7 +959,7 @@ name: "$obs.label.extraTemp3", data: [ #for $record in $span($hour_delta=48).spans(interval=600) - [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, localize=False, None_string="")], + [$record.start.raw, $record.extraTemp3.avg.format(add_label=False, localize=False, None_string="null")], #end for ] }