Skip to content

[FR]: #124

Description

@Velc84

Feature request to improve the temperature templates.

When I switch off the climate control, target temperature control should be disabled and state should show "off" instead of target temperature value. currently writing something like:
target_temperature_template: > {% set temp = state_attr('water_heater.boiler', 'temperature') %} {% if temp is none %} {{ none }} {% else %} {{ temp | float }} {% endif %}

will not work and the last value under attributes of "temperature" is still shown

if I do some sketchy code like:
target_temperature_template: > {% set mode = state_attr('water_heater.boiler', 'operation_mode') | default("unknown") %} {% if mode in ("off", "unavailable", "unknown") %} {% set temperature = "" | float %} {% else %} {{ state_attr('water_heater.boiler', 'temperature') | float }} {% endif %}

then the temperature attribute value will show null, but in log i get error messages

My concern is if I switch the control off and try to adjust the setpoint in off condition, i get error messages in the log an on the GUI

Would be nice to have a off condition, where temperature attribute gets value of null without any log errors

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions