fix terminal system lines to use server time

This commit is contained in:
npc0-hue
2026-08-24 14:07:33 +08:00
parent 504387c657
commit 3e00737267
4 changed files with 52 additions and 28 deletions
+4
View File
@@ -9,3 +9,7 @@ export function formatTerminalLogTime(timestamp: string, line?: string): string
const date = new Date(timestamp);
return Number.isNaN(date.getTime()) ? "时间未知" : date.toLocaleTimeString([], { hour: "2-digit", minute: "2-digit", second: "2-digit" });
}
export function formatTerminalServerTime(timestamp?: string): string {
return timestamp ? formatTerminalLogTime(timestamp) : "时间同步中";
}