fix(ai-outfit): preview sample rows ignore Excel status (§19.9)
Add excel_service.read_all_rows (every valid data row, status-independent) and use it in _reload_sample_rows for the preview dropdown, so previewing still works after the whole sheet is 完成. Generation still uses load_outfit_tasks. +1 excel test (read_all_rows includes 完成/失败, skips incomplete); offscreen all-完成 sheet now yields sample rows; full suite (12) green. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -1121,6 +1121,6 @@
|
||||
|
||||
问题:预览样本行用 `load_outfit_tasks()`(给生成用、跳过「完成」行)填,整表生成成功后返回空 → 下拉只剩「(选 Excel 后显示替换效果)」。预览应不看状态。
|
||||
|
||||
- [ ] `services/excel_service.py`:新增 `read_all_rows(excel)`,返回每一有效数据行(标题/货号/衣服图齐全)的 `OutfitTask`,**忽略 E 列状态**
|
||||
- [ ] `ai_outfit_panel._reload_sample_rows()` 改调 `read_all_rows`(预览专用);生成仍走 `load_outfit_tasks`,`_on_tasks_loaded` 仍用实际任务
|
||||
- [ ] 单测 `tests/test_excel_service.py`:`read_all_rows` 含「完成」行也返回、空字段行跳过
|
||||
- [x] `services/excel_service.py`:新增 `read_all_rows(excel)`,返回每一有效数据行(标题/货号/衣服图齐全)的 `OutfitTask`,**忽略 E 列状态**
|
||||
- [x] `ai_outfit_panel._reload_sample_rows()` 改调 `read_all_rows`(预览专用);生成仍走 `load_outfit_tasks`,`_on_tasks_loaded` 仍用实际任务
|
||||
- [x] 单测 `tests/test_excel_service.py`:`read_all_rows` 含「完成」「失败」行也返回、空字段行跳过(8 用例);离屏验证全表完成的 Excel 预览下拉有样本行;全套 12 文件绿
|
||||
|
||||
Reference in New Issue
Block a user