From d82e9dc407805fc569191f7c45b7f03af206136d Mon Sep 17 00:00:00 2001 From: soehi <811446351@qq.com> Date: Thu, 19 Nov 2026 15:07:30 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AF=BE=E8=A1=A8=E5=AF=BC=E5=87=BA=E5=8C=85?= =?UTF-8?q?=E5=90=AB=E6=9C=AA=E6=8F=90=E4=BA=A4=E5=92=8C=E8=AF=86=E5=88=AB?= =?UTF-8?q?=E5=A4=B1=E8=B4=A5=E7=8A=B6=E6=80=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- TIMETABLES.md | 2 +- dist/index.html | 2 +- dist/js/app.js | 2 +- server/timetables.py | 21 ++++++++++++++++----- tests/test_timetables.py | 25 +++++++++++++++++++++++++ 5 files changed, 44 insertions(+), 8 deletions(-) diff --git a/TIMETABLES.md b/TIMETABLES.md index f4eec70..3c9f67a 100644 --- a/TIMETABLES.md +++ b/TIMETABLES.md @@ -51,7 +51,7 @@ | `GET /api/timetables/export?format=csv` | 每个课表20行,便于表格整理 | | `POST /api/timetables/reprocess` | 管理员选择 `user_ids`、`week_types`,用当前算法重跑已保存图片;默认跳过已人工确认的课表 | -默认 `confirmed_only=false`,未核对课表和已核对课表都会导出;传 `true` 可只导出已核对课表。管理员密钥正确时导出全部成员,密钥错误或缺失时拒绝下载。JSON 中 `structure.cells` 每项包含 `day=1..5`、`slot`、`status=busy/free/unknown`、`courses`、`confidence`、`source` 和 `eligible`。时段时间见顶层 `slots`,记录的 `week_type` 为 `odd` / `even`。时间戳为 Unix 毫秒。 +默认 `confirmed_only=false`,未核对课表和已核对课表都会导出;传 `true` 可只导出已核对课表。管理员密钥正确时导出全部成员,密钥错误或缺失时拒绝下载。JSON 中 `structure.cells` 每项包含 `day=1..5`、`slot`、`status=busy/free/unknown`、`courses`、`confidence`、`source` 和 `eligible`;每条记录带 `ocr_status` 和 `recognition_failed`,识别失败明确标记,不会伪装成空闲。完全未提交的成员放在顶层 `missing` 列表。CSV 中识别失败行 `recognition_failed=true`,未提交成员输出一行 `week_type=未提交`、`status=missing` 占位。时段时间见顶层 `slots`,记录的 `week_type` 为 `odd` / `even`。时间戳为 Unix 毫秒。 重新识别接口只更新结构化结果和修订时间,不替换或删除原图。已人工确认的记录默认返回 `skipped_confirmed`;只有请求显式传入 `force_confirmed=true` 才会覆盖并撤销确认。 diff --git a/dist/index.html b/dist/index.html index 0756df8..4619708 100644 --- a/dist/index.html +++ b/dist/index.html @@ -337,7 +337,7 @@
- +