mirror of
https://github.com/home-assistant/frontend.git
synced 2026-04-17 07:34:21 +01:00
13 lines
267 B
TypeScript
13 lines
267 B
TypeScript
import type { HomeAssistant } from "../types";
|
|
|
|
export const setDateTimeValue = (
|
|
hass: HomeAssistant,
|
|
entityId: string,
|
|
datetime: Date
|
|
) => {
|
|
hass.callService("datetime", "set_value", {
|
|
entity_id: entityId,
|
|
datetime: datetime.toISOString(),
|
|
});
|
|
};
|