Skip to content
This repository was archived by the owner on Apr 22, 2026. It is now read-only.

Commit 2f35151

Browse files
committed
feat(gui): 增强账号管理功能与本地数据库支持
- 更新 .gitignore,添加 local_accounts.db 文件排除 - 在 gui_config_store.py 中新增 local_cpa_test_state 配置项 - 更新 gui_config.example.json,添加 local_cpa_test_state 示例 - 在 gui_frontend_app_setup.js 中新增本地账号管理功能 - 更新 gui_frontend_app_template.html,优化账号管理界面与交互 - 在 gui_server_runtime.py 中新增 API 处理逻辑,支持本地账号的删除与测试 - 在 gui_service_data_ops.py 中实现本地账号的 SQLite 存储与管理 - 更新 README.md,说明本地账号管理与 SQLite 存储的变更
1 parent 1dbba87 commit 2f35151

10 files changed

Lines changed: 1528 additions & 98 deletions

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@
44
.cursor
55
__pycache__/
66
*.txt
7+
*.db
78
gui_config.json
89
!gui_config.example.json

README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ CodeX Register 是一个桌面化的 Web 控制台,用于统一管理注册流
2727
- 邮箱体系:支持 Cloudflare Temp Email、MailFree、CloudMail、Mail-Curl、Gmail IMAP 与 Microsoft Graph,支持 Graph 文件导入、轮询与 token 刷新。
2828
- SMS 管理:支持 HeroSMS 余额检查、国家下拉(含价格/库存)、国家过滤、手机号复用、自动国家优选。
2929
- 代理能力:支持固定 HTTP 代理与 FlClash 动态切节点(含延迟探测、批次共享节点、自动过滤不可用节点)。
30-
- 数据管理:本地 `accounts_*.json` 导出文件管理,账号导入/云端维护独立到左侧“账号管理”。
30+
- 数据管理:本地 `accounts_*.json` 导出文件管理;本地账号统一落地到 SQLite(`local_accounts.db`,账号导入/云端维护独立到左侧“账号管理”。
3131
- 远端维护:支持 Sub2API / CLIProxyAPI 双云端账号源;均支持导入、批量测活、批量刷新、批量删除,Sub2API 额外支持复活与分组更新。
3232

3333
## 运行架构
@@ -89,7 +89,7 @@ python gui.py --mode browser --no-auto-open
8989

9090
- `工作台`:任务控制、实时统计(含 SMS 消耗/余额/阈值)。
9191
- `数据`:本地 `accounts_*.json` 导出文件管理。
92-
- `账号管理`本地页提供 `导入到sub2api``导入到cpa` 两个按钮;并保留 `导出为CPA可用文件`
92+
- `账号管理`本地账号以 SQLite(`local_accounts.db`)为唯一真源,支持按数量勾选、删除已选账号;`导出为Sub2API可用文件` 会弹窗设置“文件数/每文件账号数”;保留 `导入到sub2api``导入到cpa``导出为CPA可用文件`
9393
- `云端账号`:支持 Sub2API / CLIProxyAPI 双源(测活/刷新/删除),其中 Sub2API 额外支持复活与分组维护。
9494
- `邮箱设置`:MailFree / Gmail IMAP / Graph 设置,支持 Graph 文件导入与收件检查。
9595
- `SMS管理`:HeroSMS 开关、API Key、服务代码、国家价格下拉、余额刷新。
@@ -264,8 +264,9 @@ bob@outlook.com----pass456----yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy----0.AXEA...
264264

265265
## 运行产物
266266

267-
- `accounts_*.json`:成功账号 token 文件。
268-
- `accounts.txt`:账号与密码汇总。
267+
- `accounts_*.json`:成功账号 token 文件(兼容保留,可清理)。
268+
- `accounts.txt`:账号与密码汇总(兼容保留,可清理)。
269+
- `local_accounts.db`:本地账号 SQLite 存储(唯一真源)。
269270
- `gui_config.json`:本地配置回写。
270271

271272
## 本地 API 简表

gui_config.example.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@
5959
"mail_domain_error_counts": {},
6060
"mail_domain_registered_counts": {},
6161
"json_file_notes": {},
62+
"local_cpa_test_state": {},
6263
"mailfree_random_domain": true,
6364
"mailbox_custom_enabled": false,
6465
"mailbox_prefix": "",

gui_config_store.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@
6969
"mail_domain_error_counts": {},
7070
"mail_domain_registered_counts": {},
7171
"json_file_notes": {},
72+
"local_cpa_test_state": {},
7273
"mailfree_random_domain": True,
7374
"register_random_fingerprint": True,
7475
"openai_ssl_verify": True,

0 commit comments

Comments
 (0)