You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to use templating within a call-service action to give a value in the service_data that's based on a current state.
I don't know if it's just that I'm not doing something right, or whether this just isn't supported, but I'd like to supply either the value "heat" (if the current state is "auto") or "auto" (if it's currently "heat"). The default toggle action for this entity is to switch between "heat" and "off" but I don't want it "off" - it should follow the schedule (auto), unless it's turned on ad-hoc (heat) when needed....
Currently when the button is clicked, I get a message saying there's an invalid value for data['hvac_mode'] and that the needs to be one of the following "heat", "cool", "auto", "off", etc. I've tried removing the quotes around the values with no change.
I'm a developer, but new to Home Assistant, and I'm not sure how to debug this to see the actual payload being sent.
Any advice or suggestions for how to get around this issue another way are happily received
The text was updated successfully, but these errors were encountered:
I haven't delved into the wonder world of javascript and I know this comes a bit late, but as a workaround, you could have two conditional buttons:
# state = heatconditional:
conditions:
entity: climate.officestate: "heat"card:
# add the button for if the state is "heat"# state = autoconditional:
conditions:
entity: climate.officestate: "auto"card:
# add the button for if the state is "auto"
Also, as a note, I'm not sure if it'll necessarily be the state you're looking for or the state attribute value of hvac_mode.
I'm trying to use templating within a call-service action to give a value in the service_data that's based on a current state.
I don't know if it's just that I'm not doing something right, or whether this just isn't supported, but I'd like to supply either the value "heat" (if the current state is "auto") or "auto" (if it's currently "heat"). The default toggle action for this entity is to switch between "heat" and "off" but I don't want it "off" - it should follow the schedule (auto), unless it's turned on ad-hoc (heat) when needed....
Currently when the button is clicked, I get a message saying there's an invalid value for data['hvac_mode'] and that the needs to be one of the following "heat", "cool", "auto", "off", etc. I've tried removing the quotes around the values with no change.
I'm a developer, but new to Home Assistant, and I'm not sure how to debug this to see the actual payload being sent.
Any advice or suggestions for how to get around this issue another way are happily received
The text was updated successfully, but these errors were encountered: