fix weblink bug by hourly forcast

This commit is contained in:
Marko Oldenburg
2019-01-12 08:18:52 +01:00
parent 4aa222ba33
commit 19f7056f57
3 changed files with 34 additions and 16 deletions

View File

@@ -122,9 +122,11 @@ sub new {
),
cachemaxage => (
( defined( $argsRef->{apioptions} ) and $argsRef->{apioptions} )
? ( ( split( ':', $argsRef->{apioptions} ) )[0] eq 'cachemaxage'
? (
( split( ':', $argsRef->{apioptions} ) )[0] eq 'cachemaxage'
? ( split( ':', $argsRef->{apioptions} ) )[1]
: 900 )
: 900
)
: 900
),
lang => $argsRef->{language},
@@ -340,7 +342,12 @@ sub _ProcessingRetrieveData($$) {
( $data->{list}->[$i]->{dt} ) - 3600
)
),
'day_of_week' => strftime("%a",localtime(( $data->{list}->[$i]->{dt} ) - 3600)),
'day_of_week' => strftime(
"%a",
localtime(
( $data->{list}->[$i]->{dt} ) - 3600
)
),
'temperature' => int(
sprintf(
"%.1f",