As the subject says. It looks to me like it isn’t the input_datetime
. In fact unless I am doing something wrong my test persistent notification tells me there is no trigger.entity_id
at all.
In which case is there another way to know what causes the automation to be triggered?
The code below doesn’t get past the condition:
when the time now is the same as either input_datetime.time
trigger:
- platform: time
at: input_datetime.time_1
- platform: time
at: input_datetime.time_2
- platform: state
entity_id: input_boolean.my_boolean
to: 'on'
- condition: template
value_template: >
{% if trigger.entity_id == 'input_datetime.time_1' %}
True
{% elif trigger.entity_id == 'input_datetime.time2' %}
True
{% elif trigger.entity_id == 'input_boolean.my_boolean' %}
True
{% else %}
False
{% endif %}
The datetimes are defined as time only:
input_datetime:
time_1:
has_date: false
has_time: true
2 posts - 2 participants