update websocket reconnect policy & fix some bugs

This commit is contained in:
lb
2024-01-03 15:07:43 +08:00
parent 6b838ce089
commit 0f56538c27
8 changed files with 124 additions and 40 deletions

View File

@@ -115,7 +115,7 @@ function getOptions(period, trend) {
.fill(1)
.map((_, index) => {
if (period == "week") {
const dtimestamp = today - index * 24 * 60 * 60 * 1000;
const dtimestamp = today - (index+1) * 24 * 60 * 60 * 1000;
return `${new Date(dtimestamp).getMonth() + 1}.${new Date(
dtimestamp
).getDate()}`;

View File

@@ -114,7 +114,7 @@ function getOptions(period, trend) {
.fill(1)
.map((_, index) => {
if (period == "week") {
const dtimestamp = today - index * 24 * 60 * 60 * 1000;
const dtimestamp = today - (index+1) * 24 * 60 * 60 * 1000;
return `${new Date(dtimestamp).getMonth() + 1}.${new Date(
dtimestamp
).getDate()}`;