Skip to content
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

fix: state of water heater E2 #288

Merged
merged 2 commits into from
Aug 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions custom_components/midea_ac_lan/water_heater.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
from midealocal.devices.c3 import MideaC3Device
from midealocal.devices.cd import DeviceAttributes as CDAttributes
from midealocal.devices.cd import MideaCDDevice
from midealocal.devices.e2 import DeviceAttributes as E2Attributes
from midealocal.devices.e2 import MideaE2Device
from midealocal.devices.e3 import MideaE3Device
from midealocal.devices.e6 import DeviceAttributes as E6Attributes
Expand Down Expand Up @@ -214,6 +215,13 @@ def __init__(self, device: MideaE2Device, entity_key: str) -> None:
"""Midea E2 Water Heater entity init."""
super().__init__(device, entity_key)

@property
def current_operation(self) -> str:
"""Midea E2 Water Heater current operation."""
return str(
STATE_ON if self._device.get_attribute(E2Attributes.power) else STATE_OFF,
)

@property
def min_temp(self) -> float:
"""Midea E2 Water Heater min temperature."""
Expand Down
Loading