Add entity category to gogogate2 (#58366)

pull/58384/head
J. Nick Koston 2021-10-24 20:59:06 -10:00 committed by GitHub
parent 1a261f7802
commit 837e343c56
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -10,6 +10,7 @@ from homeassistant.config_entries import ConfigEntry
from homeassistant.const import (
DEVICE_CLASS_BATTERY,
DEVICE_CLASS_TEMPERATURE,
ENTITY_CATEGORY_DIAGNOSTIC,
TEMP_CELSIUS,
)
from homeassistant.core import HomeAssistant
@ -51,6 +52,8 @@ async def async_setup_entry(
class DoorSensorBattery(GoGoGate2Entity, SensorEntity):
"""Battery sensor entity for gogogate2 door sensor."""
_attr_entity_category = ENTITY_CATEGORY_DIAGNOSTIC
def __init__(
self,
config_entry: ConfigEntry,