Adjust state class of solaredge lifetime energy sensor (#56825)
parent
f18e4bab60
commit
942db3fcbc
|
@ -2,10 +2,7 @@
|
|||
from datetime import timedelta
|
||||
import logging
|
||||
|
||||
from homeassistant.components.sensor import (
|
||||
STATE_CLASS_MEASUREMENT,
|
||||
STATE_CLASS_TOTAL_INCREASING,
|
||||
)
|
||||
from homeassistant.components.sensor import STATE_CLASS_MEASUREMENT, STATE_CLASS_TOTAL
|
||||
from homeassistant.const import (
|
||||
DEVICE_CLASS_ENERGY,
|
||||
DEVICE_CLASS_POWER,
|
||||
|
@ -42,7 +39,7 @@ SENSOR_TYPES = [
|
|||
json_key="lifeTimeData",
|
||||
name="Lifetime energy",
|
||||
icon="mdi:solar-power",
|
||||
state_class=STATE_CLASS_TOTAL_INCREASING,
|
||||
state_class=STATE_CLASS_TOTAL,
|
||||
native_unit_of_measurement=ENERGY_WATT_HOUR,
|
||||
device_class=DEVICE_CLASS_ENERGY,
|
||||
),
|
||||
|
|
Loading…
Reference in New Issue