hailin
76ef8b0a8c
fix(service-party-app): 修复gRPC测试连接方法
...
将testConnection从URL解析改为直接使用host:port格式,
与grpc-client.ts的connect方法保持一致。
地址格式: mpc-grpc.szaiai.com:443 (自动检测TLS)
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 18:48:04 -08:00
hailin
2a11392ce2
fix(nginx): 配置文件使用.conf后缀以匹配nginx include规则
...
nginx.conf 使用 include /etc/nginx/sites-enabled/*.conf
因此配置文件必须以 .conf 结尾才能被加载。
变更:
- 添加 DOMAIN_CONF 变量 (mpc-grpc.szaiai.com.conf)
- 更新所有文件路径使用 .conf 后缀
- 卸载时兼容新旧文件名
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 18:39:45 -08:00
hailin
e268c33fa9
fix(nginx): 集成certbot目录创建到安装脚本
...
在安装脚本的configure_http步骤中添加:
- 创建完整的webroot目录结构: /var/www/certbot/.well-known/acme-challenge
- 设置正确的权限: chmod -R 755
这确保Let's Encrypt验证能正常工作,解决404错误问题。
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 18:29:59 -08:00
hailin
c457d15829
feat(co-managed-wallet): 添加分布式共管钱包 API 和 gRPC 代理
...
## 功能概述
实现分布式多方共管钱包创建功能的后端 API 和网络基础设施,
支持 Service Party App 通过公网连接参与 TSS 协议。
## 主要变更
### 1. Account Service - 共管钱包 API (新增)
- 新增 co_managed_handler.go - 独立的共管钱包 HTTP handler
- 新增 API 端点:
- POST /api/v1/co-managed/sessions - 创建共管钱包会话
- POST /api/v1/co-managed/sessions/:id/join - 加入会话
- GET /api/v1/co-managed/sessions/:id - 获取会话状态
- 扩展 session_coordinator_client.go:
- 添加 CreateCoManagedKeygenSession 方法
- 添加 JoinSession 方法
- 添加响应类型定义
- 更新 main.go 注册新路由 (SkipPaths 免认证)
### 2. Nginx gRPC 代理 (新增)
- 新增 mpc-grpc.szaiai.com.conf - gRPC over TLS 代理配置
- 新增 install-mpc-grpc.sh - 自动化安装脚本
- 支持 Let's Encrypt SSL 证书
- 代理到后端 Message Router (192.168.1.111:50051)
### 3. Service Party App 更新
- grpc-client.ts: 支持 TLS 连接,自动检测端口 443
- Settings.tsx: 默认地址改为 mpc-grpc.szaiai.com:443
- Home.tsx/Create.tsx: UI 样式优化
## 架构
```
Service Party App (用户电脑)
│
│ gRPC over TLS (端口 443)
▼
Nginx (mpc-grpc.szaiai.com:443)
│
│ grpc_pass
▼
Message Router (192.168.1.111:50051)
│
▼
Session Coordinator → Server Parties
```
## 100% 不影响现有功能
- 所有修改均为新增代码,不修改现有逻辑
- 共管钱包 API 完全独立于现有 RWADurian 系统
- Nginx 配置为独立文件,不影响现有 rwaapi.szaiai.com
- 使用现有 proto 定义 (co_managed_keygen, wallet_name, invite_code)
## 部署步骤
1. DNS: 添加 mpc-grpc.szaiai.com A 记录
2. 安装: sudo ./install-mpc-grpc.sh
3. 验证: curl https://mpc-grpc.szaiai.com/health
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 18:11:57 -08:00
hailin
a830a88cc3
feat(service-party-app): 添加签名功能并重命名应用
...
## 新增功能
- 添加"参与签名"页面 (Sign.tsx)
- 支持选择本地 share 参与 TSS 签名
- 支持导入备份文件参与签名
- 签名进度实时显示
## 应用重命名
- 应用名称改为"榴莲皇后绿积分共管账户服务"
- 更新 package.json productName
- 更新 index.html title
- 更新侧边栏 logo 文字
## 代码完善
- 完善 preload.ts API 定义
- 添加 main.ts IPC 处理器
- 更新 electron.d.ts 类型定义
- 添加 storage.ts saveSettings 方法
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 08:00:00 -08:00
hailin
7cfaacc833
fix(service-party-app): 修改默认阈值为 3-of-5
...
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 07:50:15 -08:00
hailin
47328c67d7
fix(service-party-app): 修复路由和启动问题
...
1. 将 BrowserRouter 改为 HashRouter - Electron 使用 file:// 协议
2. 移除生产环境自动打开浏览器的代码
3. HTTP 服务器仅在开发模式下启动
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 07:45:43 -08:00
hailin
15cbb2401f
fix(service-party-app): 修复 proto 文件打包路径问题
...
- 复制 message_router.proto 到 service-party-app/proto/
- 修改 grpc-client.ts 使用 process.resourcesPath 加载 proto 文件
- 使用 extraResources 将 proto 文件打包到 resources 目录外
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 07:39:55 -08:00
hailin
e43500fc3f
fix(service-party-app): 修复 electron-builder files 配置
...
- 将 electron/**/* 改为 dist-electron/**/* (编译后的文件)
- 添加 proto/**/* (gRPC proto 文件)
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 07:35:26 -08:00
hailin
7cec5b2b4c
fix(service-party-app): 修复 gRPC 客户端 TypeScript 类型错误
...
添加 ProtoPackage 接口定义 proto 包结构类型,避免类型推断错误
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 07:33:10 -08:00
hailin
1f476e8e5a
fix(service-party-app): 修复 Electron 主进程编译配置
...
- 新增 tsconfig.electron.json 单独编译 Electron 主进程到 dist-electron/
- 更新 package.json main 入口为 dist-electron/main.js
- 更新 build 脚本先编译 electron 再 vite build
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 07:31:26 -08:00
hailin
fcaa57605a
fix(service-party-app): fix TypeScript compilation errors
...
- Fix import/export consistency (use default exports)
- Add CSS module type declarations
- Fix ElectronAPI type definitions (ListSharesResult, ExportShareResult)
- Fix null checks for sessionInfo and session
- Change build script to use npx tsc
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 07:27:12 -08:00
hailin
88370691d1
fix(service-party-app): fix build script and remove icon requirement
...
- Rewrite build-windows.bat in English to avoid encoding issues
- Remove icon configuration from electron-builder.json (use default)
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 07:19:19 -08:00
hailin
8733e49735
feat(service-party-app): 添加 Windows 一键编译脚本
...
添加 build-windows.bat 脚本,支持:
- 检查 Node.js 和 Go 环境
- 编译 TSS 子进程 (tss-party.exe)
- 安装 npm 依赖
- 编译 Electron 应用
使用方法: 双击运行 build-windows.bat
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 07:07:43 -08:00
hailin
1908544698
fix(mobile-app): 修复 ProfilePage 在 initState 中修改 provider 导致的错误
...
将 _loadUnreadNotificationCount() 调用包装在 addPostFrameCallback 中,
延迟到 widget tree 构建完成后执行,避免 Riverpod 报错:
"Tried to modify a provider while the widget tree was building"
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 06:57:37 -08:00
hailin
b3142387f7
chore(mobile-app): 减少频繁轮询产生的调试日志
...
- 移除合同检查服务的频繁日志输出
- 移除维护状态检查的正常状态日志
- 只在检测到异常状态(维护中、待签署合同)时输出日志
- 减少服务器日志压力
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 06:54:16 -08:00
hailin
9e21d8c8cd
feat(api-gateway): 添加移动端系统维护接口的 Kong 路由
...
添加 /api/v1/mobile/system 路由到 admin-service,
使移动端可以访问 /mobile/system/maintenance-status 接口
检查系统维护状态。
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 06:36:02 -08:00
hailin
8a839b5e14
chore(mobile-app): 减少频繁日志输出
...
移除以下频繁执行操作的日志,只保留错误和关键状态日志:
- MaintenanceProvider: 移除正常状态日志,只保留检测到维护的日志
- ContractCheckService: 移除常规检查日志,只保留检测到异常的日志
- ContractSigningService: 移除KYC检查、获取任务列表等常规日志
- HomeShellPage: 移除合同检查定时器日志和路由栈打印
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 06:31:45 -08:00
hailin
68237d9905
chore(mobile-app): 调整维护状态轮询间隔为30-60秒
...
减少服务器压力:
- 将轮询间隔从 3-6 秒调整为 30-60 秒
- 10,000 用户时每秒约 222 次请求(之前约 2,222 次)
- 用户最多 60 秒内发现维护状态变化
- 启动时和从后台恢复时仍立即检查
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 06:23:20 -08:00
hailin
7e8113805d
feat(mobile-app): 在主页添加随机3-6秒轮询检查维护状态
...
- 用户登录后在 HomeShellPage 每 3-6 秒(随机)检查一次维护状态
- 随机间隔可避免所有用户同时请求,减少服务器压力
- 后端发起维护后,用户最多 6 秒内会看到维护弹窗
- App 进入后台时暂停检查,恢复前台时立即检查并重启定时器
- 启动时、从后台恢复时也会立即检查一次
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 06:21:21 -08:00
hailin
0781c53101
fix(admin-service): 修复 getCurrentStatus 方法使用旧响应格式的问题
...
AdminMaintenanceController.getCurrentStatus() 方法仍使用旧的 inMaintenance 字段,
导致构建失败。更新为与 MobileMaintenanceController 一致的新格式:
- 使用 isUnderMaintenance 代替 inMaintenance
- 使用嵌套的 maintenance 对象包含详情
- 添加 remainingMinutes 字段计算
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 06:11:54 -08:00
hailin
6c4a40c42d
fix(migration): 使数据库迁移脚本幂等化,支持重复执行
...
将 008_add_co_managed_wallet_fields.up.sql 改为幂等脚本:
- 使用 DO $$ ... IF NOT EXISTS 检查列是否存在再添加
- 使用 CREATE INDEX IF NOT EXISTS 创建索引
- 使用 DROP CONSTRAINT IF EXISTS 删除约束
这确保迁移脚本可以安全地多次执行,不会因列/索引已存在而失败。
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 05:26:38 -08:00
hailin
75a9ffadef
fix(admin-service): 修复移动端维护状态API响应格式不匹配问题
...
移动端期望的格式:
{
"isUnderMaintenance": true,
"maintenance": { "title", "message", "startTime", "endTime", "remainingMinutes" }
}
后端之前返回的格式:
{
"inMaintenance": true,
"title", "message", "endTime"
}
修改内容:
- 字段名 inMaintenance → isUnderMaintenance
- 嵌套维护详情到 maintenance 对象
- 添加 startTime 和 remainingMinutes 字段
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 05:10:18 -08:00
hailin
912cc1eb8f
fix(admin-web): 修复切换维护状态HTTP方法不匹配问题 (PATCH→PUT)
2025-12-28 05:03:34 -08:00
hailin
ba3a21d049
fix(admin-web): 修复系统维护"立即激活"按钮不显示的问题
...
- 修复 getStatusTag 函数逻辑,未激活状态使用 'inactive' 样式而不是 'expired'
- 添加更细化的状态判断:维护中、已过期、已计划、未激活、待激活
- 添加 inactive 标签样式(橙色背景)
- 现在未激活的维护计划会正确显示"立即激活"按钮
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 04:59:06 -08:00
hailin
8df2046a4e
docs: 添加 Service Party App 技术文档
...
添加分布式共管钱包桌面应用的详细技术文档,包括:
- 应用概述和使用场景
- 目录结构说明
- 技术架构和技术栈
- TSS 子进程架构设计
- IPC 消息格式定义
- 核心功能说明
- 编译与运行指南
- 安全考虑
- 系统集成说明
- 未来扩展规划
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 04:42:09 -08:00
hailin
cc3644de9d
feat(mpc-system): 添加单服务管理命令到deploy.sh
...
新增命令:
- start-svc: 启动单个服务
- stop-svc: 停止单个服务
- restart-svc: 重启单个服务
- rebuild-svc: 重建并重启服务 (支持--no-cache)
支持开发模式和生产模式
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 04:23:22 -08:00
hailin
1af5780b19
fix(admin-service): 修复共管钱包 status 类型不匹配问题
...
使用 Prisma 生成的类型替代手动定义的接口:
- PrismaCoManagedWalletSession -> @prisma/client
- PrismaCoManagedWallet -> @prisma/client
- status 字段使用 PrismaWalletSessionStatus 枚举类型
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-28 00:02:18 -08:00
hailin
e51450d9f9
chore(admin-service): 添加系统维护和共管钱包的数据库迁移
...
添加缺失的 migration 文件,包含:
- system_maintenances 表 (系统维护公告)
- WalletSessionStatus 枚举
- co_managed_wallet_sessions 表 (共管钱包会话)
- co_managed_wallets 表 (共管钱包记录)
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 23:36:42 -08:00
hailin
1b5bcf3fda
fix(co-managed-wallet): 修复向后兼容性问题并完善protobuf定义
...
## 变更概述
根据用户反馈,将 Session Coordinator 的函数签名改为可选参数模式,
确保新功能 100% 不影响现有的 keygen/sign 功能。
## 主要变更
### 1. Session Coordinator 向后兼容修复
- 保留原有 `ReconstructSession` 函数签名不变
- 新增 `ReconstructSessionOptions` 结构体存放可选参数
- 新增 `ReconstructSessionWithOptions` 函数支持新字段
- 原函数内部调用新函数,传入 nil options
### 2. Protobuf 定义更新
- CreateSessionRequest 新增字段:
- wallet_name (field 10): 钱包名称
- invite_code (field 11): 邀请码
- SessionInfo 新增字段:
- wallet_name (field 8): 钱包名称
- invite_code (field 9): 邀请码
- session_type 支持 "co_managed_keygen"
### 3. TSS Party 子进程修复
- 修复 tss.NewPartyID 参数类型错误 (big.Int)
- 修复 go.mod 依赖问题 (ed25519 replace)
- 删除未使用的变量
### 4. 清理错误生成的文件
- 删除 api/proto/*.pb.go (错误位置)
- 保留 api/grpc/coordinator/v1/*.pb.go (正确位置)
## 修改的文件
| 文件 | 变更类型 | 说明 |
|------|---------|------|
| mpc_session.go | 修改 | 添加 ReconstructSessionWithOptions |
| session_postgres_repo.go | 修改 | 使用新函数传入 options |
| session_cache_adapter.go | 修改 | 使用新函数传入 options |
| session_coordinator.proto | 修改 | 添加 wallet_name, invite_code 字段 |
| session_coordinator.pb.go | 重新生成 | 包含新 protobuf 字段 |
| tss-party/main.go | 修复 | NewPartyID 参数和未使用变量 |
| tss-party/go.mod | 修复 | ed25519 依赖替换 |
## 向后兼容性保证
- 所有现有代码调用 ReconstructSession 无需任何修改
- 数据库使用 COALESCE 处理 NULL 值
- Protobuf 新字段使用高序号,不影响现有消息解析
- **影响现有功能的风险: 0%**
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 23:33:40 -08:00
hailin
dc16a616a5
fix(identity-service): 修复并发auto-login请求导致的唯一约束冲突
...
- 在创建新token前先撤销该设备的旧token
- 使用upsert替代create避免并发时refresh_token_hash唯一约束冲突
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 23:27:21 -08:00
hailin
c328d8b59b
feat(mobile-app,admin): 添加系统维护功能和通知徽章功能
...
系统维护功能:
- 后端: 添加系统维护配置实体、仓库和控制器
- 后端: 添加维护模式拦截器,返回503状态码
- admin-web: 添加系统维护管理页面,支持创建/编辑/开关维护配置
- mobile-app: 添加维护状态检查服务和阻断弹窗
- mobile-app: 在启动页、向导页集成维护检查
- mobile-app: 支持App从后台恢复时自动检查维护状态
通知徽章功能:
- 添加通知徽章Provider,监听登录状态自动刷新
- 底部导航栏"我的"标签显示未读通知红点
- 进入通知页面自动刷新徽章状态
- 切换账号、退出登录自动清除徽章
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 23:26:01 -08:00
hailin
fea01642e7
feat(co-managed-wallet): 添加分布式多方共管钱包创建功能
...
## 功能概述
实现分布式多方共管钱包创建功能,包括 Admin-Web 扩展和 Service-Party 桌面应用。
## 主要变更
### 1. Admin-Web 扩展 (前端)
- 新增 CoManagedWalletSection 组件 (frontend/admin-web/src/components/features/co-managed-wallet/)
- 在授权管理页面添加共管钱包入口卡片
- 实现创建钱包向导: 配置 → 邀请 → 生成 → 完成
- 包含组件: ThresholdConfig, InviteQRCode, ParticipantList, SessionProgress, WalletResult
### 2. Admin-Service 后端 API
- 新增共管钱包领域实体和枚举 (domain/entities/co-managed-wallet.entity.ts)
- 新增 REST 控制器 (api/controllers/co-managed-wallet.controller.ts)
- 新增服务层 (application/services/co-managed-wallet.service.ts)
- 新增 Prisma 模型: CoManagedWalletSession, CoManagedWallet
- 更新 app.module.ts 注册新模块
### 3. Session Coordinator 扩展 (Go)
- 新增会话类型: SessionTypeCoManagedKeygen ("co_managed_keygen")
- 扩展 MPCSession 实体添加 WalletName 和 InviteCode 字段
- 更新 PostgreSQL 和 Redis 适配器支持新字段
- 新增数据库迁移: 008_add_co_managed_wallet_fields
### 4. Service-Party 桌面应用 (新项目)
- 位置: backend/mpc-system/services/service-party-app/
- 技术栈: Electron + React + TypeScript + Vite
- 包含模块:
- gRPC 客户端 (连接 Message Router)
- TSS 处理器 (子进程方式运行 Go TSS 协议)
- 本地加密存储 (AES-256-GCM)
- 页面: Home, Join, Create, Session, Settings
## 修改的现有文件 (便于回滚)
1. backend/mpc-system/services/session-coordinator/domain/entities/mpc_session.go
- 添加 SessionTypeCoManagedKeygen 常量
- 添加 IsKeygen() 方法
- 添加 WalletName, InviteCode 字段
- 更新 ReconstructSession, ToDTO, SessionDTO
2. backend/mpc-system/services/session-coordinator/adapters/output/postgres/session_postgres_repo.go
- 更新 SQL 查询包含 wallet_name, invite_code
- 更新 Save, FindByUUID, FindByStatus 等方法
- 更新 scanSessions, sessionRow
3. backend/mpc-system/services/session-coordinator/adapters/output/redis/session_cache_adapter.go
- 更新 sessionCacheEntry 结构
- 更新 sessionToCacheEntry, cacheEntryToSession
4. backend/services/admin-service/prisma/schema.prisma
- 新增 WalletSessionStatus 枚举
- 新增 CoManagedWalletSession, CoManagedWallet 模型
5. backend/services/admin-service/src/app.module.ts
- 导入并注册共管钱包相关组件
6. frontend/admin-web/src/app/(dashboard)/authorization/page.tsx
- 导入并添加 CoManagedWalletSection
7. frontend/admin-web/src/infrastructure/api/endpoints.ts
- 添加 CO_MANAGED_WALLETS API 端点
## 回滚说明
如需回滚此功能:
1. 回滚数据库迁移: 运行 008_add_co_managed_wallet_fields.down.sql
2. 删除新增文件夹:
- backend/mpc-system/services/service-party-app/
- frontend/admin-web/src/components/features/co-managed-wallet/
- backend/services/admin-service/src/**/co-managed-wallet*
3. 恢复修改的文件到前一个版本
4. 运行 prisma generate 重新生成 Prisma 客户端
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 21:39:07 -08:00
hailin
9c7dc6f511
feat(mobile-app): 非强制更新时下载完成后让用户选择是否安装
...
- 强制更新:下载完成后自动安装
- 非强制更新:下载完成后显示"稍后安装"和"立即安装"按钮
- 更新提示对话框中"稍后"改为"暂时不更新"
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 20:20:47 -08:00
hailin
fe593714ae
fix(admin-service): 修复上传版本时isForceUpdate始终为true的问题
...
问题原因:
- ValidationPipe配置了enableImplicitConversion: true
- FormData发送字符串"false"时,Boolean("false")被隐式转换为true
- @Transform装饰器在隐式转换之后执行,收到的value已经是true
解决方案:
- 在@Transform中使用obj参数获取原始未转换的值
- 手动判断字符串"true"/"false"并正确转换为布尔值
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 19:31:47 -08:00
hailin
058849dc2c
fix(admin-service): 修复上传版本时isForceUpdate默认为true的问题
...
- 改进Transform装饰器,正确处理FormData传递的字符串"false"
- 添加调试日志用于排查问题
问题原因:FormData传递的布尔值会被转为字符串,
原来的Transform可能在某些情况下处理不正确
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 19:21:48 -08:00
hailin
a54a01bba0
fix(mobile-app): 修改秘密点击解锁逻辑,点击19次后需等待2秒
...
- 连续点击19次后启动2秒定时器
- 2秒内再次点击会取消并重新计时
- 确保用户停止点击后才显示"我的同僚"
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 11:26:22 -08:00
hailin
b20ec10c75
refactor(mobile-app): 修改"我的"页面文案
...
- "团队种植树" → "同僚种植树"
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 11:23:45 -08:00
hailin
f20ed32f5f
refactor(mobile-app): 简化删除账号确认对话框文案
...
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 11:22:28 -08:00
hailin
1694f37e91
fix(mobile-app): 修复多账号切换后账号列表只显示一个的问题
...
- phone_login_page: 登录成功后添加账号到多账号列表
- import_mnemonic_page: 恢复账号后添加到多账号列表
- sms_verify_page: 短信验证登录后添加账号到多账号列表
问题原因:多个登录入口没有调用 addAccount() 将账号添加到列表
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 11:12:50 -08:00
hailin
a8261e110a
fix(mobile-app): 退出登录时停止遥测上传
...
- TelemetryService 添加 pauseForLogout() 方法
- 退出登录时先停止定期上传再清空队列
- 避免退出后继续上传导致等待
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 10:40:28 -08:00
hailin
3d68d1f6f6
fix(mobile-app): 简化退出登录提示文案
...
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 10:35:50 -08:00
hailin
4e4d9f43f6
fix(mobile-app): 修复退出登录报错问题
...
- TelemetryStorage.clearUserData() 添加初始化检查
- 移除 logoutCurrentAccount() 中多余的保存数据逻辑
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 10:34:50 -08:00
hailin
2a929fc082
fix(mobile-app): 修复头像更新未同步到账号列表的问题
...
- AccountService 添加 MultiAccountService 依赖
- updateLocalAvatarSvg() 更新后同步到账号列表
- updateProfile() 更新昵称/头像后同步到账号列表
- uploadAvatar() 上传头像后同步到账号列表
- 新增 _syncProfileToAccountList() 统一处理同步逻辑
- 调整 injection_container 依赖注入顺序
确保切换账号时显示正确的头像和昵称
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 10:25:19 -08:00
hailin
339f95f7ed
fix(identity-service): 修复手动重试钱包生成使用错误的事件类型
...
retryWalletGeneration 方法之前使用 createWalletGenerationEvent()
发布 UserAccountCreatedEvent,但 MPC 服务只监听 MpcKeygenRequestedEvent。
现在改为直接发布 MpcKeygenRequestedEvent,与 wallet-retry.task.ts 保持一致。
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 10:15:30 -08:00
hailin
9153ba3625
fix(identity-service): 修复钱包重试发布错误事件类型的问题
...
问题:
- 重试代码使用 createWalletGenerationEvent() 发布 UserAccountCreatedEvent
- 该事件发布到 identity.UserAccountCreated topic
- 但 MPC 服务监听的是 mpc.KeygenRequested topic
- 导致重试触发成功但钱包不会被生成
修复:
- triggerWalletRetryAsync: 改为发布 MpcKeygenRequestedEvent
- WalletRetryTask.retryWalletGeneration: 改为发布 MpcKeygenRequestedEvent
- 与注册流程使用相同的事件类型和参数格式
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 10:09:20 -08:00
hailin
8eecc4c55f
fix(mobile-app): 修复账号切换的严重bug和数据隔离问题
...
问题修复:
1. 键列表不一致 - 统一定义 _accountSecureKeys 和 _accountLocalKeys
2. 缺少 phoneNumber/isPasswordSet/biometricEnabled - 补充到键列表
3. 切换前未清除旧数据 - 新增 _clearCurrentAccountData 方法
4. 缓存数据未按账号隔离 - LocalStorage 数据也按账号保存/恢复
5. 遥测队列未隔离 - 切换时清除遥测事件队列
新增功能:
- _validateAccountData: 切换前验证目标账号数据完整性
- _clearCurrentAccountData: 切换前清除当前存储空间
优化:
- switchToAccount: 完整的切换流程(验证→保存→清除→恢复)
- saveCurrentAccountData: 同时保存 SecureStorage 和 LocalStorage
- _restoreAccountData: 同时恢复 SecureStorage 和 LocalStorage
- deleteAccount: 同时删除 SecureStorage 和 LocalStorage 专用键
- logoutCurrentAccount: 使用统一键列表,确保一致性
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 10:01:11 -08:00
hailin
6216a1563a
fix(identity-service): 修复动态import导致的模块解析错误
...
将动态 import('@/domain/value-objects') 改为静态 import
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 09:58:23 -08:00
hailin
4de96dac9d
fix(mobile-app): 完善退出登录时的数据清理逻辑
...
遵循大厂最佳实践,确保退出登录后下次登录是干净的环境:
SecureStorage 新增清除项:
- inviterReferralCode (临时邀请码)
- biometricEnabled (生物识别设置)
LocalStorage 新增清除项:
- lastSyncTime (最后同步时间)
- cachedRankingData (排行榜缓存)
- cachedMiningStatus (矿机状态缓存)
遥测数据:
- 清除用户相关的事件队列
重构:
- MultiAccountService 增加 LocalStorage 和 TelemetryStorage 依赖
- 更新依赖注入容器
- TelemetryStorage 新增 clearUserData 方法
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 09:55:17 -08:00
hailin
e742a360ec
fix(identity-service): 限制定时任务每次最多触发10个重试,防止MPC过载
...
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-27 09:42:56 -08:00