One additional question/issue:
I want a neested āauto-entitiesā query.
Basicly the following is working:
type: custom:auto-entities
card:
type: entities
title: StromkreiszƤhler
filter:
include:
- entity_id: sensor.pulsemeter_*_power
options:
type: custom:auto-entities
card:
type: entities
filter:
include:
- name: 101_*Power
sort:
method: friendly_name
numeric: true
But I need a filtering based on ātemplateā options for both layers.
Iāve tried the following but the second layer is NOT working:
type: custom:auto-entities
card:
type: entities
title: StromkreiszƤhler
state_color: true
filter:
template: |
{% for DEVICE in states.sensor -%}
{%- if DEVICE.entity_id | regex_match('sensor.pulsemeter_.*._power',ignorecase=False) -%}
{{
{
'type': 'custom:fold-entity-row',
'entity': DEVICE.entity_id,
'secondary_info': 'last-changed',
'entities':
[
{
'type': 'custom:multiple-entity-row',
'secondary_info': 'last-changed',
'entity': DEVICE.entity_id,
'show_state': false,
'entities':
[
{
'entity': DEVICE.entity_id.replace('power', 'energy_total'),
'name': 'Total',
'format': 'precision3'
},
{
'entity': DEVICE.entity_id.replace('power', 'energy_yearly'),
'name': 'Yearly',
'format': 'precision3'
},
{
'entity': DEVICE.entity_id.replace('power', 'energy_monthly'),
'name': 'Monthly',
'format': 'precision3'
},
{
'entity': DEVICE.entity_id.replace('power', 'energy_daily'),
'name': 'Daily',
'format': 'precision3'
},
{
'entity': DEVICE.entity_id.replace('power', 'energy_hourly'),
'name': 'Hourly',
'format': 'precision3'
},
{
'entity': DEVICE.entity_id,
'name': 'Power',
'format': 'precision1'
}
]
},
{
'type': 'custom:auto-entities',
'card':
{
'type': 'entities'
},
'filter':
{
'include':
{
'name': '101_BĆ¼ro-Licht-Treppe Power'
}
}
}
]
}
}},
{%- endif -%}
{%- endfor %}
sort:
method: friendly_name
Any help is appreciated.