feat: add SQL Server database persistence for extracted material plan data

Add optional database persistence feature that automatically saves extracted
discrete material plan data to SQL Server. Users can enable this feature in
the settings tab.

Changes:
- Add enable_db_persistence flag to ExtractionConfig (default: disabled)
- Create DiscreteMaterialPlanDAO for database operations with REPLACE pattern
- Update progress tracking to include database persistence stage (90-100%)
- Add database persistence checkbox in settings UI
- Remove verbose logging checkbox from data extraction UI (config-only now)
- Update extraction workflow to save merged DataFrame to database

Progress weights adjusted:
- download: 65% -> 60%
- database: 10% (new stage)
- Other stages adjusted accordingly

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
Misaka_Company
2026-02-06 12:18:15 +08:00
parent 3180ccacb8
commit 53a1e33e45
8 changed files with 394 additions and 24 deletions

View File

@@ -125,6 +125,7 @@ class MainWindow:
"• 数据提取 - 从 ERP 系统提取备料计划数据\n"
"• 物料校验 - 校验物料状态并匹配待删除物料\n"
"• 数据查询 - 查询生产订单号等信息\n"
"• 设置管理 - 管理系统配置\n\n"
"• 设置管理 - 管理系统配置\n"
"• 数据库持久化 - 将提取的数据自动保存到 SQL Server\n\n"
"基于 Playwright 和 Python 开发",
)