mirror of
https://github.com/home-assistant/home-assistant.io.git
synced 2025-07-25 10:17:23 +00:00
Change turn on/off lights example to use 'state' (#2555)
The example in the current documentation does not appear to work in hass 0.43.2. A trigger containing 'to' without a 'from' doesn't fire, however one that uses 'state' does.
This commit is contained in:
parent
0c36aa4d8a
commit
ef98610c59
@ -20,7 +20,7 @@ automation:
|
|||||||
trigger:
|
trigger:
|
||||||
platform: state
|
platform: state
|
||||||
entity_id: sensor.motion_sensor
|
entity_id: sensor.motion_sensor
|
||||||
to: 'on'
|
state: 'on'
|
||||||
action:
|
action:
|
||||||
service: homeassistant.turn_on
|
service: homeassistant.turn_on
|
||||||
entity_id: light.kitchen
|
entity_id: light.kitchen
|
||||||
@ -29,7 +29,7 @@ automation:
|
|||||||
trigger:
|
trigger:
|
||||||
platform: state
|
platform: state
|
||||||
entity_id: sensor.motion_sensor
|
entity_id: sensor.motion_sensor
|
||||||
to: 'off'
|
state: 'off'
|
||||||
for:
|
for:
|
||||||
minutes: 10
|
minutes: 10
|
||||||
action:
|
action:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user