Add extra conditions to automations and allow for stopping light shutoff if door ajar
This commit is contained in:
parent
1db0d47dff
commit
634c5cd78f
|
@ -119,15 +119,39 @@
|
|||
mode: single
|
||||
- id: '1628551010045'
|
||||
alias: Cascade Turn Off Basement Lights
|
||||
description: If somebody turns off the lights at the stairwell, they prolly dont
|
||||
description: 'If somebody turns off the lights at the stairwell, they prolly dont
|
||||
mind if all the lights beyond that are turned off too.
|
||||
|
||||
|
||||
will not turn off lights if the rear door is ajar'
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: switch.shop_lights
|
||||
to: 'off'
|
||||
condition: []
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: binary_sensor.shop_door_sensor
|
||||
state: 'off'
|
||||
action:
|
||||
- service: homeassistant.turn_off
|
||||
target:
|
||||
entity_id: group.basement
|
||||
mode: single
|
||||
- id: '1628966608945'
|
||||
alias: Reactivate Basemnt footpath lights if door is propped
|
||||
description: Checks if the basement door is propped whenever somebody tries to disable
|
||||
the lights, and, if it is, reactivates all the lights
|
||||
trigger:
|
||||
- platform: state
|
||||
entity_id: switch.shop_lights
|
||||
to: 'off'
|
||||
from: 'on'
|
||||
condition:
|
||||
- condition: state
|
||||
entity_id: binary_sensor.shop_door_sensor
|
||||
state: 'on'
|
||||
action:
|
||||
- service: homeassistant.turn_on
|
||||
target:
|
||||
entity_id: group.basement
|
||||
mode: single
|
||||
|
|
Loading…
Reference in New Issue