Rename key of water level sensor in PEGELONLINE (#97289)

This commit is contained in:
Michael 2023-07-26 22:03:38 +02:00 committed by GitHub
parent 7113db8da4
commit dce9a1b998
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 8 deletions

View file

@ -37,11 +37,11 @@ class PegelOnlineSensorEntityDescription(
SENSORS: tuple[PegelOnlineSensorEntityDescription, ...] = (
PegelOnlineSensorEntityDescription(
key="current_measurement",
translation_key="current_measurement",
key="water_level",
translation_key="water_level",
state_class=SensorStateClass.MEASUREMENT,
fn_native_unit=lambda data: data["current_measurement"].uom,
fn_native_value=lambda data: data["current_measurement"].value,
fn_native_unit=lambda data: data["water_level"].uom,
fn_native_value=lambda data: data["water_level"].value,
icon="mdi:waves-arrow-up",
),
)