Skip to content

Add state and unit to entity names for numeric state helpers - #121

Closed
Ranger2959 wants to merge 1 commit into
andrew-codechimp:mainfrom
Ranger2959:state-unit-in-entity-names
Closed

Ranger2959 wants to merge 1 commit into
andrew-codechimp:mainfrom
Ranger2959:state-unit-in-entity-names

Conversation

@Ranger2959

Copy link
Copy Markdown
Contributor

For numeric state helpers, names in the entity_names attribute now include the current state and unit of measurement in brackets, e.g. Kitchen (sensor.temperature) [23.5°C]

image

For numeric state helpers, names in the entity_names attribute now include the current state and unit of measurement in brackets, e.g. Kitchen (sensor.temperature) [23.5°C]
@andrew-codechimp

Copy link
Copy Markdown
Owner

Hi, this is very specific and would break a lot of peoples automations.
Maybe you could create a template something like this?
{% for entity_id in state_attr("binary_sensor.critical_sensors_unknown", "entities") %}
{{ state_attr(entity_id, "friendly_name") }}: {{ states(entity_id) }} {{ state_attr(entity_id, "unit_of_measurement") or "" }}
{% endfor %}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants