From 95cebdbbe35dcb04339b940e929fe5db0094721a Mon Sep 17 00:00:00 2001 From: Andrew Reiter Date: Mon, 24 Jun 2024 14:57:28 -0400 Subject: [PATCH] Remove boolean param energy_date_selection and instead activate when collection_key is specified --- src/panels/lovelace/cards/hui-statistics-graph-card.ts | 2 +- src/panels/lovelace/cards/types.ts | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/panels/lovelace/cards/hui-statistics-graph-card.ts b/src/panels/lovelace/cards/hui-statistics-graph-card.ts index b75691b90ada..f8f21e37aca5 100644 --- a/src/panels/lovelace/cards/hui-statistics-graph-card.ts +++ b/src/panels/lovelace/cards/hui-statistics-graph-card.ts @@ -80,7 +80,7 @@ export class HuiStatisticsGraphCard private _statTypes?: Array; public hassSubscribe() { - if (!this._config?.energy_date_selection) { + if (!this._config?.collection_key) { return []; } diff --git a/src/panels/lovelace/cards/types.ts b/src/panels/lovelace/cards/types.ts index 8b97f6cfd04b..96c9fb5ab9da 100644 --- a/src/panels/lovelace/cards/types.ts +++ b/src/panels/lovelace/cards/types.ts @@ -345,7 +345,6 @@ export interface StatisticsGraphCardConfig extends EnergyCardBaseConfig { chart_type?: "line" | "bar"; hide_legend?: boolean; logarithmic_scale?: boolean; - energy_date_selection?: boolean; } export interface StatisticCardConfig extends LovelaceCardConfig {