-
I have a setting in fp.yaml:- entity: sensor.me_kl_current_consumption
tap_action: false
state_action:
service: floorplan.class_set
service_data:
class: >-
${(parseFloat(entity.state) > 1.4) ? "switch-on" :
"switch-off"}
|
Beta Was this translation helpful? Give feedback.
Answered by
OzGav
Jul 20, 2024
Replies: 1 comment 3 replies
-
You can nest the shorthand if then else syntax like this
|
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Yes I think that should work. Edit actually swap the > sign for <