Hopeful fix for #99
This commit is contained in:
@ -209,23 +209,12 @@
|
|||||||
description: Runs when family arrives at home
|
description: Runs when family arrives at home
|
||||||
trigger:
|
trigger:
|
||||||
- platform: state
|
- platform: state
|
||||||
entity_id: group.adults
|
entity_id: sensor.adults_home_fix
|
||||||
not_from:
|
not_from: broken
|
||||||
- unknown
|
|
||||||
- unavailable
|
|
||||||
to: home
|
to: home
|
||||||
condition:
|
condition:
|
||||||
- condition: not
|
- condition: not
|
||||||
conditions:
|
conditions:
|
||||||
- condition: state
|
|
||||||
entity_id: person.tony_stork
|
|
||||||
state: unknown
|
|
||||||
- condition: state
|
|
||||||
entity_id: person.christina_stork
|
|
||||||
state: unknown
|
|
||||||
- condition: state
|
|
||||||
entity_id: group.family
|
|
||||||
state: unknown
|
|
||||||
- condition: state
|
- condition: state
|
||||||
entity_id: binary_sensor.internet
|
entity_id: binary_sensor.internet
|
||||||
state: 'off'
|
state: 'off'
|
||||||
@ -248,9 +237,7 @@
|
|||||||
trigger:
|
trigger:
|
||||||
- platform: state
|
- platform: state
|
||||||
entity_id: group.adults
|
entity_id: group.adults
|
||||||
not_from:
|
not_from: broken
|
||||||
- unknown
|
|
||||||
- unavailable
|
|
||||||
to: not_home
|
to: not_home
|
||||||
condition:
|
condition:
|
||||||
- condition: state
|
- condition: state
|
||||||
@ -258,15 +245,6 @@
|
|||||||
state: 'off'
|
state: 'off'
|
||||||
- condition: not
|
- condition: not
|
||||||
conditions:
|
conditions:
|
||||||
- condition: state
|
|
||||||
entity_id: person.tony_stork
|
|
||||||
state: unknown
|
|
||||||
- condition: state
|
|
||||||
entity_id: person.christina_stork
|
|
||||||
state: unknown
|
|
||||||
- condition: state
|
|
||||||
entity_id: group.family
|
|
||||||
state: unknown
|
|
||||||
- condition: state
|
- condition: state
|
||||||
entity_id: binary_sensor.internet
|
entity_id: binary_sensor.internet
|
||||||
state: 'off'
|
state: 'off'
|
||||||
|
@ -154,6 +154,44 @@ binary_sensor:
|
|||||||
sensor:
|
sensor:
|
||||||
- platform: template
|
- platform: template
|
||||||
sensors:
|
sensors:
|
||||||
|
adults_home_fix:
|
||||||
|
friendly_name: "Adults Home Fix"
|
||||||
|
unique_id: c63364fb-c3cb-44a6-8fba-5d63e3f9c981
|
||||||
|
value_template: >
|
||||||
|
{% if states('person.tony_stork') in ['unknown','unavailable'] or states('person.christina_stork') in ['unknown','unavailable'] %}
|
||||||
|
broken
|
||||||
|
{% elif is_state('group.adults','home') %}
|
||||||
|
home
|
||||||
|
{% elif is_state('group.adults','not_home') %}
|
||||||
|
not_home
|
||||||
|
{% endif %}
|
||||||
|
icon_template: >
|
||||||
|
{% if states('person.tony_stork') in ['unknown','unavailable'] or states('person.christina_stork') in ['unknown','unavailable'] %}
|
||||||
|
mdi:alert-circle
|
||||||
|
{% elif is_state('group.adults','home') %}
|
||||||
|
mdi:home
|
||||||
|
{% elif is_state('group.adults','not_home') %}
|
||||||
|
mdi:home-outline
|
||||||
|
{% endif %}
|
||||||
|
family_home_fix:
|
||||||
|
friendly_name: "Family Home Fix"
|
||||||
|
unique_id: f27a1a56-0c7e-46ee-9f21-a48cc1a0421c
|
||||||
|
value_template: >
|
||||||
|
{% if states('person.tony_stork') in ['unknown','unavailable'] or states('person.christina_stork') in ['unknown','unavailable'] or states('person.kallen_stork') in ['unknown','unavailable'] %}
|
||||||
|
broken
|
||||||
|
{% elif is_state('group.family','home') %}
|
||||||
|
home
|
||||||
|
{% elif is_state('group.family','not_home') %}
|
||||||
|
not_home
|
||||||
|
{% endif %}
|
||||||
|
icon_template: >
|
||||||
|
{% if states('person.tony_stork') in ['unknown','unavailable'] or states('person.christina_stork') in ['unknown','unavailable'] or states('person.kallen_stork') in ['unknown','unavailable'] %}
|
||||||
|
mdi:alert-circle
|
||||||
|
{% elif is_state('group.family','home') %}
|
||||||
|
mdi:home
|
||||||
|
{% elif is_state('group.family','not_home') %}
|
||||||
|
mdi:home-outline
|
||||||
|
{% endif %}
|
||||||
tony_location:
|
tony_location:
|
||||||
friendly_name: "Tony"
|
friendly_name: "Tony"
|
||||||
unique_id: 2620a9d0-01f0-4af4-8438-a0c860735aab
|
unique_id: 2620a9d0-01f0-4af4-8438-a0c860735aab
|
||||||
|
Reference in New Issue
Block a user