From 6d3c69e9677a5ef822dda1dd75300a9c4dc163af Mon Sep 17 00:00:00 2001 From: Joerg Lehmann Date: Fri, 27 Dec 2019 14:22:23 +0100 Subject: [PATCH] localize dates --- snippets/graph.html | 6 +++--- snippets/scales.html | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/snippets/graph.html b/snippets/graph.html index 05b3e1f..edeb7a2 100644 --- a/snippets/graph.html +++ b/snippets/graph.html @@ -2,7 +2,7 @@ {{ if ne .UserName "" }} - + @@ -57,7 +57,7 @@ $(function() { console.log("XXX: "+start.format()); function cb(start, end) { - $('#reportrange span').html(start.format('D. MMM YYYY') + ' - ' + end.format('D. MMM YYYY')); + $('#reportrange span').html(start.locale('de').format('D. MMM YYYY') + ' - ' + end.locale('de').format('D. MMM YYYY')); console.log("A new date selection was made: " + start.format() + ' to ' + end.format()); s_start = start.utc().format('YYYY-MM-DDTHH:mm:ss[Z]'); s_end = end.utc().format('YYYY-MM-DDTHH:mm:ss[Z]'); @@ -263,7 +263,7 @@ if (stop == null) { range = range + "&stop=" + stop; } -$('#reportrange span').html(moment(start).format('D. MMM YYYY') + ' - ' + moment(stop).format('D. MMM YYYY')); +$('#reportrange span').html(moment(start).locale('de').format('D. MMM YYYY') + ' - ' + moment(stop).locale('de').format('D. MMM YYYY')); drawGraph(deveui, alias, property, start, stop, true); diff --git a/snippets/scales.html b/snippets/scales.html index 525d80f..9962366 100644 --- a/snippets/scales.html +++ b/snippets/scales.html @@ -149,7 +149,7 @@ Device ID: {{end}} - +