Ero sivun ”Widget:XJwCharts” versioiden välillä
Järvi-meriwikistä
Rivi 122: | Rivi 122: | ||
var firstW = 3000; lastW = 0; | var firstW = 3000; lastW = 0; | ||
var firstF = 500; var lastB = -500; | var firstF = 500; var lastB = -500; | ||
− | //var firstCd = new Date( now.getFullyear(), 11, 31 ); var lastCd = new Date(); | + | //var firstCd = new Date( memo.now.getFullyear(), 11, 31 ); var lastCd = new Date(); |
− | var cnewyear = new Date( now.getFullYear()+1, 0, 1 ); | + | var cnewyear = new Date( memo.now.getFullYear()+1, 0, 1 ); |
for ( var o in memo.jw.obsList ) { | for ( var o in memo.jw.obsList ) { | ||
Rivi 133: | Rivi 133: | ||
if ( obs.obsdatetime.getMonth() > -1 && obs.obsdatetime.getMonth() < 8 ) { | if ( obs.obsdatetime.getMonth() > -1 && obs.obsdatetime.getMonth() < 8 ) { | ||
obs.winter = obs.obsdatetime.getFullYear()-1; | obs.winter = obs.obsdatetime.getFullYear()-1; | ||
− | obs.comparedate = new Date( now.getFullYear()+1, obs.obsdatetime.getMonth(), obs.obsdatetime.getDate() ); | + | obs.comparedate = new Date( memo.now.getFullYear()+1, obs.obsdatetime.getMonth(), obs.obsdatetime.getDate() ); |
} else { | } else { | ||
obs.winter = obs.obsdatetime.getFullYear(); | obs.winter = obs.obsdatetime.getFullYear(); | ||
− | obs.comparedate = new Date( now.getFullYear(), obs.obsdatetime.getMonth(), obs.obsdatetime.getDate() ); | + | obs.comparedate = new Date( memo.now.getFullYear(), obs.obsdatetime.getMonth(), obs.obsdatetime.getDate() ); |
} | } | ||