Remove Workday YAML configuration (#94102)
Remove platform yaml from workday
This commit is contained in:
parent
4d3db038d6
commit
f2cf92050a
5 changed files with 2 additions and 297 deletions
|
@ -155,33 +155,6 @@ class WorkdayConfigFlow(ConfigFlow, domain=DOMAIN):
|
|||
"""Get the options flow for this handler."""
|
||||
return WorkdayOptionsFlowHandler(config_entry)
|
||||
|
||||
async def async_step_import(self, config: dict[str, Any]) -> FlowResult:
|
||||
"""Import a configuration from config.yaml."""
|
||||
|
||||
abort_match = {
|
||||
CONF_COUNTRY: config[CONF_COUNTRY],
|
||||
CONF_EXCLUDES: config[CONF_EXCLUDES],
|
||||
CONF_OFFSET: config[CONF_OFFSET],
|
||||
CONF_WORKDAYS: config[CONF_WORKDAYS],
|
||||
CONF_ADD_HOLIDAYS: config[CONF_ADD_HOLIDAYS],
|
||||
CONF_REMOVE_HOLIDAYS: config[CONF_REMOVE_HOLIDAYS],
|
||||
CONF_PROVINCE: config.get(CONF_PROVINCE),
|
||||
}
|
||||
new_config = config.copy()
|
||||
new_config[CONF_PROVINCE] = config.get(CONF_PROVINCE)
|
||||
LOGGER.debug("Importing with %s", new_config)
|
||||
|
||||
self._async_abort_entries_match(abort_match)
|
||||
|
||||
self.data[CONF_NAME] = config.get(CONF_NAME, DEFAULT_NAME)
|
||||
self.data[CONF_COUNTRY] = config[CONF_COUNTRY]
|
||||
LOGGER.debug(
|
||||
"No duplicate, next step with name %s for country %s",
|
||||
self.data[CONF_NAME],
|
||||
self.data[CONF_COUNTRY],
|
||||
)
|
||||
return await self.async_step_options(user_input=new_config)
|
||||
|
||||
async def async_step_user(
|
||||
self, user_input: dict[str, Any] | None = None
|
||||
) -> FlowResult:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue