mirror of
https://github.com/blakeblackshear/frigate.git
synced 2025-07-30 13:48:07 +02:00
Frontend timezone fixes
Last recording date timezone was being applied twice, so it displayed the wrong date Also, TZDate from react-day-picker could have been behaving incorrectly at times without a full date string
This commit is contained in:
parent
480072b22d
commit
c37f28880f
@ -50,7 +50,7 @@ export default function ReviewActivityCalendar({
|
||||
}
|
||||
|
||||
const parts = date.split("-");
|
||||
const cal = new TZDate(date, timezone);
|
||||
const cal = new TZDate(date + "T00:00:00", timezone);
|
||||
|
||||
cal.setFullYear(
|
||||
parseInt(parts[0]),
|
||||
@ -70,7 +70,7 @@ export default function ReviewActivityCalendar({
|
||||
}
|
||||
|
||||
const parts = date.split("-");
|
||||
const cal = new TZDate(date, timezone);
|
||||
const cal = new TZDate(date + "T00:00:00", timezone);
|
||||
|
||||
cal.setFullYear(
|
||||
parseInt(parts[0]),
|
||||
|
@ -80,7 +80,7 @@ export default function StorageMetrics({
|
||||
const formattedEarliestDate = useFormattedTimestamp(
|
||||
earliestDate || 0,
|
||||
format,
|
||||
timezone,
|
||||
"UTC", // timezone is already converted from recordings summary endpoint
|
||||
);
|
||||
|
||||
if (!cameraStorage || !stats || !totalStorage || !config) {
|
||||
|
Loading…
Reference in New Issue
Block a user