patch_ic24 #69
2
CHANGED
2
CHANGED
@ -1 +1 @@
|
|||||||
[fix] - ix state
|
[alpha] - extendedstate: state fix if empty or not exists
|
||||||
|
@ -798,8 +798,12 @@ sub WriteReadings {
|
|||||||
#ic24 schedules pause until
|
#ic24 schedules pause until
|
||||||
if ($decode_json->{settings}[$settings]{name} =~ /schedules_paused_until_?\d?$/) {
|
if ($decode_json->{settings}[$settings]{name} =~ /schedules_paused_until_?\d?$/) {
|
||||||
#my $ventil = substr($decode_json->{settings}[$settings]{name}, -1); # => 1 - 6
|
#my $ventil = substr($decode_json->{settings}[$settings]{name}, -1); # => 1 - 6
|
||||||
|
# check if empty, clear scheduling-scheduled_watering_next_start_x
|
||||||
readingsBulkUpdateIfChanged( $hash, 'scheduling-'.$decode_json->{settings}[$settings]{name},
|
readingsBulkUpdateIfChanged( $hash, 'scheduling-'.$decode_json->{settings}[$settings]{name},
|
||||||
$decode_json->{settings}[$settings]{value} );
|
$decode_json->{settings}[$settings]{value} );
|
||||||
|
readingsBulkUpdateIfChanged( $hash, "scheduling-scheduled_watering_next_start_$1", $decode_json->{settings}[$settings]{value}) if ($decode_json->{settings}[$settings]{value} eq '');
|
||||||
|
|
||||||
|
# CommandAttr( undef, $name . " scheduling-scheduled_watering_next_start_") if ($decode_json->{settings}[$settings]{value} eq '' )
|
||||||
}
|
}
|
||||||
|
|
||||||
######
|
######
|
||||||
@ -904,7 +908,7 @@ sub setState {
|
|||||||
$nearst_irrigation = ReadingsVal($name, 'scheduling-scheduled_watering_next_start_'.$_, '')
|
$nearst_irrigation = ReadingsVal($name, 'scheduling-scheduled_watering_next_start_'.$_, '')
|
||||||
if (
|
if (
|
||||||
Time::Piece->strptime( ReadingsVal($name, 'scheduling-scheduled_watering_next_start_'.$_, ''), "%Y-%m-%d %H:%M") < Time::Piece->strptime( $nearst_irrigation, "%Y-%m-%d %H:%M")
|
Time::Piece->strptime( ReadingsVal($name, 'scheduling-scheduled_watering_next_start_'.$_, ''), "%Y-%m-%d %H:%M") < Time::Piece->strptime( $nearst_irrigation, "%Y-%m-%d %H:%M")
|
||||||
&& $has_scheduling
|
&& $has_scheduling && Time::Piece->strptime( ReadingsVal($name, 'scheduling-scheduled_watering_next_start_'.$_, ''), "%Y-%m-%d %H:%M") > Time::Pice->new
|
||||||
)
|
)
|
||||||
} # fi
|
} # fi
|
||||||
}
|
}
|
||||||
|
@ -1,2 +1,2 @@
|
|||||||
UPD 2022-06-24_13:45:33 49520 FHEM/73_GardenaSmartBridge.pm
|
UPD 2022-06-25_13:02:19 49520 FHEM/73_GardenaSmartBridge.pm
|
||||||
UPD 2022-06-24_18:40:19 69564 FHEM/74_GardenaSmartDevice.pm
|
UPD 2022-06-25_16:17:07 70122 FHEM/74_GardenaSmartDevice.pm
|
||||||
|
Loading…
x
Reference in New Issue
Block a user