feat: 历史统计时对照显示官方本月学时

This commit is contained in:
Nixevol
2026-11-19 02:54:32 +08:00
parent ba787a513b
commit a0ceb51348
12 changed files with 156 additions and 13 deletions
+2
View File
@@ -150,6 +150,7 @@ def test_login_stores_password_and_credential_only(monkeypatch) -> None:
"last_refresh_at",
"credential_valid",
"month_hours",
"official_month_hours",
"user_name",
"company",
"hours_month",
@@ -1155,6 +1156,7 @@ def test_home_and_history_hours_follow_source(monkeypatch) -> None:
history = client.get("/api/home/history")
assert home.json()["hours_source"] == history.json()["hours_source"] == "history"
assert home.json()["month_hours"] == history.json()["month_hours"] == 2
assert home.json()["official_month_hours"] == history.json()["official_month_hours"] == "60"
assert home.json()["year_hours"] == history.json()["year_hours"] == "100"
assert home.json()["total_hours"] == history.json()["total_hours"] == "10"
assert home.json()["today_hours"] == history.json()["today_hours"] == 1