mirror of
https://github.com/home-assistant/core.git
synced 2025-04-23 08:47:57 +00:00
Use read-only options in onkyo options flow (#129929)
This commit is contained in:
parent
29ba140816
commit
7ce74cb5ec
@ -343,7 +343,9 @@ class OnkyoOptionsFlowHandler(OptionsFlow):
|
||||
|
||||
return self.async_create_entry(
|
||||
data={
|
||||
OPTION_VOLUME_RESOLUTION: self.options[OPTION_VOLUME_RESOLUTION],
|
||||
OPTION_VOLUME_RESOLUTION: self.config_entry.options[
|
||||
OPTION_VOLUME_RESOLUTION
|
||||
],
|
||||
OPTION_MAX_VOLUME: user_input[OPTION_MAX_VOLUME],
|
||||
OPTION_INPUT_SOURCES: sources_store,
|
||||
}
|
||||
@ -351,7 +353,7 @@ class OnkyoOptionsFlowHandler(OptionsFlow):
|
||||
|
||||
schema_dict: dict[Any, Selector] = {}
|
||||
|
||||
max_volume: float = self.options[OPTION_MAX_VOLUME]
|
||||
max_volume: float = self.config_entry.options[OPTION_MAX_VOLUME]
|
||||
schema_dict[vol.Required(OPTION_MAX_VOLUME, default=max_volume)] = (
|
||||
NumberSelector(
|
||||
NumberSelectorConfig(min=1, max=100, mode=NumberSelectorMode.BOX)
|
||||
|
Loading…
x
Reference in New Issue
Block a user