[alpha] extemdedState - fix state
This commit is contained in:
@ -928,7 +928,7 @@ sub setState {
|
||||
## find nearst timestamp
|
||||
#$has_scheduling = 1 if ( ReadingsVal($name, 'scheduling-schedules_paused_until_'.$_ , '') ne '2038-01-18T00:00:00.000Z' && ReadingsVal($name, 'scheduling-schedules_paused_until_'.$_ , '') eq '' );
|
||||
$has_scheduling = 1 if ( ReadingsVal($name, 'scheduling-schedules_paused_until_'.$_ , '') eq '' );
|
||||
$longest_duration = ReadingsVal( $name, "watering-watering_timer_".$_."_duration", 0 ) if (
|
||||
$longest_duration = ReadingsVal( $name, "watering-watering_timer_".$_."_irrigation_left", 0 ) if (
|
||||
( ReadingsVal( $name, "watering-watering_timer_".$_."_duration", 0 ) =~ m{\A[1-9]([0-9]+)?\z}xms
|
||||
&& ReadingsVal( $name, "watering-watering_timer_".$_."_duration", 0 ) > 0
|
||||
&& ReadingsVal( $name, "watering-watering_timer_".$_."_duration", 0 ) > $longest_duration ) );
|
||||
|
Reference in New Issue
Block a user