mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-27 19:53:36 +00:00
Changed weatherforecast to use dt_txt field
This commit is contained in:
parent
cfb39c6364
commit
0e2e8d2e2a
@ -24,6 +24,7 @@ This project adheres to [Semantic Versioning](http://semver.org/).
|
|||||||
- In default module currentWeather/currentWeather.js line 296, 300, self.config.animationSpeed can not be found because the notificationReceived function does not have "self" variable.
|
- In default module currentWeather/currentWeather.js line 296, 300, self.config.animationSpeed can not be found because the notificationReceived function does not have "self" variable.
|
||||||
- Fixed browser-side code to work on the Midori browser.
|
- Fixed browser-side code to work on the Midori browser.
|
||||||
- Fixed issue where heat index was reporting incorrect values in Celsius and Fahrenheit. [#1263](https://github.com/MichMich/MagicMirror/issues/1263)
|
- Fixed issue where heat index was reporting incorrect values in Celsius and Fahrenheit. [#1263](https://github.com/MichMich/MagicMirror/issues/1263)
|
||||||
|
- Fixed weatherforecast to use dt_txt field instead of dt to handle timezones better
|
||||||
|
|
||||||
### Updated
|
### Updated
|
||||||
- Updated Italian translation
|
- Updated Italian translation
|
||||||
|
@ -333,8 +333,8 @@ Module.register("weatherforecast",{
|
|||||||
var forecast = data.list[i];
|
var forecast = data.list[i];
|
||||||
this.parserDataWeather(forecast); // hack issue #1017
|
this.parserDataWeather(forecast); // hack issue #1017
|
||||||
|
|
||||||
var day = moment(forecast.dt, "X").format("ddd");
|
var day = moment(forecast.dt_txt, "YYYY-MM-DD hh:mm:ss").format("ddd");
|
||||||
var hour = moment(forecast.dt, "X").format("H");
|
var hour = moment(forecast.dt_txt, "YYYY-MM-DD hh:mm:ss").format("H");
|
||||||
|
|
||||||
if (day !== lastDay) {
|
if (day !== lastDay) {
|
||||||
var forecastData = {
|
var forecastData = {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user