Closes #152 - No early moring announcements that are routine.

This commit is contained in:
CCOSTAN 2017-05-03 19:47:07 +00:00
parent 587ade7814
commit 20b0eb0dcc
2 changed files with 7 additions and 1 deletions

View File

@ -14,7 +14,13 @@
for: '00:02:30'
action:
- service: input_boolean.turn_on
- service_template: >
{% set hour=states("sensor.time").split(':')[0] | int %}
{% if hour >= 7 and hour <= 9 and states.input_boolean.school_mode.state == 'on'%}
input_boolean.turn_off
{% else %}
input_boolean.turn_on
{% endif %}
entity_id: input_boolean.alert_mode
- service: script.Voice_notify

View File