mirror of
https://github.com/joBr99/nspanel-lovelace-ui.git
synced 2025-12-22 15:34:26 +01:00
Fix lgtm alerts
This commit is contained in:
@@ -201,7 +201,7 @@ class LuiPagesGen(object):
|
|||||||
state = None
|
state = None
|
||||||
self._send_mqtt_msg(get_screensaver_color_output(theme=theme, state=state))
|
self._send_mqtt_msg(get_screensaver_color_output(theme=theme, state=state))
|
||||||
|
|
||||||
def generate_entities_item(self, item, cardType, temp_unit):
|
def generate_entities_item(self, item, cardType, temp_unit=""):
|
||||||
entityId = item.entityId
|
entityId = item.entityId
|
||||||
icon = item.iconOverride
|
icon = item.iconOverride
|
||||||
colorOverride = item.colorOverride
|
colorOverride = item.colorOverride
|
||||||
@@ -361,7 +361,6 @@ class LuiPagesGen(object):
|
|||||||
value = get_translation(self._locale, f"backend.component.person.state._.{entity.state}")
|
value = get_translation(self._locale, f"backend.component.person.state._.{entity.state}")
|
||||||
elif entityType == "climate":
|
elif entityType == "climate":
|
||||||
entityTypePanel = "text"
|
entityTypePanel = "text"
|
||||||
hvac_action = get_attr_safe(entity, "hvac_action", "")
|
|
||||||
state_value = get_translation(self._locale, f"backend.component.climate.state._.{entity.state}")
|
state_value = get_translation(self._locale, f"backend.component.climate.state._.{entity.state}")
|
||||||
temperature = get_attr_safe(entity, "temperature", "")
|
temperature = get_attr_safe(entity, "temperature", "")
|
||||||
temperature_unit = "°C" if(temp_unit == "celsius") else "°F"
|
temperature_unit = "°C" if(temp_unit == "celsius") else "°F"
|
||||||
|
|||||||
Reference in New Issue
Block a user