This commit is contained in:
Home Assistant Version Control committed 2026-10-09 00:21:32 +00:00
1 parent 5ca8693679
commit b82a133046
4 files changed
+299 -6

No files matched your search

+8 -6
View File
@@ -4401,9 +4401,10 @@
- variables:
spool_id: '{% set ns = namespace(id='''') %}{% for e in integration_entities(''spoolman'')
%}{% if e.endswith(''_color_hex'') and (states(e) | replace(''#'', '''') |
lower) == color %}{% set b = e[:-10] %}{% if (states(b) | float(0)) > 0 and
ns.id == '''' %}{% set ns.id = states(b ~ ''_id'') %}{% endif %}{% endif %}{%
endfor %}{{ ns.id }}'
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 }}'
- variables:
helper_idx: '{{ old_slot.split('' '')[-1] if old_slot.split('' '')[-1] in [''1'',
''2'', ''3'', ''4''] else '''' }}'
@@ -4571,9 +4572,10 @@
- variables:
spool_id: '{% set ns = namespace(id='''') %}{% for e in integration_entities(''spoolman'')
%}{% if e.endswith(''_color_hex'') and (states(e) | replace(''#'', '''')
| lower) == color %}{% set b = e[:-10] %}{% if (states(b) | float(0))
> 0 and ns.id == '''' %}{% set ns.id = states(b ~ ''_id'') %}{% endif
%}{% endif %}{% endfor %}{{ ns.id }}'
| 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:
condition: template
value_template: '{{ grams | float > 0 }}'