diff --git a/custom_components/smartevse/number.py b/custom_components/smartevse/number.py index 48004d9..d5e05d6 100644 --- a/custom_components/smartevse/number.py +++ b/custom_components/smartevse/number.py @@ -84,5 +84,4 @@ async def async_set_native_value(self, value: float) -> None: def write(self): res = requests.post(self.api_url, {}) if res.status_code == 200: - self.schedule_update_ha_state() - + self.schedule_update_ha_state(force_refresh=True) diff --git a/custom_components/smartevse/select.py b/custom_components/smartevse/select.py index 9aaf5c3..a2c2586 100644 --- a/custom_components/smartevse/select.py +++ b/custom_components/smartevse/select.py @@ -89,4 +89,4 @@ def write(self, option): res = requests.post(self.api_url, {}) if res.status_code == 200: self._attr_current_option = option - self.schedule_update_ha_state() + self.schedule_update_ha_state(force_refresh=True) diff --git a/custom_components/smartevse/switch.py b/custom_components/smartevse/switch.py index 87d9292..5d63a61 100644 --- a/custom_components/smartevse/switch.py +++ b/custom_components/smartevse/switch.py @@ -72,4 +72,4 @@ async def async_turn_off(self, **kwargs: Any) -> None: def write(self): res = requests.post(self.api_url, {}) if res.status_code == 200: - self.schedule_update_ha_state() + self.schedule_update_ha_state(force_refresh=True)