iven
|
787e64d9a9
|
fix: 前端深度审计全量修复 — 安全/功能/代码质量
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
严重 BUG 修复:
- 修复 Token 过期后 hash 重定向导致无法跳转登录页
- 修复文章编辑器新建后提交审核使用错误 ID
安全加固:
- HTML 清理函数替换为 ammonia 专业库(替代自定义解析器)
- 文件上传添加 magic bytes 校验(防 Content-Type 伪造)
- 登录添加账户级失败锁定(5次失败→15分钟锁定)
- 审计日志 9 个关键更新操作补充变更前后值(with_changes)
功能缺陷修复:
- 登录/登出时清理 API 缓存(防多账户数据污染)
- 文章编辑器上传改用统一 HTTP 客户端(自动 token 刷新)
- 添加全局 HTTP 错误处理和后端错误消息展示
- PrivateRoute 增加路由级权限检查(系统管理页面)
- 健康数据三个 Tab 添加编辑/删除功能
- 预约创建增加排班可用性校验提示
- 医生详情 API 返回解密后的原始执照号
代码清理:
- 删除未使用的 auth.ts refresh() 函数
- 删除重复的 AuthGuard.tsx 组件
- 删除未使用的 getHealthSummary API
|
2026-04-26 21:47:26 +08:00 |
|
iven
|
8a253a4910
|
fix: 低优先级收尾 — 图片上传/语言编辑/插件恢复/URL 编码
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- P3-2: ArticleEditor 图片上传接入 /upload 端点 + 封面图上传按钮
- P4-3: recover_plugins 添加 tenant 日志 + 同 ID 去重保护
- P4-4: LanguageManager 编辑弹窗改为真实表单 (name 字段) + 后端 name 持久化
- P4-6: Settings API getSetting/updateSetting 添加 encodeURIComponent
|
2026-04-26 19:52:42 +08:00 |
|
iven
|
b05b7c27a0
|
feat: 审计修复 Phase 6-7 — SSE 推送/工作流补全/消息群发/前端收尾
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
Phase 6 功能补全:
- P1-3: 消息 SSE 实时推送端点 + 前端 EventSource 连接
- P1-6: ServiceTask HTTP 调用能力 (reqwest GET/POST)
- P1-7: user.deleted 事件处理 — 终止相关流程实例
- P1-8: 任务认领 (claim) 端点 + handler
- P1-9: 超时检查器发布 task.timeout 事件
- P1-15: 组织/部门名称唯一性校验 (create + update)
- P1-18: 消息群发 fan-out (role/department/all 批量投递)
Phase 7 P3-P4 收尾:
- PluginAdmin purge 按钮状态修复
- ChangePassword 最小 8 字符 + 新旧密码不同验证
- AuditLogViewer 用户名缓存 + 扩展资源类型
- InstanceMonitor 通过 definition 缓存解析 node_name
- NotificationPreferences DND 时间范围校验
|
2026-04-26 19:44:04 +08:00 |
|
iven
|
83fe89cbcd
|
fix: 全系统审计问题修复 — 安全/数据完整性/功能缺陷/UX (Phase 1-5)
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
Phase 1 安全热修复:
- P0-1: /uploads 文件服务添加 JWT 认证中间件(支持 header + query param)
- P0-2: analytics/batch 路由从 public 移到 protected_routes
- P0-3: plugin engine SQL 注入修复(format! → 参数化查询)
- P0-new: stats_service compute_avg_field 字段白名单 + FLOAT8 类型转换
Phase 2 数据完整性:
- P0-4: 组织删除级联检查(添加部门存在性校验)
- P0-5: 部门删除级联检查(添加岗位 + 用户存在性校验)
- P0-8: workflow on_tenant_deleted 实现 5 实体批量删除
- P0-7: 并行网关 race condition 修复(consumed → completed 原子转换)
Phase 3 P1 后端 Bug:
- P1-12: plugin host 表名消毒(使用 sanitize_identifier)
- P1-10: workflow deprecated 状态转换(published → deprecated)
- P1-11: workflow 更新验证条件(nodes/edges 任一变化即验证)
- P0-9: 小程序 .gitignore 添加 .env/.env.*/日志
- P1-19: 小程序加密密钥替换为 64 字符强密钥
Phase 4 消息模块:
- P1-5: 通知偏好 GET 路由 + handler
- P1-4: 消息模板 update/delete CRUD + version
- P2-8: mark_all_read SQL 添加 version + 1
- P2-7: markAsRead 改为乐观更新 + 失败回滚
Phase 5 前端修复:
- P2-9: 通知面板点击导航到 /messages
- P2-1: 随访任务患者名批量 ID 解析(替代 UUID 显示)
- P2-5: AppointmentList 分离 patient_id/doctor_id 分别调用 API
- P2-17: PluginMarket installed 字段修正(name → id)
- P3-3: 路由标题 fallback 改为模式匹配(支持 :id 动态路径)
- P2-15: workflow updateDefinition 添加 version 字段
- P3-9: Kanban 版本使用记录实际 version
- P2-21: secure-storage 生产环境无密钥时阻止存储
- P3-11: destroyOnHidden → destroyOnClose
- P3-13: PendingTasks 深色模式 Tag 颜色适配
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
2026-04-26 19:16:23 +08:00 |
|
iven
|
5bb6105127
|
feat: 咨询消息轮询优化 — Web 自动刷新 + 患者端聊天详情页
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
Web 端:
- ConsultationDetail 添加 10s 自动轮询新消息(after_id 增量拉取)
- consultations API 补充 after_id 参数
小程序患者端:
- 新增 consultation service 消息 API(listMessages/sendMessage/markSessionRead)
- 新增聊天详情页(8s 轮询 + 发送消息 + 自动标记已读)
- 咨询列表页点击跳转详情页(替换"即将上线"占位)
|
2026-04-26 14:40:46 +08:00 |
|
iven
|
7a9054c914
|
feat: 医护仪表盘增强 + 患者端文章分类浏览
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- DoctorDashboard 增加 pending_dialysis_review/pending_lab_review/today_appointments
- 医护小程序首页增加「健康审核」区块(待审透析/化验/今日预约)
- 患者端文章列表增加分类 tabs 横向滚动筛选
- article service 增加 listCategories + category_id 筛选
|
2026-04-26 14:25:06 +08:00 |
|
iven
|
c9bf5f6139
|
feat(health): 健康数据统计 — 透析/化验/预约/体征上报率
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 新增 6 个统计端点: dialysis, lab-reports, appointments,
vital-signs-report-rate, health-data(综合)
- 透析统计: 类型分布/并发症率/平均超滤/平均时长
- 化验统计: 类型分布/异常项计数/审核状态
- 预约统计: 状态/类型分布/取消率
- 体征上报率: 月度上报率 + 近 7 天趋势
- Web 统计面板增加健康数据中心区块
|
2026-04-26 14:19:38 +08:00 |
|
iven
|
55ec57b2c0
|
feat(health): 积分规则/商品 update/delete + 标签更新端点
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 积分规则: 添加 update/delete service + handler + 路由
- 兑换商品: 添加 update/delete service + handler + 路由
- 文章标签: 添加 update service + handler + 路由
- Web 管理端: 规则/商品列表页支持编辑/删除/启用切换
- Web 管理端: 标签管理页支持编辑、删除传 version
|
2026-04-26 14:07:21 +08:00 |
|
iven
|
f0076aa240
|
feat: Iteration 3 — 咨询轮询、统计概览、埋点后端
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- consultation_service 支持 after_id 增量消息查询
- 小程序咨询详情页 8 秒轮询新消息
- 新增 DashboardStatsResp 综合统计端点 (/statistics/dashboard)
- 新增 /analytics/batch 埋点接收端点(日志记录模式)
|
2026-04-26 13:54:21 +08:00 |
|
iven
|
0cf69815d9
|
feat: 通知分发器 DND 检查 + 咨询/报告事件 + 线下活动页面
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
Iteration 2 剩余工作:
通知分发器改进(erp-message module.rs):
- 添加 should_skip_for_dnd() 免打扰检查(urgent 级别不受限)
- DND 支持跨午夜窗口(如 22:00-08:00)
- 新增 consultation.new_message 事件(患者发消息通知医生)
- 新增 lab_report.reviewed 事件(报告审核完成通知患者)
- 改进已有事件:预约确认含日期、随访逾期含患者名
积分前端补充:
- points.ts 新增 OfflineEvent/EventRegistration 接口 + API
- 新增线下活动列表页面(报名/人数/积分奖励)
- 注册 events 页面路由
|
2026-04-26 13:43:54 +08:00 |
|
iven
|
9f546a519b
|
feat(web): 三级可折叠侧边栏菜单 — 健康管理 18 项归入 6 个子分组
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 新增 CollapsibleSubGroup 组件,支持子分组的展开/折叠渲染
- DynamicMenuSection 改为递归检测子目录,支持多级嵌套
- 当前路径所在子分组自动展开
- 折叠侧边栏时子分组显示为图标 + Tooltip
- 兼容 menu_type='page' 类型
- 数据库插入 6 个子分组(患者医护/预约排班/随访咨询/积分运营/内容运营/AI 分析)
|
2026-04-26 13:37:57 +08:00 |
|
iven
|
3723cd93c0
|
feat(miniprogram): 医护端小程序页面 — 8 页面覆盖患者/咨询/随访/报告
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
Iteration 2 医护端前端核心页面:
- 新增 doctor.ts service 层(仪表盘/患者/咨询/随访/报告 API)
- 升级医生首页:接入真实仪表盘数据 + 快捷操作入口
- 患者管理:搜索 + 标签筛选 + 详情页(基本信息/过敏史/健康概览)
- 咨询回复:会话列表 + 状态筛选 + 聊天详情 + 发送消息 + 关闭会话
- 随访管理:任务列表 + 状态筛选 + 详情 + 填写随访记录
- 报告解读:化验报告列表 + 异常高亮 + 指标表格 + 医生审核注释
- 修复 login 页面重复解构
- 注册 8 个新页面路由到 app.config.ts
|
2026-04-26 13:32:08 +08:00 |
|
iven
|
a0b72b0f73
|
feat: Iteration 1 — 审计日志IP记录、文件上传、医护端API、小程序角色切换
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
Iteration 1 六项任务全部完成:
1. 审计日志IP记录 — task_local RequestInfo 自动注入 IP/user_agent
2. 文件上传服务 — multipart 上传 + ServeDir 静态文件服务
3. 医护端后端API — 医生工作台仪表盘 + 患者标签CRUD + 会话已读
4. 小程序角色切换 — 登录后根据角色跳转医护台/患者首页
5. 小程序安全加固 — secure-storage 开发模式警告
6. 讨论记录归档 — docs/discussions/
|
2026-04-26 13:13:25 +08:00 |
|
iven
|
17b423b9b8
|
feat(health): 内容管理模块 — 审核/分类/标签/富文本编辑器
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
后端:
- 文章审核状态机:draft → pending_review → published(含 reject/unpublish)
- 文章分类 CRUD(article_category entity + service + handler)
- 文章标签 CRUD(article_tag + article_article_tag 关联)
- 文章修订版快照(article_revision)
- 阅读计数、排序、slug、审核备注
- 新增 health.articles.review 权限
前端:
- ArticleManageList:状态标签页 + 分类筛选 + 关键字搜索 + 审核操作
- ArticleEditor:Wangeditor 富文本编辑器 + 元数据侧栏
- ArticleCategoryManage:分类 CRUD + 父子层级
- ArticleTagManage:标签 CRUD
修复:
- diagnosis_service/health_data_service/dialysis_service: 补充 key_version 字段
- ArticleCategoryManage: 补充 Select 组件导入
|
2026-04-26 12:51:30 +08:00 |
|
iven
|
2a7c3ceeb7
|
feat(web): 多指标趋势图重设计 — 概览卡片条 + 点击展开详情图
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
交互模式: 水平概览卡片条(指标名+最新值+32px微型趋势线) →
点击展开200px详情折线图(坐标轴+tooltip+关闭按钮)
5项指标独立Y轴,解决量级差异问题(血压~120 vs 血糖~5)
|
2026-04-26 12:21:56 +08:00 |
|
iven
|
a6d2426f04
|
feat(web): 趋势图多指标展示 — 5项体征指标迷你趋势卡片网格
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
收缩压/舒张压/心率/体重/血糖各一个迷你 Line 图,
并行加载、无数据指标显示空状态,录入后自动刷新
|
2026-04-26 10:24:57 +08:00 |
|
iven
|
d245499e34
|
fix(web): 新增体征数据后趋势图自动刷新
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
VitalSignsChart 增加 refreshKey prop,录入成功后递增触发 useEffect 重新加载趋势数据
|
2026-04-26 09:46:53 +08:00 |
|
iven
|
1f8fd0465d
|
fix(health): 趋势图数据不显示 — 后端 DTO 元组→结构体 + 前端解包修复
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 后端 IndicatorTimeseriesResp.data 从 Vec<(NaiveDate, f64)> 改为 Vec<DataPoint>
解决 JSON 序列化为数组而非对象导致前端无法识别的问题
- 前端 VitalSignsChart 正确解包 API 返回的 { indicator, data } 响应结构
- 移除趋势图无用的指标下拉选择器,固定显示收缩压(晨)趋势
- 修复 PatientDetail Card body padding 三层嵌套空白问题
|
2026-04-26 09:35:05 +08:00 |
|
iven
|
6c60be0047
|
feat(web): 体征数据页面 UI/UX 优化 — 消除空白+信息密度提升
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
VitalSignsChart:
- 空状态改为带图标的虚线提示区域(替代 Empty 组件大片空白)
- 图表高度约束 180px,加载状态居中显示
- 添加最新值摘要显示
- 头部选择器与摘要信息并排布局
VitalSignsTab:
- 添加最新记录摘要条(体征数据一览)
- 表格上方显示记录总数
- 表头列名带 Tooltip 说明
- 录入按钮改为 small size,节省空间
- 表格添加 scroll.x 防止列溢出
|
2026-04-26 08:08:05 +08:00 |
|
iven
|
c76371fbdc
|
fix(web): 体征数据图表高度约束 — 消除大片空白
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
VitalSignsChart 的 Line 组件添加 height: 220 显式约束,
并用 div 包裹防止容器撑开导致页面大片空白
|
2026-04-26 08:04:53 +08:00 |
|
iven
|
e3177f262c
|
feat(config): 菜单动态化改造 — 侧边栏从后端 API 加载
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 新增 seed 迁移插入完整菜单树(4 directory + 23 menu = 27 条)
- 新增 GET /api/v1/menus/user 端点(仅需登录,无需 menu.list 权限)
- MainLayout 从 API 动态获取菜单树替换硬编码数组
- 扩展图标映射表覆盖 22 个 Ant Design 图标
- Header 标题从动态菜单数据查找,保留 fallback
|
2026-04-26 01:55:01 +08:00 |
|
iven
|
2539e5fc44
|
fix(web): 系统设置 CRUD 修复 — version 乐观锁 + 语言字段映射 + JSON 显示
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- API 层所有 Info/Request 接口添加 version 字段,update 函数传递 version
- delete 函数改为 client.delete(url, { data: { version } }) 发送 JSON body
- LanguageInfo.enabled → is_active,匹配后端 LanguageResp 字段名
- LanguageManager 编辑弹窗简化为只读详情(后端仅支持 is_active 切换)
- SystemSettings 设置值显示改用 JSON.stringify 而非 String()
- SystemSettings updateSetting 发送解析后的 JSON 对象而非字符串
|
2026-04-26 01:28:13 +08:00 |
|
iven
|
b4735213c5
|
feat(health): Phase 1 业务改进 — 诊断编码/统计API/体征表合并/积分修复
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
1.1 Dashboard 统计: 新增 3 个统计端点 (patient/consultation/follow-up)
1.2 事件发布: follow_up.overdue + health_data.critical_alert 事件
1.3 体征表合并: vital_signs 添加 source 列, daily_monitoring 委托写入
1.4 实时预警: 创建体征时检测血压/心率/血糖异常并发布事件
1.5 诊断编码: 新建 diagnosis entity/service/handler + ICD-10 支持
1.6 积分过期: expire_points 定时任务 + 修复 r#type 列名问题
修复: points_transaction.r#type → transaction_type 列重命名
修复: consultation_message.sender_type → sender_role SQL 列名
前端: 3 个统计 API 从伪实现改为真实调用
|
2026-04-26 00:54:56 +08:00 |
|
iven
|
98de5ad3b9
|
feat(miniprogram): AI 报告查看 — 列表页/详情页/首页入口
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- AI 分析 API service (ai-analysis.ts)
- 报告列表页: 滚动加载 + 状态标签 + 点击详情
- 报告详情页: Markdown 转 HTML + RichText 渲染
- app.config.ts 注册路由
- 首页添加 AI 报告快捷入口
|
2026-04-25 23:53:01 +08:00 |
|
iven
|
5621dbe273
|
feat(web): AI 管理端 3 页面 — Prompt/分析历史/用量统计
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- API 封装: prompts.ts / analysis.ts / usage.ts
- AiPromptList: CRUD + 激活/回滚 + AuthButton 权限
- AiAnalysisList: 历史列表 + 行展开查看结果
- AiUsageDashboard: 总次数/类型分布统计卡片
- 菜单注册 + 路由配置 (MainLayout + App.tsx)
|
2026-04-25 23:44:15 +08:00 |
|
iven
|
69313a177e
|
feat(web): 健康模块 13 页面按钮级权限控制 — AuthButton 包装
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
使用 AuthButton 声明式组件包装健康模块全部操作按钮:
- health.patient.manage: PatientList/PatientDetail/PatientTagManage
- health.appointment.manage: AppointmentList
- health.doctor.manage: DoctorList/DoctorSchedule
- health.follow-up.manage: FollowUpTaskList
- health.consultation.manage: ConsultationList/ConsultationDetail
- health.points.manage: OfflineEventList/PointsProductList/PointsOrderList/PointsRuleList
|
2026-04-25 23:33:32 +08:00 |
|
iven
|
d6420f4e27
|
feat(web): 添加 usePermission hook + AuthButton/AuthGuard 声明式权限组件
|
2026-04-25 23:24:02 +08:00 |
|
iven
|
9f25112861
|
feat(web): auth store 添加 permissions 状态,从 JWT 解码提取
|
2026-04-25 23:23:28 +08:00 |
|
iven
|
72592d3d77
|
fix(web): 链路测试修复 — 健康记录枚举 + 预约名称解析
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- HealthRecordsTab: record_type 从自由文本 Input 改为 Select 枚举
(checkup/outpatient/inpatient → 体检/门诊/住院),匹配后端校验规则
- AppointmentList: 添加批量患者/医生名称解析,列表不再显示截断 UUID
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
|
2026-04-25 22:38:46 +08:00 |
|
iven
|
d2baacae7e
|
feat(health): Phase 4 跨模块集成与架构优化 — 通知/标签/待办/数据录入
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
后端:
- erp-message: 添加 appointment.created/confirmed/cancelled 事件监听,自动发送站内通知
- erp-health: 新增 GET /health/patient-tags 标签列表端点 + list_tags service
- wechat-templates: 添加 isTemplateConfigured 运行时校验
前端:
- 新增 Zustand useHealthStore 共享患者/医生名称缓存
- PatientTagManage: UUID 输入替换为 Checkbox 标签选择器
- VitalSignsTab: 添加体征数据录入 Modal (血压/心率/体重/血糖)
- LabReportsTab: 添加化验报告创建 Modal
- HealthRecordsTab: 添加健康记录创建 Modal
- patients API: 添加 TagItem 类型 + listTags 方法
小程序:
- 首页待办事项接入预约和随访 API,替换硬编码 EmptyState
|
2026-04-25 20:10:50 +08:00 |
|
iven
|
5b520a168c
|
fix(web): Phase 3 前端 UX/i18n 修复 — 名称解析/确认对话框/日历切换/删除替换
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- ConsultationList: 批量解析患者/医生名称替代截断 UUID
- PointsOrderList: 使用 product_name + 批量解析患者/核销人名称
- AppointmentList: 破坏性状态变更添加 Modal.confirm + 取消原因收集
- CalendarView: 添加 onPanelChange 回调支持月份切换
- DoctorSchedule: 日历视图切换月份自动刷新数据
- PointsRuleList: 移除无效删除按钮,Switch 添加启用/停用文字
- PointsProductList: 删除按钮替换为上架/下架 Switch
- PatientSelect: 性别显示中文化 (male→男, female→女)
- VitalSignsChart: API 失败时显示 Alert 错误提示
- PointsOrder 类型: 添加 product_name 字段
|
2026-04-25 19:49:25 +08:00 |
|
iven
|
17085a3e61
|
fix(health): P1 功能缺陷修复 — 8 项后端+小程序问题
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 管理员订单列表:新增 admin_list_orders 不按 patient_id 过滤
- 分配医生:添加 doctor_profile 存在性验证防止孤立关联
- 标签管理:将软删除+插入包裹在事务中防止标签丢失
- HealthDataProvider:标记为 experimental,改进错误消息
- 预约 CAS:添加注释说明匹配字段与唯一索引的关系
- 小程序 DTO:inputVitalSign 映射 indicator_type 到结构化字段
- 小程序数据隔离:listAppointments/listTasks 添加 patient_id 参数
- 小程序字段名:family-add 修复 birthday → birth_date
|
2026-04-25 19:37:35 +08:00 |
|
iven
|
280f65658a
|
feat: 积分商城子页面 + 日常监测 + 统计报表 (Chunk 6)
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
小程序 — 积分商城 (3 新页面):
- mall/exchange: 兑换确认 (余额校验/QR码生成)
- mall/orders: 我的订单 (状态筛选/分页/QR展示)
- mall/detail: 积分明细 (余额卡片/收入支出筛选/流水列表)
小程序 — 上报 Tab 改造:
- health/daily-monitoring: 日常监测表单 (血压/体重/血糖/出入量)
- health/index: 增加快捷操作/打卡状态/近期监测卡片
- consultation: 替换占位为咨询列表 (会话/状态/未读)
- profile: 新增积分余额/打卡天数/我的订单/积分明细入口
小程序 — 新增服务:
- services/consultation.ts: 咨询会话 API
- services/points.ts: 扩展兑换/订单/流水 API
- services/health.ts: 扩展日常监测 API
PC 管理端:
- StatisticsDashboard: 统计报表仪表盘 (患者/咨询/随访/积分卡片 + Top10排行 + 快速链接)
- 侧边栏新增统计报表入口 (健康模块首页)
|
2026-04-25 19:17:11 +08:00 |
|
iven
|
1507ec6036
|
feat(miniprogram): TabBar 重构 + 积分商城页面 (Chunk 5)
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
TabBar: 首页|健康|预约|资讯|我的 → 首页|上报|咨询|商城|我的
新增页面:
- 商城(mall): 积分余额卡片 + 签到 + 商品网格(分类型筛选/分页)
- 咨询(consultation): 占位页(即将上线)
新增服务:
- services/points.ts: 积分账户/签到/商品列表 API
API: getAccount, dailyCheckin, getCheckinStatus, listProducts
|
2026-04-25 17:44:24 +08:00 |
|
iven
|
7b18a7398d
|
feat(health): 线下活动管理端 CRUD + 积分统计 API + 前端页面 (Chunk 4)
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
后端:
- 线下活动管理: create/update/delete/list/checkin 5 个管理端接口
- 活动签到自动发放积分 (事务内原子操作)
- 积分统计 API: 总发放/总消耗/总过期/活跃账户/Top10排行
前端:
- OfflineEventList: 活动管理页面 (创建/编辑/删除/状态筛选)
- points.ts 扩展: 线下活动 + 统计 API 方法
- 侧边栏新增线下活动入口
|
2026-04-25 17:34:54 +08:00 |
|
iven
|
eb937d3d02
|
feat(health): 日常监测后端 + 积分商城 PC 管理页面 (Chunk 3 V2 迭代)
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
后端 - 日常监测:
- 新增 daily_monitoring 表 (血压/体重/血糖/出入量/备注)
- Entity/DTO/Service/Handler 完整 CRUD
- 唯一约束 (patient_id, record_date) 防重复上报
前端 - 积分商城管理 (3 页面):
- PointsRuleList: 积分规则增删改 + 启用禁用
- PointsProductList: 商品管理 + 库存 + 类型筛选
- PointsOrderList: 订单列表 + 扫码核销
- API 模块 points.ts 对接 6 个管理端接口
- 侧边栏新增积分规则/商品管理/订单管理入口
|
2026-04-25 17:24:32 +08:00 |
|
iven
|
355e8da272
|
fix(health): 全链路流通性验证修复
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 创建 stub migration 解决缺失文件报错
- PatientList/PatientDetail: DatePicker dayjs 对象序列化为 YYYY-MM-DD
- AppointmentList: 预约类型与后端验证对齐(outpatient/recheck/health_checkup/consultation/dialysis)
- AppointmentList: 医生字段改为必填(后端 CAS 排班要求), destroyOnClose→destroyOnHidden
- Home.tsx: 补充审计日志 action 翻译(created/login_failed 等)
全链路验证通过: 医生CRUD→排班→预约创建+状态流转→随访生命周期→咨询会话+消息→患者详情+健康数据
|
2026-04-25 11:31:54 +08:00 |
|
iven
|
7a2d8e4664
|
fix(web): 前端功能验证修复 — 移除硬编码假数据/修正系统信息/修复dev.ps1环境变量
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- refactor(Home): 待办任务改为从工作流API获取真实数据
- refactor(Home): 最近动态改为从审计日志API获取真实操作记录
- refactor(Home): 移除硬编码的sparkline趋势图和假统计数据
- fix(Home): 系统信息 PostgreSQL 16→18,模块数量 5→6
- fix(Login): 移除硬编码版本号 v0.1.0
- fix(MainLayout): Footer 更新为 "HMS 健康管理平台"
- fix(dev.ps1): 添加缺失的 WECHAT/HEALTH 环境变量
|
2026-04-25 10:53:58 +08:00 |
|
iven
|
0bf1822fa9
|
fix: QA 第二轮修复 — PatientDetail 重构/测试覆盖/id_number 列宽/小程序 URL 规范化
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- refactor(web): PatientDetail.tsx 拆分为 4 个子组件(737→334行)
- refactor(web): 提取 usePaginatedData hook 消除重复分页状态
- feat(db): patient.id_number varchar(20)→varchar(255) 容纳加密值
- test(health): 添加预约模块集成测试(创建/列表/租户隔离)
- test(plugin): 添加 6 个 SQL 注入 sanitize 测试
- fix(miniprogram): 7 个 service 文件 URL 构建规范化(params 对象)
- fix(miniprogram): 跨平台字段名对齐(birth_date/start_time/end_time)
|
2026-04-25 10:22:44 +08:00 |
|
iven
|
55a3fd32d0
|
test(web): 添加 vitest 单元测试基础设施和初始测试用例
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 安装 vitest + @testing-library/react + @testing-library/jest-dom + jsdom
- 创建 vitest.config.ts (jsdom 环境, 全局 API, e2e 目录排除)
- 创建 test/setup.ts (@testing-library/jest-dom 匹配器)
- 添加 29 个测试用例: health 常量 (14), useThemeMode hook (2), StatusTag 组件 (13)
|
2026-04-25 10:11:30 +08:00 |
|
iven
|
945ccd64ba
|
fix: 全面 QA 审计修复 — 安全加固/代码质量/跨平台一致性/测试覆盖
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
Phase 0 安全热修复 (CRITICAL):
- 外部化微信 appid/secret 到 ERP__WECHAT__APPID/SECRET 环境变量
- 正确连接 HealthCrypto 到 ERP__HEALTH__AES_KEY/HMAC_KEY 环境变量
- 外部化小程序加密密钥到 TARO_APP_ENCRYPTION_KEY 环境变量
- 移除小程序 auth store 中的敏感信息 console.log
Phase 1 安全加固:
- 微信自动注册 display_name 添加 sanitize 防止 XSS
- 测试数据库凭据改为从 TEST_DB_URL 环境变量读取
Phase 2 代码质量:
- 提取 useThemeMode hook 消除 22 处重复暗色模式检测
- 提取共享健康常量到 constants/health.ts
- 拆分 patient_service.rs 脱敏函数到 masking.rs
- 移除未使用的 i18next/react-i18next 依赖
- 移除未使用的 api/errors.ts 和 erp-auth/anyhow 依赖
Phase 3 测试覆盖:
- 新增 5 个患者模块集成测试 (CRUD/租户隔离/验证/软删除)
Phase 4 跨平台一致性:
- 统一小程序 Patient.birthday → birth_date 匹配后端
- 统一小程序 Appointment.time_slot → start_time/end_time 匹配后端
Phase 5 架构:
- 微信登录添加多租户 TODO 注释
- 更新 wiki/infrastructure.md 环境变量文档
|
2026-04-25 10:00:49 +08:00 |
|
iven
|
07f4ba41ba
|
fix(health): 穷尽审计修复 — 权限同步/编译错误/前端bug/审计日志
CI / frontend-build (push) Has been cancelled
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / security-audit (push) Has been cancelled
审计发现并修复的问题:
HIGH:
- H1: ConsultationDetail 使用 getSession(id) 替代错误的列表搜索
- H2: SessionResp 添加 version/updated_at 字段
- H3: 移除 FollowUpRecordList 调用不存在的导出端点
- H4: 新增 articles.ts 前端 API 模块
MEDIUM:
- M1: article delete 添加乐观锁 (expected_version)
- M2: 取消预约排班释放传播错误 (log::warn -> ?)
- M3: FollowUpTaskList 日期格式 Dayjs -> string
- M4: 补充 15 个缺失审计日志
LOW:
- L1: 替换 follow_up_service 中的 .unwrap()
- L2: PatientListItem 添加 version 字段
CRITICAL (新发现):
- 权限未同步: 健康模块 14 个权限从未写入数据库,添加启动时自动同步
- migration 表名错误: patients -> patient
- 编译错误: health_trend entity 未导入, ToPrimitive trait 未导入
- HealthError 缺少 From<AppError> 实现
|
2026-04-25 08:58:58 +08:00 |
|
iven
|
0c21f13e72
|
feat(web): 健康管理模块 10 页面完整实现
CI / security-audit (push) Has been cancelled
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
Task 12 - 患者管理:
- PatientList: 搜索+状态筛选+CRUD+行点击跳转详情
- PatientTagManage: 患者标签管理+批量打标
- PatientDetail: 3Tab详情页(基本信息/健康数据/随访记录)+编辑
Task 13 - 医护预约:
- DoctorList: 科室筛选+CRUD+在线状态Badge
- AppointmentList: 状态筛选+日期筛选+创建预约+状态流转
- DoctorSchedule: 医生选择+列表/日历视图+排班CRUD
Task 14 - 随访咨询:
- FollowUpTaskList: 任务CRUD+填写记录+分配医护
- FollowUpRecordList: 只读台账+日期范围筛选+导出
- ConsultationList: 会话列表+创建+关闭+行点击跳转
- ConsultationDetail: 聊天界面+消息分页+发送+图片预览
修正: consultations.ts Session类型补充 updated_at/version
|
2026-04-25 00:57:48 +08:00 |
|
iven
|
cdbf381060
|
feat(web): 路由和菜单集成 + 10 页面占位
CI / security-audit (push) Has been cancelled
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
- App.tsx 添加 10 条 lazy 路由(患者/医护/预约/随访/咨询)
- MainLayout.tsx 添加健康管理菜单组(7 项菜单 + 10 条标题映射)
- 创建 10 个页面占位组件
|
2026-04-25 00:42:12 +08:00 |
|
iven
|
6296ce22d2
|
feat(web): 健康模块通用组件 8 个
- StatusTag: 通用状态标签(预约/随访/咨询/患者状态)
- PatientSelect: 患者远程搜索选择器
- DoctorSelect: 医护远程搜索选择器
- VitalSignsChart: ECharts 趋势图(可切换指标)
- CalendarView: 日历视图(排班展示)
- ChatBubble: 聊天气泡(角色区分左右布局)
- ImagePreview: 图片预览(Ant Design Image.PreviewGroup)
- ExportButton: 导出按钮(blob 下载)
|
2026-04-25 00:40:11 +08:00 |
|
iven
|
778ae79d84
|
feat(web): 健康模块 API 服务层 6 文件 47 端点
- patients.ts: 患者CRUD/标签/家庭/医护关联 14端点
- healthData.ts: 体征/化验/健康档案CRUD + 趋势 18端点
- appointments.ts: 预约CRUD + 排班管理 + 日历 8端点
- followUp.ts: 随访任务/记录CRUD 7端点
- consultations.ts: 咨询会话/消息CRUD + 导出 6端点
- doctors.ts: 医护CRUD 5端点
|
2026-04-25 00:37:59 +08:00 |
|
iven
|
a63043f447
|
fix(miniprogram): 深度审查修复多个功能问题
CI / security-audit (push) Has been cancelled
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
- settings: 清除缓存不再错误读取明文 token,改由 auth store restore 恢复
- appointment: 移除多余的 detail_cache Storage 写入
- reports: 未选择就诊人时显示引导提示而非空白
- health/input: 血压录入验证舒张压必填
- followups: tab 切换时不再清空列表导致闪烁
|
2026-04-24 18:36:56 +08:00 |
|
iven
|
81cc84e4b2
|
fix(miniprogram): 修复 project.config.json 配置
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
添加 miniprogramRoot: dist/ 指向 Taro 编译产物目录,
修复微信开发者工具无法加载小程序代码的问题。
更新 appid 为真实值,启用生产构建选项。
|
2026-04-24 17:47:29 +08:00 |
|
iven
|
b4e8399194
|
feat(miniprogram): 文章分享功能 onShareAppMessage
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 文章详情页注册微信分享(分享标题 + 路径带 article id)
- 分享时触发 article_share 埋点事件
|
2026-04-24 13:03:02 +08:00 |
|
iven
|
030afb8213
|
feat(miniprogram): 埋点事件追踪服务
CI / rust-check (push) Has been cancelled
CI / rust-test (push) Has been cancelled
CI / frontend-build (push) Has been cancelled
CI / security-audit (push) Has been cancelled
- 新增 analytics.ts:trackEvent/trackPageView/flushEvents
- 事件队列本地缓存,批量上报到 /analytics/batch
- 首页 page_view、预约创建、随访提交、健康数据录入四个关键埋点
|
2026-04-24 13:02:08 +08:00 |
|