automations.yaml, zigbee2mqtt/state.json

This commit is contained in:
Home Assistant Version Control committed 2026-10-15 12:49:47 +00:00
1 parent 597166a690
commit e6b1b4fac8
2 files changed
+19 -19

No files matched your search

+5 -5
View File
@@ -4426,11 +4426,11 @@
'', ''_'')) ~ ''_color'') | replace(''#'', '''') | lower }}'
- variables:
spool_id: '{% set ns = namespace(id='''') %}{% for e in integration_entities(''spoolman'')
%}{% if e.endswith(''_color_hex'') and (states(e) | replace(''#'', '''') |
lower) == color and (state_attr(e[:-10], ''location'') | default('''', true)
| lower) == ''cfs lite'' %}{% set b = e[:-10] %}{% if (states(b) | float(0))
> 0 and ns.id == '''' %}{% set ns.id = states(b ~ ''_id'') %}{% endif %}{%
endif %}{% endfor %}{{ ns.id }}'
%}{% if e.endswith(''_color_hex'') and (state_attr(e[:-10], ''location'') |
default('''', true) | lower) == (''cfs lite '' ~ old_slot.split(''_'')[-1])
%}{% set b = e[:-10] %}{% if (states(b) | float(0)) > 0 and ns.id == ''''
%}{% set ns.id = states(b ~ ''_id'') %}{% endif %}{% endif %}{% endfor %}{{
ns.id }}'
- variables:
helper_idx: '{{ old_slot.split(''_'')[-1] if old_slot.split(''_'')[-1] in [''1'',
''2'', ''3'', ''4''] else '''' }}'