mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-24 09:46:36 +00:00
Force using history for all entity domains on map card (#15804)
This commit is contained in:
parent
1bc7bb0169
commit
effb4b9f7a
@ -232,7 +232,8 @@ export const subscribeHistoryStatesTimeWindow = (
|
||||
hoursToShow: number,
|
||||
entityIds: string[],
|
||||
minimalResponse = true,
|
||||
significantChangesOnly = true
|
||||
significantChangesOnly = true,
|
||||
noAttributes?: boolean
|
||||
): Promise<() => Promise<void>> => {
|
||||
const params = {
|
||||
type: "history/stream",
|
||||
@ -242,9 +243,11 @@ export const subscribeHistoryStatesTimeWindow = (
|
||||
).toISOString(),
|
||||
minimal_response: minimalResponse,
|
||||
significant_changes_only: significantChangesOnly,
|
||||
no_attributes: !entityIds.some((entityId) =>
|
||||
entityIdHistoryNeedsAttributes(hass, entityId)
|
||||
),
|
||||
no_attributes:
|
||||
noAttributes ??
|
||||
!entityIds.some((entityId) =>
|
||||
entityIdHistoryNeedsAttributes(hass, entityId)
|
||||
),
|
||||
};
|
||||
const stream = new HistoryStream(hass, hoursToShow);
|
||||
return hass.connection.subscribeMessage<HistoryStreamMessage>(
|
||||
|
@ -216,6 +216,7 @@ class HuiMapCard extends LitElement implements LovelaceCard {
|
||||
this._config!.hours_to_show! ?? DEFAULT_HOURS_TO_SHOW,
|
||||
this._configEntities!,
|
||||
false,
|
||||
false,
|
||||
false
|
||||
).catch((err) => {
|
||||
this._subscribed = undefined;
|
||||
|
Loading…
x
Reference in New Issue
Block a user