Add "school tomorrow" sensor
This commit is contained in:
@ -9,3 +9,12 @@
|
||||
month_is:
|
||||
friendly_name: 'Month is'
|
||||
value_template: "{{ ['January','February','March','April','May','June','August','September','October','November','December'][now().month-1] }}"
|
||||
school_tomorrow:
|
||||
friendly_name: 'School Tomorrow'
|
||||
value_template: >-
|
||||
{%- set test=(as_timestamp(now())+ (86400)) | timestamp_custom("%Y-%m-%d",true) %}
|
||||
{% if states.calendar.kallen_school_days.attributes.start_time == test + " 09:00:00" %}
|
||||
on
|
||||
{% else %}
|
||||
off
|
||||
{% endif %}
|
Reference in New Issue
Block a user