-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
expose: allow setting the label for Lock() #2373
Conversation
I remember now why the name is always
Where did you plan to use this label? |
Before it was state instead of keypad lockout, having one is fine but the danfoss uses a few binary sensors so you end up with a few list labeled state, which is confusing. Perhaps keypad_lockout should not be a use Lock() but just Binary() as there is no lock_state for those just one property keypad_lockout that is unlock, lock1(, lock2, lock3, ...) as its a property of the TRV not a seperate Lock device? Switch() has a similar problem, if a device has a multiple Switch() and Lock() exposes it gets confusing. I think switching e.keypad_lockout() away from Lock() seems the better solution here? |
@nurikk what about using the |
It might be better to add a |
Currently we don't have a clear definition of what is |
I think just not using e.Lock() here is the correct way to resolve this... it really isn't a 'Lock' Device but a extra feature on a Climate device. And that should work fine without any changes to the frontend. |
@sjorge what if it is exposed as a switch? |
Same issue zigbee-herdsman-converters/lib/exposes.js Line 68 in fea5c35
|
@sjorge what if we use:
|
That was my suggestion when i wrote
That would indeed fix it. |
nvm :) I copied your line but it has an error in it, state.ALL is the right one, resting... |
Avoid having 'state' label on Climate devices
Thanks! |
For devices with multiple locks or for devices that have a lock function, allow setting of a label.
e.g. for TRV's with a keypad_lockout it is now called keypad_lockout instead of state which is confusing if there are multiple switches/locks all called 'state'