Show box for Smartthings rise number entity (#141526)

This commit is contained in:
Robert Resch 2025-03-26 22:03:24 +01:00 committed by GitHub
parent 6bfd39f094
commit 3a207e2571
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 5 deletions

View File

@ -4,7 +4,7 @@ from __future__ import annotations
from pysmartthings import Attribute, Capability, Command, SmartThings
from homeassistant.components.number import NumberEntity
from homeassistant.components.number import NumberEntity, NumberMode
from homeassistant.core import HomeAssistant
from homeassistant.helpers.entity_platform import AddConfigEntryEntitiesCallback
@ -32,6 +32,7 @@ class SmartThingsWasherRinseCyclesNumberEntity(SmartThingsEntity, NumberEntity):
_attr_translation_key = "washer_rinse_cycles"
_attr_native_step = 1.0
_attr_mode = NumberMode.BOX
def __init__(self, client: SmartThings, device: FullDevice) -> None:
"""Initialize the instance."""

View File

@ -7,7 +7,7 @@
'capabilities': dict({
'max': 5,
'min': 0,
'mode': <NumberMode.AUTO: 'auto'>,
'mode': <NumberMode.BOX: 'box'>,
'step': 1.0,
}),
'config_entry_id': <ANY>,
@ -44,7 +44,7 @@
'friendly_name': 'Washer Rinse cycles',
'max': 5,
'min': 0,
'mode': <NumberMode.AUTO: 'auto'>,
'mode': <NumberMode.BOX: 'box'>,
'step': 1.0,
'unit_of_measurement': 'cycles',
}),
@ -64,7 +64,7 @@
'capabilities': dict({
'max': 5,
'min': 0,
'mode': <NumberMode.AUTO: 'auto'>,
'mode': <NumberMode.BOX: 'box'>,
'step': 1.0,
}),
'config_entry_id': <ANY>,
@ -101,7 +101,7 @@
'friendly_name': 'Washing Machine Rinse cycles',
'max': 5,
'min': 0,
'mode': <NumberMode.AUTO: 'auto'>,
'mode': <NumberMode.BOX: 'box'>,
'step': 1.0,
'unit_of_measurement': 'cycles',
}),