mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
Fix repetier timestamp sensors (#61214)
This commit is contained in:
parent
54d55fdf88
commit
21f897bb5b
@ -160,7 +160,7 @@ class RepetierJobEndSensor(RepetierSensor):
|
||||
print_time = data["print_time"]
|
||||
from_start = data["from_start"]
|
||||
time_end = start + round(print_time, 0)
|
||||
self._state = datetime.utcfromtimestamp(time_end).isoformat()
|
||||
self._state = datetime.utcfromtimestamp(time_end)
|
||||
remaining = print_time - from_start
|
||||
remaining_secs = int(round(remaining, 0))
|
||||
_LOGGER.debug(
|
||||
@ -182,7 +182,7 @@ class RepetierJobStartSensor(RepetierSensor):
|
||||
job_name = data["job_name"]
|
||||
start = data["start"]
|
||||
from_start = data["from_start"]
|
||||
self._state = datetime.utcfromtimestamp(start).isoformat()
|
||||
self._state = datetime.utcfromtimestamp(start)
|
||||
elapsed_secs = int(round(from_start, 0))
|
||||
_LOGGER.debug(
|
||||
"Job %s elapsed %s",
|
||||
|
Loading…
x
Reference in New Issue
Block a user