98_WeekdayTimer.pm: enable multiple holiday2we-devices for also non-holiday TYPE devices

git-svn-id: https://svn.fhem.de/fhem/trunk/fhem@19043 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
Beta-User 2019-03-26 18:08:05 +00:00
parent fb1d0f6cdf
commit 89e6e8a6b9

View File

@ -308,7 +308,14 @@ sub WeekdayTimer_getListeDerTage($$) {
foreach my $h2we (split(',', AttrVal('global', 'holiday2we', ''))) {
if($h2we) {
my $ergebnis = CommandGet(undef,$h2we . ' ' . sprintf("%02d-%02d",$mon+1,$mday));
my $ergebnis = 'none';
if (InternalVal($h2we, 'TYPE', '') eq "holiday") {
$ergebnis = CommandGet(undef,$h2we . ' ' . sprintf("%02d-%02d",$mon+1,$mday));
} elsif ($wday==$nowWday ){
$ergebnis = "is_true" if IsWe();
}elsif ( $wday==$nowWday+1){
$ergebnis = "is_true" if IsWe("tomorrow");
}
if ($ergebnis ne 'none') {
#Log 3, "ergebnis-------$i----->$ergebnis";
$hdays{$i} = undef if ($d==7); # $we Tag aufnehmen