feat: LAN update check on startup with notify banner (stage 2)
Read manifest.json from the configured update_source and show a dismissable banner when a newer version is available. Notify-only — no install yet. - services/update_service.py: version compare + check_for_update (pure, tested) - config: add update_source key (empty = no check) - main_window: top banner, background-thread check; open folder via os.startfile (QDesktopServices.openUrl mishandles file:// folder URLs — ShellExecute err 2) - tests: +15 covering version compare and check_for_update branches - docs 02/05/10 + tasks 17.16 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
+3
-1
@@ -330,7 +330,8 @@ CMBot/
|
||||
"last_garment_dir": "",
|
||||
"last_print_dir": "",
|
||||
"last_template": "正方形模板",
|
||||
"last_batch_mode": "full_combo"
|
||||
"last_batch_mode": "full_combo",
|
||||
"update_source": ""
|
||||
}
|
||||
```
|
||||
|
||||
@@ -339,6 +340,7 @@ CMBot/
|
||||
- `last_garment_dir` / `last_print_dir`:上次打开的衣服 / 印花文件夹路径,用于让文件夹对话框定位到上次位置。
|
||||
- `last_template`:上次选中的模板名称,用于启动恢复。
|
||||
- `last_batch_mode`:上次选择的批量模式(取 `BatchMode` 枚举值,如 `full_combo` / `many_garments` / `many_prints` / `one_to_one`)。
|
||||
- `update_source`:局域网更新源目录(含 `manifest.json`)。为空时不做更新检查。详见 `docs/10-lan-update.md`。
|
||||
- 偏好的读取、分发与「改一次存一次」由主窗口集中处理,UI 控件不直接读写配置文件。
|
||||
|
||||
## 10. 验收标准
|
||||
|
||||
Reference in New Issue
Block a user