Rename tuya base entity module (#126180)
This commit is contained in:
parent
16ac303994
commit
8785a9869e
16 changed files with 15 additions and 15 deletions
|
@ -22,8 +22,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode, DPType
|
||||
from .entity import TuyaEntity
|
||||
|
||||
|
||||
class Mode(StrEnum):
|
||||
|
|
|
@ -17,8 +17,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode
|
||||
from .entity import TuyaEntity
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
|
|
|
@ -11,8 +11,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode
|
||||
from .entity import TuyaEntity
|
||||
|
||||
# All descriptions can be found here.
|
||||
# https://developer.tuya.com/en/docs/iot/standarddescription?id=K9i5ql6waswzq
|
||||
|
|
|
@ -11,8 +11,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode
|
||||
from .entity import TuyaEntity
|
||||
|
||||
# All descriptions can be found here:
|
||||
# https://developer.tuya.com/en/docs/iot/standarddescription?id=K9i5ql6waswzq
|
||||
|
|
|
@ -24,8 +24,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import IntegerTypeData, TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode, DPType
|
||||
from .entity import IntegerTypeData, TuyaEntity
|
||||
|
||||
TUYA_HVAC_TO_HA = {
|
||||
"auto": HVACMode.HEAT_COOL,
|
||||
|
|
|
@ -20,8 +20,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import IntegerTypeData, TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode, DPType
|
||||
from .entity import IntegerTypeData, TuyaEntity
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
|
|
|
@ -21,8 +21,8 @@ from homeassistant.util.percentage import (
|
|||
)
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import EnumTypeData, IntegerTypeData, TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode, DPType
|
||||
from .entity import EnumTypeData, IntegerTypeData, TuyaEntity
|
||||
|
||||
TUYA_SUPPORT_TYPE = {
|
||||
"fs", # Fan
|
||||
|
|
|
@ -17,8 +17,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import IntegerTypeData, TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode, DPType
|
||||
from .entity import IntegerTypeData, TuyaEntity
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
|
|
|
@ -23,8 +23,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import IntegerTypeData, TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode, DPType, WorkMode
|
||||
from .entity import IntegerTypeData, TuyaEntity
|
||||
from .util import remap_value
|
||||
|
||||
|
||||
|
|
|
@ -15,8 +15,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import IntegerTypeData, TuyaEntity
|
||||
from .const import DEVICE_CLASS_UNITS, DOMAIN, TUYA_DISCOVERY_NEW, DPCode, DPType
|
||||
from .entity import IntegerTypeData, TuyaEntity
|
||||
|
||||
# All descriptions can be found here. Mostly the Integer data types in the
|
||||
# default instructions set of each category end up being a number.
|
||||
|
|
|
@ -11,8 +11,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode, DPType
|
||||
from .entity import TuyaEntity
|
||||
|
||||
# All descriptions can be found here. Mostly the Enum data types in the
|
||||
# default instructions set of each category end up being a select.
|
||||
|
|
|
@ -27,7 +27,6 @@ from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
|||
from homeassistant.helpers.typing import StateType
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import ElectricityTypeData, EnumTypeData, IntegerTypeData, TuyaEntity
|
||||
from .const import (
|
||||
DEVICE_CLASS_UNITS,
|
||||
DOMAIN,
|
||||
|
@ -36,6 +35,7 @@ from .const import (
|
|||
DPType,
|
||||
UnitOfMeasurement,
|
||||
)
|
||||
from .entity import ElectricityTypeData, EnumTypeData, IntegerTypeData, TuyaEntity
|
||||
|
||||
|
||||
@dataclass(frozen=True)
|
||||
|
|
|
@ -16,8 +16,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode
|
||||
from .entity import TuyaEntity
|
||||
|
||||
# All descriptions can be found here:
|
||||
# https://developer.tuya.com/en/docs/iot/standarddescription?id=K9i5ql6waswzq
|
||||
|
|
|
@ -17,8 +17,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode
|
||||
from .entity import TuyaEntity
|
||||
|
||||
# All descriptions can be found here. Mostly the Boolean data types in the
|
||||
# default instruction set of each category end up being a Switch.
|
||||
|
|
|
@ -19,8 +19,8 @@ from homeassistant.helpers.dispatcher import async_dispatcher_connect
|
|||
from homeassistant.helpers.entity_platform import AddEntitiesCallback
|
||||
|
||||
from . import TuyaConfigEntry
|
||||
from .base import EnumTypeData, IntegerTypeData, TuyaEntity
|
||||
from .const import TUYA_DISCOVERY_NEW, DPCode, DPType
|
||||
from .entity import EnumTypeData, IntegerTypeData, TuyaEntity
|
||||
|
||||
TUYA_MODE_RETURN_HOME = "chargego"
|
||||
TUYA_STATUS_TO_HA = {
|
||||
|
|
Loading…
Add table
Reference in a new issue