jlvaillant / intellicenter

Home Assistant Integration for Pentair Intellicenter
GNU General Public License v3.0
32 stars 13 forks source link

add number entity for chlorinator output #16

Closed dwradcliffe closed 3 years ago

dwradcliffe commented 3 years ago

Tested locally:

image

jlvaillant commented 3 years ago

David, did you have to add unit_of_measurement all the way to PoolEntity to get that feature? It's pretty specific to sensors and I would rather keep the top class as generic as possible.

dwradcliffe commented 3 years ago

I needed to add it to the number entity here to get the percent to show up properly. We could add it for all the sensors and number classes only but it seemed nice to stop repeating the same code. If you prefer I can move it back though.

From the dev docs, unit_of_measurement is valid for all entities:

Other properties that are common to all entities such as icon, unit_of_measurement, name etc are also applicable.

dwradcliffe commented 3 years ago

Rebased