diff --git a/fhem/CHANGED b/fhem/CHANGED index 0e0fe25d7..bf08a3709 100644 --- a/fhem/CHANGED +++ b/fhem/CHANGED @@ -1,5 +1,6 @@ # Add changes at the top of the list. Keep it in ASCII, and 80-char wide. # Do not insert empty lines here, update check depends on it. + - bugfix: 98_WeekdayTimer: fix problem if use more then one holiday2we entry - bugfix: 42_AptToDate: fix Can't call method readFromChild on an undefined value - feature: 93_Log2Syslog: new attribute "exclErrCond" to exclude events from diff --git a/fhem/FHEM/98_WeekdayTimer.pm b/fhem/FHEM/98_WeekdayTimer.pm index 495a37982..6ffab1a30 100644 --- a/fhem/FHEM/98_WeekdayTimer.pm +++ b/fhem/FHEM/98_WeekdayTimer.pm @@ -305,15 +305,17 @@ sub WeekdayTimer_getListeDerTage($$) { my $echteZeit = WeekdayTimer_zeitErmitteln ($now, $stunde, $minute, $sekunde, $relativeDay); #Log 3, "echteZeit---$i---->>>$relativeDay<<<----->".FmtDateTime($echteZeit); ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime($echteZeit); - my $h2we = $attr{global}{holiday2we}; - if($h2we) { - my $ergebnis = fhem("get $h2we ".sprintf("%02d-%02d",$mon+1,$mday),1); - if ($ergebnis ne "none") { - #Log 3, "ergebnis-------$i----->$ergebnis"; - $hdays{$i} = undef if ($d==7); # $we Tag aufnehmen - delete $hdays{$i} if ($d==8); # !$we Tag herausnehmen + + foreach my $h2we (split(',', AttrVal('global', 'holiday2we', ''))) { + if($h2we) { + my $ergebnis = CommandGet(undef,$h2we . ' ' . sprintf("%02d-%02d",$mon+1,$mday)); + if ($ergebnis ne 'none') { + #Log 3, "ergebnis-------$i----->$ergebnis"; + $hdays{$i} = undef if ($d==7); # $we Tag aufnehmen + delete $hdays{$i} if ($d==8); # !$we Tag herausnehmen + } } - } + } } #Log 3, "result------------>" . join (" ", sort keys %hdays);