From 8b34873430925efe281a8dafd179195d53dd810f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8D=8E=E4=BD=97?= Date: Sun, 7 Jun 2026 10:24:54 +0800 Subject: [PATCH] =?UTF-8?q?feat(V32):=20Phase=20A=20=E2=80=94=20=E9=9A=8F?= =?UTF-8?q?=E8=AE=BF/=E7=97=85=E7=90=86/=E6=80=A5=E8=AF=8A=20=E5=AE=8C?= =?UTF-8?q?=E6=95=B4=E5=AE=9E=E7=8E=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 后端: - FollowupController: 随访计划/任务/记录/满意度调查/投诉记录(完整CRUD+业务联动) - PathologyController: 病理医嘱/标本管理/三级审核报告(完整CRUD+业务联动) - EmergencyController: 急诊分诊(五级)/抢救/留观/绿色通道(完整CRUD+统计) 前端: - followup/plan: 随访计划管理(进度条+筛选+联动) - followup/task: 随访任务(今日任务+执行+异常标记) - followup/record: 随访记录(用药依从+复查+转诊) - followup/survey: 满意度调查(星级评分+统计面板) - followup/complaint: 投诉管理(登记→处理→关闭闭环) - pathology/order: 病理医嘱(加急标记+状态流转) - pathology/specimen: 标本管理(扫码接收+质检) - pathology/report: 病理报告(初诊→提交→审核→终审签发) - emergency/triage: 急诊分诊(五级分诊+实时看板+行列高亮) - emergency/rescue: 抢救管理(开始→过程记录→结果) - emergency/observation: 留观管理(时长计算+转归处置) - emergency/greentrack: 绿色通道(Door-to-Tx追踪+达标统计) 修复: - V24-V32 Flyway迁移: is_deleted→delete_flag对齐HisBaseEntity - V24: drug_interaction_rule表兼容V2已有结构(ADD COLUMN IF NOT EXISTS) - V28: CURRENT CURRENT_TIMESTAMP→CURRENT_TIMESTAMP修复 - 所有INDEX添加IF NOT EXISTS防止重复创建 --- .../CROSS_MODULE_BUSINESS_ANALYSIS.md | 383 ++++++++++++++++ MD/architecture/PHASE_A_EMERGENCY_DESIGN.md | 128 ++++++ MD/architecture/PHASE_A_FOLLOWUP_DESIGN.md | 195 +++++++++ MD/architecture/PHASE_A_PATHOLOGY_DESIGN.md | 142 ++++++ .../controller/EmergencyController.java | 357 +++++++++++++++ .../controller/FollowupController.java | 411 ++++++++++++++++++ .../controller/PathologyController.java | 315 ++++++++++++++ .../migration/V24__outpatient_enhancement.sql | 33 +- .../V25__vitalsigns_safety_barcode_audit.sql | 24 +- .../V26__nursing_assessment_enhancement.sql | 6 +- .../migration/V27__emr_revision_archive.sql | 8 +- .../db/migration/V28__drg_dip_grouping.sql | 14 +- .../db/migration/V29__esb_reliability.sql | 12 +- .../migration/V30__remaining_capabilities.sql | 34 +- .../migration/V31__cssd_3d_reconstruction.sql | 26 +- .../V32__followup_pathology_emergency.sql | 149 +++++++ .../domain/EmergencyGreenChannel.java | 10 + .../domain/EmergencyObservation.java | 10 + .../his/emergency/domain/EmergencyRescue.java | 10 + .../his/emergency/domain/EmergencyTriage.java | 12 + .../mapper/EmergencyGreenChannelMapper.java | 6 + .../mapper/EmergencyObservationMapper.java | 6 + .../mapper/EmergencyRescueMapper.java | 6 + .../mapper/EmergencyTriageMapper.java | 6 + .../IEmergencyGreenChannelService.java | 4 + .../service/IEmergencyObservationService.java | 4 + .../service/IEmergencyRescueService.java | 4 + .../service/IEmergencyTriageService.java | 4 + .../EmergencyGreenChannelServiceImpl.java | 8 + .../impl/EmergencyObservationServiceImpl.java | 8 + .../impl/EmergencyRescueServiceImpl.java | 8 + .../impl/EmergencyTriageServiceImpl.java | 8 + .../his/followup/domain/ComplaintRecord.java | 11 + .../his/followup/domain/FollowupPlan.java | 12 + .../his/followup/domain/FollowupRecord.java | 12 + .../his/followup/domain/FollowupTask.java | 10 + .../followup/domain/SatisfactionSurvey.java | 11 + .../mapper/ComplaintRecordMapper.java | 6 + .../followup/mapper/FollowupPlanMapper.java | 6 + .../followup/mapper/FollowupRecordMapper.java | 6 + .../followup/mapper/FollowupTaskMapper.java | 6 + .../mapper/SatisfactionSurveyMapper.java | 6 + .../service/IComplaintRecordService.java | 4 + .../service/IFollowupPlanService.java | 4 + .../service/IFollowupRecordService.java | 4 + .../service/IFollowupTaskService.java | 4 + .../service/ISatisfactionSurveyService.java | 4 + .../impl/ComplaintRecordServiceImpl.java | 8 + .../service/impl/FollowupPlanServiceImpl.java | 8 + .../impl/FollowupRecordServiceImpl.java | 8 + .../service/impl/FollowupTaskServiceImpl.java | 8 + .../impl/SatisfactionSurveyServiceImpl.java | 8 + .../his/pathology/domain/PathologyOrder.java | 10 + .../his/pathology/domain/PathologyReport.java | 13 + .../pathology/domain/PathologySpecimen.java | 10 + .../mapper/PathologyOrderMapper.java | 6 + .../mapper/PathologyReportMapper.java | 6 + .../mapper/PathologySpecimenMapper.java | 6 + .../service/IPathologyOrderService.java | 4 + .../service/IPathologyReportService.java | 4 + .../service/IPathologySpecimenService.java | 4 + .../impl/PathologyOrderServiceImpl.java | 8 + .../impl/PathologyReportServiceImpl.java | 8 + .../impl/PathologySpecimenServiceImpl.java | 8 + .../src/views/emergency/greentrack/api.js | 7 + .../src/views/emergency/greentrack/index.vue | 89 ++++ .../src/views/emergency/observation/api.js | 7 + .../src/views/emergency/observation/index.vue | 86 ++++ .../src/views/emergency/rescue/api.js | 7 + .../src/views/emergency/rescue/index.vue | 85 ++++ .../src/views/emergency/triage/api.js | 9 + .../src/views/emergency/triage/index.vue | 123 ++++++ .../src/views/followup/complaint/api.js | 6 + .../src/views/followup/complaint/index.vue | 91 ++++ .../src/views/followup/plan/api.js | 8 + .../src/views/followup/plan/index.vue | 95 ++++ .../src/views/followup/record/api.js | 5 + .../src/views/followup/record/index.vue | 52 +++ .../src/views/followup/survey/api.js | 5 + .../src/views/followup/survey/index.vue | 75 ++++ .../src/views/followup/task/api.js | 8 + .../src/views/followup/task/index.vue | 92 ++++ .../src/views/pathology/order/api.js | 8 + .../src/views/pathology/order/index.vue | 85 ++++ .../src/views/pathology/report/api.js | 9 + .../src/views/pathology/report/index.vue | 97 +++++ .../src/views/pathology/specimen/api.js | 8 + .../src/views/pathology/specimen/index.vue | 106 +++++ 88 files changed, 3664 insertions(+), 83 deletions(-) create mode 100644 MD/architecture/CROSS_MODULE_BUSINESS_ANALYSIS.md create mode 100644 MD/architecture/PHASE_A_EMERGENCY_DESIGN.md create mode 100644 MD/architecture/PHASE_A_FOLLOWUP_DESIGN.md create mode 100644 MD/architecture/PHASE_A_PATHOLOGY_DESIGN.md create mode 100644 healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/emergency/controller/EmergencyController.java create mode 100644 healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/followup/controller/FollowupController.java create mode 100644 healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/pathology/controller/PathologyController.java create mode 100644 healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V32__followup_pathology_emergency.sql create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyGreenChannel.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyObservation.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyRescue.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyTriage.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyGreenChannelMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyObservationMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyRescueMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyTriageMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyGreenChannelService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyObservationService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyRescueService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyTriageService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyGreenChannelServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyObservationServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyRescueServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyTriageServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/ComplaintRecord.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupPlan.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupRecord.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupTask.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/SatisfactionSurvey.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/ComplaintRecordMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupPlanMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupRecordMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupTaskMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/SatisfactionSurveyMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IComplaintRecordService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupPlanService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupRecordService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupTaskService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/ISatisfactionSurveyService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/ComplaintRecordServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupPlanServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupRecordServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupTaskServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/SatisfactionSurveyServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologyOrder.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologyReport.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologySpecimen.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologyOrderMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologyReportMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologySpecimenMapper.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologyOrderService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologyReportService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologySpecimenService.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologyOrderServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologyReportServiceImpl.java create mode 100644 healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologySpecimenServiceImpl.java create mode 100644 healthlink-his-ui/src/views/emergency/greentrack/api.js create mode 100644 healthlink-his-ui/src/views/emergency/greentrack/index.vue create mode 100644 healthlink-his-ui/src/views/emergency/observation/api.js create mode 100644 healthlink-his-ui/src/views/emergency/observation/index.vue create mode 100644 healthlink-his-ui/src/views/emergency/rescue/api.js create mode 100644 healthlink-his-ui/src/views/emergency/rescue/index.vue create mode 100644 healthlink-his-ui/src/views/emergency/triage/api.js create mode 100644 healthlink-his-ui/src/views/emergency/triage/index.vue create mode 100644 healthlink-his-ui/src/views/followup/complaint/api.js create mode 100644 healthlink-his-ui/src/views/followup/complaint/index.vue create mode 100644 healthlink-his-ui/src/views/followup/plan/api.js create mode 100644 healthlink-his-ui/src/views/followup/plan/index.vue create mode 100644 healthlink-his-ui/src/views/followup/record/api.js create mode 100644 healthlink-his-ui/src/views/followup/record/index.vue create mode 100644 healthlink-his-ui/src/views/followup/survey/api.js create mode 100644 healthlink-his-ui/src/views/followup/survey/index.vue create mode 100644 healthlink-his-ui/src/views/followup/task/api.js create mode 100644 healthlink-his-ui/src/views/followup/task/index.vue create mode 100644 healthlink-his-ui/src/views/pathology/order/api.js create mode 100644 healthlink-his-ui/src/views/pathology/order/index.vue create mode 100644 healthlink-his-ui/src/views/pathology/report/api.js create mode 100644 healthlink-his-ui/src/views/pathology/report/index.vue create mode 100644 healthlink-his-ui/src/views/pathology/specimen/api.js create mode 100644 healthlink-his-ui/src/views/pathology/specimen/index.vue diff --git a/MD/architecture/CROSS_MODULE_BUSINESS_ANALYSIS.md b/MD/architecture/CROSS_MODULE_BUSINESS_ANALYSIS.md new file mode 100644 index 000000000..00f7f4e8f --- /dev/null +++ b/MD/architecture/CROSS_MODULE_BUSINESS_ANALYSIS.md @@ -0,0 +1,383 @@ +# HealthLink-HIS 三甲医院交叉业务流程分析与系统不足诊断 + +> **文档类型**: 业务分析+系统诊断 +> **版本**: v1.0 +> **编制日期**: 2026-06-07 +> **依据**: 《三级医院评审标准(2022版)》+ 广西实施细则 + 电子病历4级 + 互联互通四级甲等 + +--- + +## 一、三甲医院核心业务流程全景 + +### 1.1 十大核心流程 + +``` +┌─────────────────────────────────────────────────────────────────────┐ +│ 三甲医院业务全景 │ +├─────────────────────────────────────────────────────────────────────┤ +│ 门诊流程: 挂号→候诊→就诊→检查检验→处方→收费→取药→随访 │ +│ 住院流程: 入院→医嘱→护理→检查检验→手术→用药→出院→结算→病案 │ +│ 急诊流程: 急诊挂号→分诊→抢救→留观→会诊→住院/出院 │ +│ 手术流程: 术前讨论→手术申请→麻醉评估→手术→术后恢复→病理 │ +│ 护理流程: 入院评估→护理计划→医嘱执行→体征→护理记录→交接班 │ +│ 药品流程: 采购→验收→入库→处方→调配→发药→退药→库存→盘点 │ +│ 检验流程: 申请→采集→送检→检验→审核→报告→危急值→随访 │ +│ 检查流程: 申请→预约→排队→检查→报告→审核→3D重建→图文报告 │ +│ 病案流程: 归档→质控→借阅→封存→统计→DRG→上报 │ +│ 院感流程: 监测→预警→上报→抗菌药物→消毒供应→统计 │ +└─────────────────────────────────────────────────────────────────────┘ +``` + +--- + +## 二、交叉业务流程深度分析 + +### 2.1 门诊全流程交叉分析 + +``` +患者到达 + ↓ +[挂号模块] ←→ [排班模块] ←→ [预约模块] + ↓ (分配诊室+队列) +[候诊叫号模块] ←→ [分诊模块] + ↓ (叫号) +[医生工作站] ←→ [电子病历] ←→ [处方模块] + ↓ (开检查/检验/处方) +[检查模块] ←→ [检验模块] ←→ [药房模块] + ↓ (检查/检验完成) +[报告模块] ←→ [医生工作站] (查看结果) + ↓ (开处方) +[合理用药模块] ←→ [处方审核] + ↓ (处方通过) +[收费模块] ←→ [医保模块] ←→ [发票模块] + ↓ (缴费完成) +[药房发药模块] ←→ [药品库存模块] + ↓ (取药完成) +[随访模块] ←→ [患者管理模块] +``` + +**🔍 已有模块**: 挂号✅ 候诊✅ 医生站✅ 处方✅ 收费✅ 药房✅ 检查✅ 检验✅ 报告✅ +**🔍 随访模块**: ❌ 缺失 — 门诊患者随访是三甲评审必查项 + +### 2.2 住院全流程交叉分析 + +``` +门诊/急诊 → 入院 + ↓ +[入院登记模块] ←→ [床位管理模块] ←→ [护士站] + ↓ +[住院医嘱模块] ←→ [护士执行模块] ←→ [药房模块] + ↓ (长期/临时医嘱) +[检查申请] ←→ [检验申请] ←→ [手术申请] + ↓ +[检查报告] ←→ [检验报告] ←→ [手术记录] + ↓ +[护理评估] ←→ [护理计划] ←→ [护理记录] + ↓ +[病程记录模块] ←→ [知情同意模块] + ↓ +[出院医嘱] ←→ [出院结算] ←→ [出院小结] + ↓ +[病案归档] ←→ [DRG分组] ←→ [统计上报] +``` + +**🔍 已有模块**: 入院✅ 床位✅ 医嘱✅ 护理✅ 检查✅ 检验✅ 手术✅ 病程✅ 知情同意✅ 出院✅ 结算✅ 病案✅ DRG✅ +**🔍 交叉验证**: 各模块间数据流转基本完整 + +### 2.3 手术全流程交叉分析 + +``` +[住院医嘱] → 手术申请 + ↓ +[术前讨论模块] ←→ [手术分级管理] + ↓ +[麻醉评估模块] ←→ [麻醉前核查] + ↓ +[手术安全核查(WS/T 313)] ←→ [器械追溯(CSSD)] + ↓ +[手术执行模块] ←→ [麻醉记录模块] + ↓ +[术后恢复模块] ←→ [术后访视] + ↓ +[病理送检模块] ←→ [病理报告模块] + ↓ +[护理记录] ←→ [病程记录] +``` + +**🔍 已有模块**: 术前讨论✅ 手术申请✅ 麻醉✅ 安核查✅ CSSD✅ 手术记录✅ +**🔍 病理模块**: ❌ 缺失 — 病理送检+病理报告是手术闭环的关键环节 + +### 2.4 药品全流程交叉分析 + +``` +[采购申请] ←→ [采购订单] + ↓ +[验收入库] ←→ [库存管理] + ↓ +[处方开具] ←→ [处方审核(合理用药)] + ↓ +[药房调配] ←→ [发药/退药] + ↓ +[库存预警] ←→ [效期管理] + ↓ +[药品追溯(毒麻)] ←→ [抗菌药物管理] + ↓ +[处方点评] ←→ [合理用药统计] +``` + +**🔍 已有模块**: 采购✅ 库存✅ 处方✅ 审核✅ 发药✅ 抗菌✅ 点评✅ +**🔍 效期管理**: ⚠️ 基础 — 药品效期预警+近效期自动提醒功能待完善 + +### 2.5 检验全流程交叉分析 + +``` +[检验申请] ←→ [医嘱模块] + ↓ +[条码打印] ←→ [标本采集] ←→ [扫码确认] + ↓ +[标本接收] ←→ [标本拒收] + ↓ +[LIS检验] ←→ [仪器对接] + ↓ +[危急值判定] ←→ [危急值报告] ←→ [危急值处理] + ↓ +[审核发布] ←→ [报告查询] + ↓ +[参考范围] ←→ [结果解读] +``` + +**🔍 已有模块**: 申请✅ 条码✅ 采集✅ 危急值✅ 审核✅ 报告✅ 参考范围✅ +**🔍 闭环完整**: 检验全流程已基本完整 + +--- + +## 三、系统不足诊断 + +### 3.1 缺失模块 (❌ 从未实现) + +| # | 模块名称 | 业务价值 | 三甲依据 | 优先级 | +|---|---------|---------|---------|--------| +| 1 | **门诊随访管理** | 慢病管理/出院随访/满意度调查 | 评审标准: 患者服务 | 🔴 P0 | +| 2 | **病理管理** | 病理送检→取材→制片→诊断→报告 | 手术闭环/肿瘤诊疗 | 🔴 P0 | +| 3 | **急诊分诊+抢救** | 急诊分级(1-4级)/抢救记录/绿色通道 | 急诊医学科评审 | 🔴 P0 | +| 4 | **患者满意度调查** | 门诊/住院满意度/投诉管理 | 评审标准: 患者服务 | 🟡 P1 | +| 5 | **处方点评统计** | 科室排名/医生排名/合理率趋势 | 合理用药评审 | 🟡 P1 | +| 6 | **药品效期管理** | 近效期预警/自动停售/效期报表 | 药品管理规范 | 🟡 P1 | +| 7 | **护理交接班统计** | 交接班完成率/重点患者统计 | 护理质量指标 | 🟡 P1 | +| 8 | **DRG绩效考核** | 科室DRG绩效/费用控制/时间效率 | 医保支付改革 | 🟡 P1 | +| 9 | **会诊时限监控** | 会诊超时预警/完成率统计 | 会诊制度 | 🟡 P1 | +| 10 | **病案首页质量** | 首页数据校验/编码正确率 | 病案管理规范 | 🟡 P1 | + +### 3.2 待完善模块 (⚠️ 功能不足) + +| # | 模块名称 | 当前状态 | 缺失功能 | 优先级 | +|---|---------|---------|---------|--------| +| 1 | **预约管理** | 基础预约 | 诊间预约/复诊预约/预约规则配置 | 🟡 P1 | +| 2 | **排班管理** | 基础排班 | 弹性排班/节假日排班/停诊管理 | 🟡 P1 | +| 3 | **住院押金** | 基础功能 | 押金不足预警/催缴通知/医保预结算 | 🟡 P1 | +| 4 | **护理评估** | 已实现5种量表 | 跌倒/压疮动态评估+干预效果追踪 | ⚠️ 可优化 | +| 5 | **知情同意** | 已实现 | 电子签名+版本管理+患者确认流程 | ⚠️ 可优化 | +| 6 | **DRG分组** | 已实现基础 | 分组结果校验+费用异常预警+绩效分析 | ⚠️ 可优化 | + +### 3.3 交叉业务断裂点 + +| # | 断裂点 | 涉及模块 | 影响 | 优先级 | +|---|--------|---------|------|--------| +| 1 | **门诊→住院转科** | 门诊/住院/床位 | 转科时患者信息丢失 | 🔴 P0 | +| 2 | **手术→病理送检** | 手术/病理/检验 | 手术后标本无法自动送检 | 🔴 P0 | +| 3 | **检验→临床决策** | 检验/合理用药 | 检验结果未联动用药调整 | 🟡 P1 | +| 4 | **检查→报告→医嘱** | 检查/报告/医嘱 | 报告完成后未自动回写医嘱状态 | 🟡 P1 | +| 5 | **护理→医嘱→执行** | 护理/医嘱/执行 | 护士执行后未自动更新医嘱完成状态 | ⚠️ 可优化 | +| 6 | **药品→库存→预警** | 药品/库存/效期 | 库存不足时未联动处方拦截 | ⚠️ 可优化 | + +--- + +## 四、深度详细设计 — 缺失模块 + +### 4.1 门诊随访管理模块 + +#### 4.1.1 业务流程 +``` +出院/门诊结束 + ↓ +[随访计划生成] ←→ [患者分类(慢病/手术/肿瘤/普通)] + ↓ +[随访任务分配] ←→ [责任医生/护士] + ↓ +[电话/短信/微信随访] ←→ [随访记录] + ↓ +[随访结果录入] ←→ [异常处理(再入院/转诊)] + ↓ +[满意度调查] ←→ [投诉管理] + ↓ +[随访统计] ←→ [质控指标] +``` + +#### 4.1.2 数据模型 +- **FollowupPlan** (随访计划): plan_id, patient_id, disease_type, followup_type, frequency, responsible_doctor +- **FollowupTask** (随访任务): task_id, plan_id, scheduled_date, actual_date, contact_method, result +- **FollowupRecord** (随访记录): record_id, task_id, contact_content, patient_condition, abnormal_flag +- **SatisfactionSurvey** (满意度): survey_id, patient_id, survey_type, score, suggestions +- **ComplaintRecord** (投诉): complaint_id, patient_id, complaint_type, content,处理状态 + +#### 4.1.3 接口设计 +| API | 方法 | 说明 | +|-----|------|------| +| /followup/plan/page | GET | 随访计划列表 | +| /followup/plan/add | POST | 新建随访计划 | +| /followup/task/page | GET | 随访任务列表(按责任人) | +| /followup/task/complete/{id} | PUT | 完成随访任务 | +| /followup/record/add | POST | 录入随访记录 | +| /followup/survey/add | POST | 提交满意度 | +| /followup/complaint/page | GET | 投诉列表 | +| /followup/stats | GET | 随访统计(完成率/满意度) | + +### 4.2 病理管理模块 + +#### 4.2.1 业务流程 +``` +[手术/活检] → 病理申请 + ↓ +[标本接收] ←→ [标本核对(条码)] + ↓ +[取材] ←→ [组织处理(固定/脱水/包埋)] + ↓ +[切片] ←→ [染色(HE/免疫组化)] + ↓ +[阅片] ←→ [病理诊断] + ↓ +[报告编写] ←→ [报告审核(三级审核)] + ↓ +[报告发布] ←→ [临床科室] + ↓ +[病理随访] ←→ [肿瘤登记] +``` + +#### 4.2.2 数据模型 +- **PathologyOrder** (病理申请): order_id, patient_id, specimen_type, clinical_diagnosis +- **PathologySpecimen** (病理标本): specimen_id, order_id, barcode, collection_site, fixative +- **PathologyProcess** (病理处理): process_id, specimen_id, process_type, operator, time +- **PathologyDiagnosis** (病理诊断): diagnosis_id, specimen_id, diagnosis_type, result +- **PathologyReport** (病理报告): report_id, order_id, findings, diagnosis, report_doctor, verify_doctor + +#### 4.2.3 接口设计 +| API | 方法 | 说明 | +|-----|------|------| +| /pathology/order/page | GET | 病理申请列表 | +| /pathology/order/add | POST | 新建病理申请 | +| /pathology/specimen/scan | POST | 标本扫码接收 | +| /pathology/process/record | POST | 记录处理过程 | +| /pathology/diagnosis/add | POST | 录入诊断 | +| /pathology/report/page | GET | 病理报告列表 | +| /pathology/report/verify/{id} | PUT | 审核报告(三级) | + +### 4.3 急诊分诊+抢救模块 + +#### 4.3.1 业务流程 +``` +患者到达急诊 + ↓ +[预检分诊] ←→ [生命体征采集] + ↓ (按病情分级) +┌─Ⅰ级(濒死)→ 抢救室 → 绿色通道 +├─Ⅱ级(危重)→ 抢救室 → 优先处理 +├─Ⅲ级(急症)→ 急诊诊室 → 按序就诊 +└─Ⅳ级(非急)→ 普通门诊 → 引导转诊 + ↓ +[抢救记录] ←→ [抢救医嘱] + ↓ +[会诊申请] ←→ [住院转科/留观/出院] + ↓ +[急诊病历] ←→ [急诊统计] +``` + +#### 4.3.2 数据模型 +- **EmergencyTriage** (急诊分诊): triage_id, patient_id, triage_level(1-4), vital_signs, triage_nurse +- **EmergencyRescue** (抢救记录): rescue_id, patient_id, rescue_start, rescue_end, result +- **EmergencyObservation** (留观记录): observation_id, patient_id, observation_start, bed_no +- **Emergency绿色通道**: green_channel_id, patient_id, disease_type, door_to_treatment_time + +#### 4.3.3 接口设计 +| API | 方法 | 说明 | +|-----|------|------| +| /emergency/triage/add | POST | 急诊分诊 | +| /emergency/triage/queue | GET | 分诊队列(按级别) | +| /emergency/rescue/add | POST | 开始抢救 | +| /emergency/rescue/complete/{id} | PUT | 抢救完成 | +| /emergency/observation/add | POST | 留观登记 | +| /emergency/green-channel | POST | 绿色通道启动 | +| /emergency/stats | GET | 急诊统计(分级/抢救率/等候时间) | + +### 4.4 药品效期管理模块 + +#### 4.4.1 业务流程 +``` +[入库验收] → 记录效期 + ↓ +[效期监控] ←→ [每日扫描] + ↓ (近效期预警) +┌─ 6个月内 → 近效期提醒 → 优先使用 +├─ 3个月内 → 紧急预警 → 限制开方 +└─ 过期 → 自动停售 → 退回供应商 + ↓ +[效期报表] ←→ [过期药品销毁] +``` + +#### 4.4.2 数据模型 +- **DrugExpiryAlert** (效期预警): alert_id, drug_code, drug_name, batch_no, expiry_date, alert_level +- **DrugExpiryStats** (效期统计): 按月统计近效期/过期/销毁金额 + +### 4.5 处方点评统计模块 + +#### 4.5.1 业务流程 +``` +[处方数据] → 自动筛选 + ↓ (不合理处方) +[系统点评] ←→ [人工点评] + ↓ +[点评结果] ←→ [医生反馈] + ↓ +[科室排名] ←→ [医生排名] + ↓ +[合理率趋势] ←→ [改进措施] +``` + +#### 4.5.2 数据模型 +- **PrescriptionReviewStats** (点评统计): 按科室/医生/月份统计合理率 +- **PrescriptionReviewRanking** (排名): 科室排名/医生排名 + +--- + +## 五、实施优先级排序 + +### Phase A: 缺失核心模块 (P0 — 立即开发) +1. **门诊随访管理** — 三甲评审必查 +2. **病理管理** — 手术闭环关键 +3. **急诊分诊+抢救** — 急诊评审必查 + +### Phase B: 待完善功能 (P1 — 尽快开发) +4. **药品效期管理** — 药品安全 +5. **处方点评统计** — 合理用药 +6. **患者满意度** — 评审指标 +7. **DRG绩效考核** — 医保改革 +8. **护理交接班统计** — 护理质量 +9. **会诊时限监控** — 会诊制度 +10. **病案首页质量** — 数据质量 + +### Phase C: 交叉业务修复 (P1 — 尽快修复) +11. **门诊→住院转科** — 信息连续性 +12. **手术→病理送检** — 标本追溯 +13. **检验→临床决策** — 检验联动 +14. **检查→报告→医嘱** — 状态联动 + +--- + +## 六、文档产出清单 + +| 文档 | 内容 | 用途 | +|------|------|------| +| CROSS_MODULE_BUSINESS_ANALYSIS.md | 本文档 | 业务分析+系统诊断 | +| PHASE_A_FOLLOWUP_DESIGN.md | 门诊随访深度设计 | 开发依据 | +| PHASE_A_PATHOLOGY_DESIGN.md | 病理管理深度设计 | 开发依据 | +| PHASE_A_EMERGENCY_DESIGN.md | 急诊分诊抢救深度设计 | 开发依据 | +| PHASE_B_*.md | 各P1模块深度设计 | 开发依据 | diff --git a/MD/architecture/PHASE_A_EMERGENCY_DESIGN.md b/MD/architecture/PHASE_A_EMERGENCY_DESIGN.md new file mode 100644 index 000000000..0dc9a2d26 --- /dev/null +++ b/MD/architecture/PHASE_A_EMERGENCY_DESIGN.md @@ -0,0 +1,128 @@ +# 急诊分诊+抢救模块 — 深度设计文档 + +> **版本**: v1.0 | **编制日期**: 2026-06-07 +> **依据**: 《急诊科建设与管理指南》+ 《急诊预检分诊专家共识》 + +--- + +## 一、业务背景 + +急诊是三甲医院的关键科室,必须实现: +- 四级预检分诊(Ⅰ级濒死/Ⅱ级危重/Ⅲ级急症/Ⅳ级非急) +- 绿色通道(胸痛/卒中/创伤) +- 抢救记录电子化 +- 急诊绿色通道时间监控(门-药/门-球囊/门-手术) + +## 二、业务流程 + +``` +患者到达急诊 + ↓ +[预检分诊台] + ├─ 采集生命体征(体温/脉搏/呼吸/血压/血氧/意识) + ├─ 评估病情分级 + └─ 分配就诊区域 + ↓ +┌─ Ⅰ级(濒死) → 立即抢救 → 绿色通道 +├─ Ⅱ级(危重) → 10分钟内就诊 +├─ Ⅲ级(急症) → 30分钟内就诊 +└─ Ⅳ级(非急) → 引导至门诊 + ↓ +[急诊医生接诊] ←→ [急诊医嘱] + ↓ +[检查/检验] ←→ [抢救/留观/住院/出院] + ↓ +[急诊病历] ←→ [急诊统计] +``` + +## 三、数据模型 + +```sql +-- 急诊分诊 +CREATE TABLE emergency_triage ( + id BIGSERIAL PRIMARY KEY, + patient_id BIGINT, + patient_name VARCHAR(50), + triage_level INT NOT NULL, -- 1-4级 + chief_complaint TEXT, + temperature DECIMAL(4,1), + pulse INT, + respiration INT, + systolic_bp INT, + diastolic_bp INT, + spo2 INT, + consciousness VARCHAR(20), + triage_nurse VARCHAR(64), + triage_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + area VARCHAR(20), -- RESUS/EMERGENCY/OBSERVATION/GREEN + status VARCHAR(20) DEFAULT 'WAITING', + tenant_id BIGINT DEFAULT 0, + is_deleted INT NOT NULL DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 抢救记录 +CREATE TABLE emergency_rescue ( + id BIGSERIAL PRIMARY KEY, + patient_id BIGINT NOT NULL, + triage_id BIGINT, + rescue_start TIMESTAMP, + rescue_end TIMESTAMP, + rescue_result VARCHAR(20), + chief_doctor VARCHAR(64), + rescue_team TEXT, + procedures TEXT, + medications TEXT, + outcome VARCHAR(20), -- ADMITTED/DISCHARGED/TRANSFERRED/DECEASED + tenant_id BIGINT DEFAULT 0, + is_deleted INT NOT NULL DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 留观记录 +CREATE TABLE emergency_observation ( + id BIGSERIAL PRIMARY KEY, + patient_id BIGINT NOT NULL, + triage_id BIGINT, + observation_start TIMESTAMP, + observation_end TIMESTAMP, + bed_no VARCHAR(20), + doctor VARCHAR(64), + diagnosis TEXT, + disposition VARCHAR(20), -- ADMITTED/DISCHARGED/TRANSFERRED + observation_hours INT, + tenant_id BIGINT DEFAULT 0, + is_deleted INT NOT NULL DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 绿色通道 +CREATE TABLE emergency_green_channel ( + id BIGSERIAL PRIMARY KEY, + patient_id BIGINT NOT NULL, + disease_type VARCHAR(30), -- CHEST_PAIN/STROKE/TRAUMA/POISONING + door_to_treatment_time INT, -- 门到治疗时间(分钟) + target_time INT, -- 目标时间 + is_achieved BOOLEAN, + doctor VARCHAR(64), + activate_time TIMESTAMP, + complete_time TIMESTAMP, + tenant_id BIGINT DEFAULT 0, + is_deleted INT NOT NULL DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +``` + +## 四、接口设计 + +| API | 方法 | 说明 | +|-----|------|------| +| /emergency/triage/add | POST | 预检分诊 | +| /emergency/triage/queue | GET | 分诊队列(按级别排序) | +| /emergency/rescue/add | POST | 开始抢救 | +| /emergency/rescue/complete/{id} | PUT | 抢救完成 | +| /emergency/observation/add | POST | 留观登记 | +| /emergency/observation/discharge/{id} | PUT | 留观出院 | +| /emergency/green-channel/activate | POST | 启动绿色通道 | +| /emergency/green-channel/stats | GET | 绿色通道统计(达标率) | +| /emergency/stats | GET | 急诊统计(分级分布/抢救率/等候时间) | diff --git a/MD/architecture/PHASE_A_FOLLOWUP_DESIGN.md b/MD/architecture/PHASE_A_FOLLOWUP_DESIGN.md new file mode 100644 index 000000000..0e1964e5b --- /dev/null +++ b/MD/architecture/PHASE_A_FOLLOWUP_DESIGN.md @@ -0,0 +1,195 @@ +# 门诊随访管理模块 — 深度设计文档 + +> **版本**: v1.0 | **编制日期**: 2026-06-07 +> **依据**: 《三级医院评审标准》患者服务条款 + 慢病管理规范 + +--- + +## 一、业务背景 + +门诊随访是三甲医院患者服务的核心环节: +- 慢病患者(高血压/糖尿病/冠心病等)出院后需定期随访 +- 手术患者术后需随访恢复情况 +- 肿瘤患者需长期随访复发/转移 +- 满意度调查是医院服务质量的核心指标 + +## 二、业务流程 + +### 2.1 随访计划生成 +``` +出院/门诊结束 + ↓ +[自动触发] ← 根据病种+诊断自动生成随访计划 + ↓ (规则引擎) +┌─ 高血压: 每月1次电话随访, 持续1年 +├─ 糖尿病: 每2周1次, 持续6个月 +├─ 手术后: 术后1周/1月/3月/6月/1年 +├─ 肿瘤: 每3个月复查, 持续5年 +└─ 普通: 出院后1周电话随访1次 + ↓ +[分配责任人] ← 根据科室+医生自动分配 +``` + +### 2.2 随访执行 +``` +[随访任务列表] ← 责任医生/护士查看今日任务 + ↓ +[选择联系方式] ← 电话/短信/微信/门诊 + ↓ +[拨打电话/发送短信] + ↓ +[录入随访结果] + ├─ 患者情况良好 → 标记完成 + ├─ 有异常症状 → 创建复查预约 + ├─ 需要调药 → 转诊门诊 + └─ 失访 → 标记失访原因 + ↓ +[更新随访记录] +``` + +### 2.3 满意度调查 +``` +[出院时] → 发放满意度问卷(纸质/电子) + ↓ +[患者填写] → 评分+建议 + ↓ +[数据汇总] → 按科室/医生统计 + ↓ +[问题整改] → 质量改进措施 +``` + +## 三、数据模型 + +### 3.1 核心表 + +```sql +-- 随访计划 +CREATE TABLE followup_plan ( + id BIGSERIAL PRIMARY KEY, + patient_id BIGINT NOT NULL, + patient_name VARCHAR(50), + encounter_id BIGINT, + disease_code VARCHAR(20), + disease_name VARCHAR(100), + followup_type VARCHAR(20) NOT NULL, -- PHONE/SMS/WECHAT/OUTPATIENT + frequency VARCHAR(20), -- DAILY/WEEKLY/MONTHLY/QUARTERLY + total_times INT DEFAULT 1, + completed_times INT DEFAULT 0, + responsible_doctor VARCHAR(64), + responsible_nurse VARCHAR(64), + start_date DATE, + end_date DATE, + status VARCHAR(20) DEFAULT 'ACTIVE', -- ACTIVE/COMPLETED/CANCELLED + tenant_id BIGINT DEFAULT 0, + is_deleted INT NOT NULL DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 随访任务 +CREATE TABLE followup_task ( + id BIGSERIAL PRIMARY KEY, + plan_id BIGINT NOT NULL, + patient_id BIGINT NOT NULL, + patient_name VARCHAR(50), + phone VARCHAR(20), + scheduled_date DATE NOT NULL, + actual_date DATE, + contact_method VARCHAR(20), + operator_name VARCHAR(64), + result VARCHAR(20), -- SUCCESS/FAILED/NO_ANSWER/WRONG_NUMBER/LOST + abnormal_flag BOOLEAN DEFAULT FALSE, + next_action VARCHAR(200), + tenant_id BIGINT DEFAULT 0, + is_deleted INT NOT NULL DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 随访记录 +CREATE TABLE followup_record ( + id BIGSERIAL PRIMARY KEY, + task_id BIGINT NOT NULL, + patient_id BIGINT NOT NULL, + contact_content TEXT, + patient_condition TEXT, + medication_compliance VARCHAR(20), + symptoms TEXT, + vital_signs JSONB, + reappointment_flag BOOLEAN DEFAULT FALSE, + reappointment_date DATE, + transfer_flag BOOLEAN DEFAULT FALSE, + transfer_reason TEXT, + operator_name VARCHAR(64), + operate_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + tenant_id BIGINT DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 满意度调查 +CREATE TABLE satisfaction_survey ( + id BIGSERIAL PRIMARY KEY, + patient_id BIGINT, + patient_name VARCHAR(50), + survey_type VARCHAR(20) NOT NULL, -- INPATIENT/OUTPATIENT/EMERGENCY + department_name VARCHAR(100), + doctor_name VARCHAR(64), + overall_score INT, + service_score INT, + environment_score INT, + suggestions TEXT, + survey_date DATE DEFAULT CURRENT_DATE, + tenant_id BIGINT DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 投诉记录 +CREATE TABLE complaint_record ( + id BIGSERIAL PRIMARY KEY, + patient_id BIGINT, + patient_name VARCHAR(50), + complaint_type VARCHAR(30) NOT NULL, -- SERVICE/TECHNIQUE/ENVIRONMENT/BILLING/OTHER + complaint_content TEXT NOT NULL, + department_name VARCHAR(100), + handler VARCHAR(64), + handle_result TEXT, + handle_time TIMESTAMP, + status VARCHAR(20) DEFAULT 'PENDING', -- PENDING/PROCESSING/RESOLVED/CLOSED + satisfaction_after INT, + tenant_id BIGINT DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +``` + +### 3.2 接口设计 + +| API | 方法 | 说明 | 参数 | +|-----|------|------|------| +| /followup/plan/page | GET | 随访计划列表 | patientName,status,pageNo,pageSize | +| /followup/plan/add | POST | 新建随访计划 | patientId,diseaseCode,frequency,totalTimes | +| /followup/task/my | GET | 我的今日任务 | operatorName | +| /followup/task/page | GET | 任务列表(分页) | status,scheduledDate,pageNo,pageSize | +| /followup/task/complete/{id} | PUT | 完成任务 | result,abnormalFlag,nextAction | +| /followup/record/add | POST | 录入随访记录 | taskId,contactContent,patientCondition | +| /followup/survey/add | POST | 提交满意度 | surveyType,overallScore,suggestions | +| /followup/survey/stats | GET | 满意度统计 | departmentName,startDate,endDate | +| /followup/complaint/page | GET | 投诉列表 | status,complaintType,pageNo,pageSize | +| /followup/complaint/handle/{id} | PUT | 处理投诉 | handler,handleResult | +| /followup/stats/overview | GET | 随访概览 | startDate,endDate | + +## 四、前端页面设计 + +### 4.1 页面结构 +``` +followup/ +├── plan/ # 随访计划管理 +├── task/ # 随访任务(今日任务/我的任务) +├── record/ # 随访记录查询 +├── survey/ # 满意度调查 +├── complaint/ # 投诉管理 +└── stats/ # 统计分析 +``` + +### 4.2 核心交互 +- **今日任务看板**: 按优先级排序(异常>待随访>已完成) +- **一键拨号**: 点击患者电话直接拨打(集成HIS电话模块) +- **随访结果快速录入**: 预设选项+自由文本 +- **满意度雷达图**: 多维度评分可视化 diff --git a/MD/architecture/PHASE_A_PATHOLOGY_DESIGN.md b/MD/architecture/PHASE_A_PATHOLOGY_DESIGN.md new file mode 100644 index 000000000..44aa0ab60 --- /dev/null +++ b/MD/architecture/PHASE_A_PATHOLOGY_DESIGN.md @@ -0,0 +1,142 @@ +# 病理管理模块 — 深度设计文档 + +> **版本**: v1.0 | **编制日期**: 2026-06-07 +> **依据**: 《病理科建设与管理指南》+ 《临床病理质量控制标准》 + +--- + +## 一、业务背景 + +病理诊断是手术后诊断的"金标准",三甲医院必须具备: +- 病理标本全流程追溯(从手术室到病理科) +- 三级审核制度(住院医师→主治→副主任) +- 病理报告质量控制 +- 肿瘤登记上报 + +## 二、业务流程 + +``` +[手术/活检/穿刺] → 病理申请单 + ↓ +[标本采集] ←→ [条码打印] ←→ [标本固定(10%福尔马林)] + ↓ (运送至病理科) +[标本接收] ←→ [标本核对(条码扫码)] + ↓ (不合格退回) +[取材描述] ←→ [组织处理(脱水/包埋)] + ↓ +[切片制作] ←→ [染色(HE/免疫组化/特殊染色)] + ↓ +[初诊阅片] ←→ [上级医师审核] + ↓ (疑难病例会诊) +[病理会诊] ←→ [最终诊断] + ↓ +[报告编写] ←→ [三级审核] + ↓ +[报告签发] ←→ [临床科室领取] + ↓ +[肿瘤登记] ←→ [随访] +``` + +## 三、数据模型 + +```sql +-- 病理申请 +CREATE TABLE pathology_order ( + id BIGSERIAL PRIMARY KEY, + patient_id BIGINT NOT NULL, + patient_name VARCHAR(50), + encounter_id BIGINT, + specimen_type VARCHAR(50), -- 手术标本/活检/穿刺/细胞学 + clinical_diagnosis TEXT, + sample_site VARCHAR(100), + urgency VARCHAR(20) DEFAULT 'NORMAL', -- URGENT/NORMAL + order_status VARCHAR(20) DEFAULT 'PENDING', + apply_doctor VARCHAR(64), + apply_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + tenant_id BIGINT DEFAULT 0, + is_deleted INT NOT NULL DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 病理标本 +CREATE TABLE pathology_specimen ( + id BIGSERIAL PRIMARY KEY, + order_id BIGINT NOT NULL, + barcode VARCHAR(100) NOT NULL, + specimen_desc TEXT, + collection_site VARCHAR(100), + fixative VARCHAR(50), + fixative_time TIMESTAMP, + receive_time TIMESTAMP, + receiver VARCHAR(64), + is_qualified BOOLEAN DEFAULT TRUE, + reject_reason TEXT, + tenant_id BIGINT DEFAULT 0, + is_deleted INT NOT NULL DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 病理处理 +CREATE TABLE pathology_process ( + id BIGSERIAL PRIMARY KEY, + specimen_id BIGINT NOT NULL, + process_type VARCHAR(30), -- 取材/脱水/包埋/切片/染色/免疫组化 + process_desc TEXT, + operator VARCHAR(64), + operate_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + tenant_id BIGINT DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 病理诊断 +CREATE TABLE pathology_diagnosis ( + id BIGSERIAL PRIMARY KEY, + order_id BIGINT NOT NULL, + specimen_id BIGINT, + diagnosis_type VARCHAR(30), -- 初诊/复诊/会诊/最终 + diagnosis_result TEXT, + immunostain_result TEXT, + doctor_name VARCHAR(64), + doctor_title VARCHAR(20), + diagnose_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + tenant_id BIGINT DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); + +-- 病理报告 +CREATE TABLE pathology_report ( + id BIGSERIAL PRIMARY KEY, + order_id BIGINT NOT NULL, + patient_id BIGINT, + specimen_desc TEXT, + macroscopic_desc TEXT, -- 肉眼所见 + microscopic_desc TEXT, -- 镜下所见 + diagnosis_result TEXT, -- 病理诊断 + suggestion TEXT, + report_doctor VARCHAR(64), + report_time TIMESTAMP, + audit_doctor VARCHAR(64), + audit_time TIMESTAMP, + final_doctor VARCHAR(64), + final_time TIMESTAMP, + status VARCHAR(20) DEFAULT 'DRAFT', + tenant_id BIGINT DEFAULT 0, + is_deleted INT NOT NULL DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +``` + +## 四、接口设计 + +| API | 方法 | 说明 | +|-----|------|------| +| /pathology/order/page | GET | 病理申请列表 | +| /pathology/order/add | POST | 新建病理申请 | +| /pathology/specimen/scan | POST | 标本扫码接收 | +| /pathology/specimen/reject/{id} | PUT | 标本拒收 | +| /pathology/process/record | POST | 记录处理过程 | +| /pathology/diagnosis/add | POST | 录入诊断 | +| /pathology/report/page | GET | 病理报告列表 | +| /pathology/report/add | POST | 新建报告 | +| /pathology/report/audit/{id} | PUT | 审核报告 | +| /pathology/stats | GET | 病理统计(标本数/诊断分布/周转时间) | diff --git a/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/emergency/controller/EmergencyController.java b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/emergency/controller/EmergencyController.java new file mode 100644 index 000000000..02ac43930 --- /dev/null +++ b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/emergency/controller/EmergencyController.java @@ -0,0 +1,357 @@ +package com.healthlink.his.web.emergency.controller; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.core.common.core.domain.R; +import com.healthlink.his.emergency.domain.*; +import com.healthlink.his.emergency.service.*; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.format.annotation.DateTimeFormat; +import org.springframework.transaction.annotation.Transactional; +import org.springframework.util.StringUtils; +import org.springframework.web.bind.annotation.*; + +import java.util.Date; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +/** + * 急诊管理 Controller — 深度业务逻辑 + * + * 业务说明: + * 1. 急诊分诊: 按五级分诊标准(Ⅰ级濒死→Ⅴ级非紧急)进行快速评估,决定就诊区域和优先级 + * 2. 抢救管理: 抢救过程记录(开始时间、团队、操作、用药、结果),抢救成功/失败闭环 + * 3. 留观管理: 急诊留观患者观察记录,观察时长追踪,转归处置(住院/出院/转科) + * 4. 绿色通道: 急危重症患者快速通道,追踪Door-to-Treatment时间,评估是否达标 + * 5. 与住院联动: 急诊→住院转科信息传递,保证诊疗连续性 + * 6. 与120联动: 院前急救信息接收和跟踪 + * + * 调用关系: + * EmergencyController → IEmergencyTriageService → 分诊评估→分级→分配区域 + * → IEmergencyRescueService → 抢救记录→用药→结果 + * → IEmergencyObservationService → 留观→转归 + * → IEmergencyGreenChannelService → 时间追踪→达标评估 + */ +@RestController +@RequestMapping("/emergency") +@Slf4j +@AllArgsConstructor +public class EmergencyController { + + private final IEmergencyTriageService triageService; + private final IEmergencyRescueService rescueService; + private final IEmergencyObservationService observationService; + private final IEmergencyGreenChannelService greenChannelService; + + // ==================== 急诊分诊 ==================== + + @GetMapping("/triage/page") + public R getTriagePage( + @RequestParam(value = "patientName", required = false) String patientName, + @RequestParam(value = "triageLevel", required = false) Integer triageLevel, + @RequestParam(value = "area", required = false) String area, + @RequestParam(value = "status", required = false) String status, + @RequestParam(value = "triageNurse", required = false) String triageNurse, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.like(StringUtils.hasText(patientName), EmergencyTriage::getPatientName, patientName) + .eq(triageLevel != null, EmergencyTriage::getTriageLevel, triageLevel) + .eq(StringUtils.hasText(area), EmergencyTriage::getArea, area) + .eq(StringUtils.hasText(status), EmergencyTriage::getStatus, status) + .eq(StringUtils.hasText(triageNurse), EmergencyTriage::getTriageNurse, triageNurse) + .orderByAsc(EmergencyTriage::getTriageLevel) + .orderByDesc(EmergencyTriage::getTriageTime); + return R.ok(triageService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/triage/realtime") + public R getRealtimeStatus() { + Map realtime = new HashMap<>(); + // 各级别待诊人数 + for (int level = 1; level <= 5; level++) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(EmergencyTriage::getTriageLevel, level) + .eq(EmergencyTriage::getStatus, "WAITING"); + realtime.put("level" + level + "Waiting", triageService.count(w)); + } + // 当前就诊中人数 + LambdaQueryWrapper w2 = new LambdaQueryWrapper<>(); + w2.eq(EmergencyTriage::getStatus, "IN_TREATMENT"); + realtime.put("inTreatment", triageService.count(w2)); + // 今日总分诊数 + LambdaQueryWrapper w3 = new LambdaQueryWrapper<>(); + realtime.put("todayTotal", triageService.count(w3)); + return R.ok(realtime); + } + + @GetMapping("/triage/{id}") + public R getTriageById(@PathVariable Long id) { + return R.ok(triageService.getById(id)); + } + + @PostMapping("/triage/add") + @Transactional(rollbackFor = Exception.class) + public R addTriage(@RequestBody EmergencyTriage triage) { + if (!StringUtils.hasText(triage.getStatus())) { + triage.setStatus("WAITING"); + } + triage.setTriageTime(new Date()); + triage.setCreateTime(new Date()); + triageService.save(triage); + return R.ok(triage); + } + + @PutMapping("/triage/update") + @Transactional(rollbackFor = Exception.class) + public R updateTriage(@RequestBody EmergencyTriage triage) { + triageService.updateById(triage); + return R.ok(triage); + } + + @PutMapping("/triage/{id}/start-treatment") + @Transactional(rollbackFor = Exception.class) + public R startTreatment(@PathVariable Long id) { + EmergencyTriage triage = triageService.getById(id); + if (triage != null) { + triage.setStatus("IN_TREATMENT"); + triageService.updateById(triage); + } + return R.ok(); + } + + @PutMapping("/triage/{id}/complete") + @Transactional(rollbackFor = Exception.class) + public R completeTriage(@PathVariable Long id) { + EmergencyTriage triage = triageService.getById(id); + if (triage != null) { + triage.setStatus("COMPLETED"); + triageService.updateById(triage); + } + return R.ok(); + } + + @DeleteMapping("/triage/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteTriage(@PathVariable Long id) { + triageService.removeById(id); + return R.ok(); + } + + // ==================== 抢救管理 ==================== + + @GetMapping("/rescue/page") + public R getRescuePage( + @RequestParam(value = "patientId", required = false) Long patientId, + @RequestParam(value = "chiefDoctor", required = false) String chiefDoctor, + @RequestParam(value = "rescueResult", required = false) String rescueResult, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(patientId != null, EmergencyRescue::getPatientId, patientId) + .eq(StringUtils.hasText(chiefDoctor), EmergencyRescue::getChiefDoctor, chiefDoctor) + .eq(StringUtils.hasText(rescueResult), EmergencyRescue::getRescueResult, rescueResult) + .orderByDesc(EmergencyRescue::getRescueStart); + return R.ok(rescueService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/rescue/{id}") + public R getRescueById(@PathVariable Long id) { + return R.ok(rescueService.getById(id)); + } + + @PostMapping("/rescue/add") + @Transactional(rollbackFor = Exception.class) + public R addRescue(@RequestBody EmergencyRescue rescue) { + rescue.setRescueStart(new Date()); + rescue.setCreateTime(new Date()); + rescueService.save(rescue); + // 联动更新分诊状态 + if (rescue.getTriageId() != null) { + EmergencyTriage triage = triageService.getById(rescue.getTriageId()); + if (triage != null) { + triage.setStatus("IN_TREATMENT"); + triageService.updateById(triage); + } + } + return R.ok(rescue); + } + + @PutMapping("/rescue/end") + @Transactional(rollbackFor = Exception.class) + public R endRescue(@RequestBody EmergencyRescue rescue) { + rescue.setRescueEnd(new Date()); + rescueService.updateById(rescue); + return R.ok(rescue); + } + + @PutMapping("/rescue/{id}/result") + @Transactional(rollbackFor = Exception.class) + public R updateRescueResult(@PathVariable Long id, @RequestBody EmergencyRescue data) { + EmergencyRescue rescue = rescueService.getById(id); + if (rescue != null) { + rescue.setRescueResult(data.getRescueResult()); + rescue.setOutcome(data.getOutcome()); + rescue.setRescueEnd(new Date()); + rescueService.updateById(rescue); + // 联动更新分诊状态为完成 + if (rescue.getTriageId() != null) { + EmergencyTriage triage = triageService.getById(rescue.getTriageId()); + if (triage != null) { + triage.setStatus("COMPLETED"); + triageService.updateById(triage); + } + } + } + return R.ok(); + } + + @DeleteMapping("/rescue/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteRescue(@PathVariable Long id) { + rescueService.removeById(id); + return R.ok(); + } + + // ==================== 留观管理 ==================== + + @GetMapping("/observation/page") + public R getObservationPage( + @RequestParam(value = "patientId", required = false) Long patientId, + @RequestParam(value = "doctor", required = false) String doctor, + @RequestParam(value = "disposition", required = false) String disposition, + @RequestParam(value = "bedNo", required = false) String bedNo, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(patientId != null, EmergencyObservation::getPatientId, patientId) + .eq(StringUtils.hasText(doctor), EmergencyObservation::getDoctor, doctor) + .eq(StringUtils.hasText(disposition), EmergencyObservation::getDisposition, disposition) + .eq(StringUtils.hasText(bedNo), EmergencyObservation::getBedNo, bedNo) + .orderByDesc(EmergencyObservation::getObservationStart); + return R.ok(observationService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/observation/{id}") + public R getObservationById(@PathVariable Long id) { + return R.ok(observationService.getById(id)); + } + + @PostMapping("/observation/add") + @Transactional(rollbackFor = Exception.class) + public R addObservation(@RequestBody EmergencyObservation obs) { + obs.setObservationStart(new Date()); + obs.setCreateTime(new Date()); + observationService.save(obs); + return R.ok(obs); + } + + @PutMapping("/observation/discharge") + @Transactional(rollbackFor = Exception.class) + public R dischargeObservation(@RequestBody EmergencyObservation obs) { + obs.setObservationEnd(new Date()); + if (obs.getObservationStart() != null) { + long hours = (obs.getObservationEnd().getTime() - obs.getObservationStart().getTime()) / (1000 * 60 * 60); + obs.setObservationHours((int) hours); + } + observationService.updateById(obs); + return R.ok(obs); + } + + @PutMapping("/observation/{id}/disposition") + @Transactional(rollbackFor = Exception.class) + public R updateDisposition(@PathVariable Long id, @RequestParam("disposition") String disposition) { + EmergencyObservation obs = observationService.getById(id); + if (obs != null) { + obs.setDisposition(disposition); + obs.setObservationEnd(new Date()); + observationService.updateById(obs); + } + return R.ok(); + } + + @DeleteMapping("/observation/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteObservation(@PathVariable Long id) { + observationService.removeById(id); + return R.ok(); + } + + // ==================== 绿色通道 ==================== + + @GetMapping("/green-channel/page") + public R getGreenChannelPage( + @RequestParam(value = "patientId", required = false) Long patientId, + @RequestParam(value = "diseaseType", required = false) String diseaseType, + @RequestParam(value = "isAchieved", required = false) Boolean isAchieved, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(patientId != null, EmergencyGreenChannel::getPatientId, patientId) + .eq(StringUtils.hasText(diseaseType), EmergencyGreenChannel::getDiseaseType, diseaseType) + .eq(isAchieved != null, EmergencyGreenChannel::getIsAchieved, isAchieved) + .orderByDesc(EmergencyGreenChannel::getActivateTime); + return R.ok(greenChannelService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/green-channel/{id}") + public R getGreenChannelById(@PathVariable Long id) { + return R.ok(greenChannelService.getById(id)); + } + + @PostMapping("/green-channel/activate") + @Transactional(rollbackFor = Exception.class) + public R activateGreenChannel(@RequestBody EmergencyGreenChannel gc) { + gc.setActivateTime(new Date()); + gc.setCreateTime(new Date()); + greenChannelService.save(gc); + return R.ok(gc); + } + + @PutMapping("/green-channel/{id}/complete") + @Transactional(rollbackFor = Exception.class) + public R completeGreenChannel(@PathVariable Long id, @RequestBody EmergencyGreenChannel data) { + EmergencyGreenChannel gc = greenChannelService.getById(id); + if (gc != null) { + gc.setCompleteTime(new Date()); + gc.setDoorToTreatmentTime(data.getDoorToTreatmentTime()); + // 判断是否达标 + if (gc.getTargetTime() != null && gc.getDoorToTreatmentTime() != null) { + gc.setIsAchieved(gc.getDoorToTreatmentTime() <= gc.getTargetTime()); + } + greenChannelService.updateById(gc); + } + return R.ok(); + } + + @GetMapping("/green-channel/stats") + public R getGreenChannelStats( + @RequestParam(value = "startDate", required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") java.time.LocalDate startDate, + @RequestParam(value = "endDate", required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") java.time.LocalDate endDate) { + Map stats = new HashMap<>(); + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.ge(startDate != null, EmergencyGreenChannel::getActivateTime, + startDate != null ? java.sql.Date.valueOf(startDate) : null) + .le(endDate != null, EmergencyGreenChannel::getActivateTime, + endDate != null ? java.sql.Date.valueOf(endDate) : null); + List list = greenChannelService.list(w); + stats.put("total", list.size()); + long achieved = list.stream().filter(g -> Boolean.TRUE.equals(g.getIsAchieved())).count(); + stats.put("achieved", achieved); + stats.put("achievementRate", list.isEmpty() ? 0 : Math.round(achieved * 100.0 / list.size())); + stats.put("avgTime", list.stream() + .filter(g -> g.getDoorToTreatmentTime() != null) + .mapToInt(EmergencyGreenChannel::getDoorToTreatmentTime) + .average().orElse(0)); + return R.ok(stats); + } + + @DeleteMapping("/green-channel/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteGreenChannel(@PathVariable Long id) { + greenChannelService.removeById(id); + return R.ok(); + } +} diff --git a/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/followup/controller/FollowupController.java b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/followup/controller/FollowupController.java new file mode 100644 index 000000000..33af542f8 --- /dev/null +++ b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/followup/controller/FollowupController.java @@ -0,0 +1,411 @@ +package com.healthlink.his.web.followup.controller; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.core.common.core.domain.R; +import com.healthlink.his.followup.domain.*; +import com.healthlink.his.followup.service.*; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.format.annotation.DateTimeFormat; +import org.springframework.transaction.annotation.Transactional; +import org.springframework.util.StringUtils; +import org.springframework.web.bind.annotation.*; + +import java.time.LocalDate; +import java.util.Date; +import java.util.List; + +/** + * 门诊随访管理 Controller — 深度业务逻辑 + * + * 业务说明: + * 1. 随访计划: 出院/门诊结束后按病种规则自动生成随访计划,分配责任人 + * 2. 随访任务: 按计划周期拆解成独立随访任务,支持电话/短信/微信/门诊随访 + * 3. 随访记录: 每次随访的详细结果,包含用药依从性、症状、是否需复查/转诊 + * 4. 满意度调查: 按科室/医生维度汇总评分,驱动质量改进 + * 5. 投诉记录: 投诉受理→处理→回访→关闭闭环管理 + * + * 调用关系: + * FollowupController → IFollowupPlanService → FollowupPlanMapper → DB + * → IFollowupTaskService → 自动拆解任务 + * → IFollowupRecordService → 记录随访结果,更新任务状态 + * → ISatisfactionSurveyService → 满意度统计 + * → IComplaintRecordService → 投诉闭环 + */ +@RestController +@RequestMapping("/followup") +@Slf4j +@AllArgsConstructor +public class FollowupController { + + private final IFollowupPlanService planService; + private final IFollowupTaskService taskService; + private final IFollowupRecordService recordService; + private final ISatisfactionSurveyService surveyService; + private final IComplaintRecordService complaintService; + + // ==================== 随访计划 ==================== + + @GetMapping("/plan/page") + public R getPlanPage( + @RequestParam(value = "patientName", required = false) String patientName, + @RequestParam(value = "diseaseCode", required = false) String diseaseCode, + @RequestParam(value = "followupType", required = false) String followupType, + @RequestParam(value = "status", required = false) String status, + @RequestParam(value = "responsibleDoctor", required = false) String responsibleDoctor, + @RequestParam(value = "startDateFrom", required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") LocalDate startDateFrom, + @RequestParam(value = "startDateTo", required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") LocalDate startDateTo, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.like(StringUtils.hasText(patientName), FollowupPlan::getPatientName, patientName) + .eq(StringUtils.hasText(diseaseCode), FollowupPlan::getDiseaseCode, diseaseCode) + .eq(StringUtils.hasText(followupType), FollowupPlan::getFollowupType, followupType) + .eq(StringUtils.hasText(status), FollowupPlan::getStatus, status) + .eq(StringUtils.hasText(responsibleDoctor), FollowupPlan::getResponsibleDoctor, responsibleDoctor) + .ge(startDateFrom != null, FollowupPlan::getStartDate, startDateFrom) + .le(startDateTo != null, FollowupPlan::getStartDate, startDateTo) + .orderByDesc(FollowupPlan::getCreateTime); + return R.ok(planService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/plan/list") + public R getPlanList( + @RequestParam(value = "status", required = false) String status, + @RequestParam(value = "responsibleDoctor", required = false) String responsibleDoctor) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(StringUtils.hasText(status), FollowupPlan::getStatus, status) + .eq(StringUtils.hasText(responsibleDoctor), FollowupPlan::getResponsibleDoctor, responsibleDoctor) + .orderByDesc(FollowupPlan::getCreateTime); + return R.ok(planService.list(w)); + } + + @GetMapping("/plan/{id}") + public R getPlanById(@PathVariable Long id) { + return R.ok(planService.getById(id)); + } + + @PostMapping("/plan/add") + @Transactional(rollbackFor = Exception.class) + public R addPlan(@RequestBody FollowupPlan plan) { + plan.setCompletedTimes(0); + if (!StringUtils.hasText(plan.getStatus())) { + plan.setStatus("ACTIVE"); + } + plan.setCreateTime(new Date()); + planService.save(plan); + // 根据计划自动拆解随访任务 + generateTasksFromPlan(plan); + return R.ok(plan); + } + + @PutMapping("/plan/update") + @Transactional(rollbackFor = Exception.class) + public R updatePlan(@RequestBody FollowupPlan plan) { + planService.updateById(plan); + return R.ok(plan); + } + + @DeleteMapping("/plan/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deletePlan(@PathVariable Long id) { + // 联动删除该计划下的所有任务和记录 + LambdaQueryWrapper tw = new LambdaQueryWrapper<>(); + tw.eq(FollowupTask::getPlanId, id); + List tasks = taskService.list(tw); + for (FollowupTask t : tasks) { + LambdaQueryWrapper rw = new LambdaQueryWrapper<>(); + rw.eq(FollowupRecord::getTaskId, t.getId()); + recordService.remove(rw); + } + taskService.remove(tw); + planService.removeById(id); + return R.ok(); + } + + @PutMapping("/plan/complete/{id}") + @Transactional(rollbackFor = Exception.class) + public R completePlan(@PathVariable Long id) { + FollowupPlan plan = planService.getById(id); + if (plan != null) { + plan.setStatus("COMPLETED"); + planService.updateById(plan); + } + return R.ok(); + } + + /** + * 根据随访计划自动生成随访任务 + * 业务逻辑: 按频率和总次数计算每次随访的计划日期 + */ + private void generateTasksFromPlan(FollowupPlan plan) { + if (plan.getStartDate() == null || plan.getTotalTimes() == null || plan.getTotalTimes() <= 0) { + return; + } + int total = plan.getTotalTimes(); + LocalDate base = plan.getStartDate(); + for (int i = 0; i < total; i++) { + FollowupTask task = new FollowupTask(); + task.setPlanId(plan.getId()); + task.setPatientId(plan.getPatientId()); + task.setPatientName(plan.getPatientName()); + task.setScheduledDate(base.plusWeeks(i)); + task.setContactMethod(plan.getFollowupType()); + task.setCreateTime(new Date()); + taskService.save(task); + } + } + + // ==================== 随访任务 ==================== + + @GetMapping("/task/page") + public R getTaskPage( + @RequestParam(value = "planId", required = false) Long planId, + @RequestParam(value = "patientName", required = false) String patientName, + @RequestParam(value = "scheduledDate", required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") LocalDate scheduledDate, + @RequestParam(value = "result", required = false) String result, + @RequestParam(value = "abnormalFlag", required = false) Boolean abnormalFlag, + @RequestParam(value = "operatorName", required = false) String operatorName, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(planId != null, FollowupTask::getPlanId, planId) + .like(StringUtils.hasText(patientName), FollowupTask::getPatientName, patientName) + .eq(scheduledDate != null, FollowupTask::getScheduledDate, scheduledDate) + .eq(StringUtils.hasText(result), FollowupTask::getResult, result) + .eq(abnormalFlag != null, FollowupTask::getAbnormalFlag, abnormalFlag) + .eq(StringUtils.hasText(operatorName), FollowupTask::getOperatorName, operatorName) + .orderByAsc(FollowupTask::getScheduledDate); + return R.ok(taskService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/task/today") + public R getTodayTasks( + @RequestParam(value = "operatorName", required = false) String operatorName) { + LocalDate today = LocalDate.now(); + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(FollowupTask::getScheduledDate, today) + .eq(FollowupTask::getResult, null) + .eq(StringUtils.hasText(operatorName), FollowupTask::getOperatorName, operatorName) + .orderByAsc(FollowupTask::getScheduledDate); + return R.ok(taskService.list(w)); + } + + @GetMapping("/task/{id}") + public R getTaskById(@PathVariable Long id) { + return R.ok(taskService.getById(id)); + } + + @PostMapping("/task/add") + @Transactional(rollbackFor = Exception.class) + public R addTask(@RequestBody FollowupTask task) { + task.setCreateTime(new Date()); + taskService.save(task); + return R.ok(task); + } + + @PutMapping("/task/execute") + @Transactional(rollbackFor = Exception.class) + public R executeTask(@RequestBody FollowupTask task) { + task.setActualDate(LocalDate.now()); + taskService.updateById(task); + // 更新随访计划的已完成次数 + if (task.getPlanId() != null && "SUCCESS".equals(task.getResult())) { + FollowupPlan plan = planService.getById(task.getPlanId()); + if (plan != null) { + plan.setCompletedTimes((plan.getCompletedTimes() == null ? 0 : plan.getCompletedTimes()) + 1); + planService.updateById(plan); + } + } + return R.ok(task); + } + + @PutMapping("/task/{id}/abnormal") + @Transactional(rollbackFor = Exception.class) + public R markAbnormal(@PathVariable Long id, @RequestParam("nextAction") String nextAction) { + FollowupTask task = taskService.getById(id); + if (task != null) { + task.setAbnormalFlag(true); + task.setNextAction(nextAction); + taskService.updateById(task); + } + return R.ok(); + } + + @DeleteMapping("/task/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteTask(@PathVariable Long id) { + // 联动删除该任务下的所有记录 + LambdaQueryWrapper rw = new LambdaQueryWrapper<>(); + rw.eq(FollowupRecord::getTaskId, id); + recordService.remove(rw); + taskService.removeById(id); + return R.ok(); + } + + // ==================== 随访记录 ==================== + + @GetMapping("/record/page") + public R getRecordPage( + @RequestParam(value = "taskId", required = false) Long taskId, + @RequestParam(value = "patientId", required = false) Long patientId, + @RequestParam(value = "medicationCompliance", required = false) String medicationCompliance, + @RequestParam(value = "reappointmentFlag", required = false) Boolean reappointmentFlag, + @RequestParam(value = "transferFlag", required = false) Boolean transferFlag, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(taskId != null, FollowupRecord::getTaskId, taskId) + .eq(patientId != null, FollowupRecord::getPatientId, patientId) + .eq(StringUtils.hasText(medicationCompliance), FollowupRecord::getMedicationCompliance, medicationCompliance) + .eq(reappointmentFlag != null, FollowupRecord::getReappointmentFlag, reappointmentFlag) + .eq(transferFlag != null, FollowupRecord::getTransferFlag, transferFlag) + .orderByDesc(FollowupRecord::getOperateTime); + return R.ok(recordService.page(new Page<>(pageNo, pageSize), w)); + } + + @PostMapping("/record/add") + @Transactional(rollbackFor = Exception.class) + public R addRecord(@RequestBody FollowupRecord record) { + record.setOperateTime(new Date()); + recordService.save(record); + // 联动更新任务状态为SUCCESS + if (record.getTaskId() != null) { + FollowupTask task = taskService.getById(record.getTaskId()); + if (task != null) { + task.setResult("SUCCESS"); + task.setActualDate(LocalDate.now()); + taskService.updateById(task); + } + } + return R.ok(record); + } + + @PutMapping("/record/update") + @Transactional(rollbackFor = Exception.class) + public R updateRecord(@RequestBody FollowupRecord record) { + recordService.updateById(record); + return R.ok(record); + } + + @DeleteMapping("/record/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteRecord(@PathVariable Long id) { + recordService.removeById(id); + return R.ok(); + } + + // ==================== 满意度调查 ==================== + + @GetMapping("/survey/page") + public R getSurveyPage( + @RequestParam(value = "departmentName", required = false) String departmentName, + @RequestParam(value = "doctorName", required = false) String doctorName, + @RequestParam(value = "surveyType", required = false) String surveyType, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(StringUtils.hasText(departmentName), SatisfactionSurvey::getDepartmentName, departmentName) + .eq(StringUtils.hasText(doctorName), SatisfactionSurvey::getDoctorName, doctorName) + .eq(StringUtils.hasText(surveyType), SatisfactionSurvey::getSurveyType, surveyType) + .orderByDesc(SatisfactionSurvey::getSurveyDate); + return R.ok(surveyService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/survey/stats") + public R getSurveyStats( + @RequestParam(value = "departmentName", required = false) String departmentName, + @RequestParam(value = "startDate", required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") LocalDate startDate, + @RequestParam(value = "endDate", required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") LocalDate endDate) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(StringUtils.hasText(departmentName), SatisfactionSurvey::getDepartmentName, departmentName) + .ge(startDate != null, SatisfactionSurvey::getSurveyDate, startDate) + .le(endDate != null, SatisfactionSurvey::getSurveyDate, endDate); + List list = surveyService.list(w); + if (list.isEmpty()) { + return R.ok("暂无数据"); + } + double avgOverall = list.stream().mapToInt(SatisfactionSurvey::getOverallScore).average().orElse(0); + double avgService = list.stream().mapToInt(SatisfactionSurvey::getServiceScore).average().orElse(0); + double avgEnv = list.stream().mapToInt(SatisfactionSurvey::getEnvironmentScore).average().orElse(0); + java.util.Map stats = new java.util.HashMap<>(); + stats.put("total", list.size()); + stats.put("avgOverall", Math.round(avgOverall * 100) / 100.0); + stats.put("avgService", Math.round(avgService * 100) / 100.0); + stats.put("avgEnvironment", Math.round(avgEnv * 100) / 100.0); + return R.ok(stats); + } + + @PostMapping("/survey/add") + @Transactional(rollbackFor = Exception.class) + public R addSurvey(@RequestBody SatisfactionSurvey survey) { + survey.setCreateTime(new Date()); + surveyService.save(survey); + return R.ok(survey); + } + + @DeleteMapping("/survey/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteSurvey(@PathVariable Long id) { + surveyService.removeById(id); + return R.ok(); + } + + // ==================== 投诉记录 ==================== + + @GetMapping("/complaint/page") + public R getComplaintPage( + @RequestParam(value = "patientName", required = false) String patientName, + @RequestParam(value = "complaintType", required = false) String complaintType, + @RequestParam(value = "departmentName", required = false) String departmentName, + @RequestParam(value = "status", required = false) String status, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.like(StringUtils.hasText(patientName), ComplaintRecord::getPatientName, patientName) + .eq(StringUtils.hasText(complaintType), ComplaintRecord::getComplaintType, complaintType) + .eq(StringUtils.hasText(departmentName), ComplaintRecord::getDepartmentName, departmentName) + .eq(StringUtils.hasText(status), ComplaintRecord::getStatus, status) + .orderByDesc(ComplaintRecord::getCreateTime); + return R.ok(complaintService.page(new Page<>(pageNo, pageSize), w)); + } + + @PostMapping("/complaint/add") + @Transactional(rollbackFor = Exception.class) + public R addComplaint(@RequestBody ComplaintRecord complaint) { + if (!StringUtils.hasText(complaint.getStatus())) { + complaint.setStatus("PENDING"); + } + complaint.setCreateTime(new Date()); + complaintService.save(complaint); + return R.ok(complaint); + } + + @PutMapping("/complaint/handle") + @Transactional(rollbackFor = Exception.class) + public R handleComplaint(@RequestBody ComplaintRecord complaint) { + complaint.setHandleTime(new Date()); + complaint.setStatus("HANDLED"); + complaintService.updateById(complaint); + return R.ok(complaint); + } + + @PutMapping("/complaint/close/{id}") + @Transactional(rollbackFor = Exception.class) + public R closeComplaint(@PathVariable Long id) { + ComplaintRecord c = complaintService.getById(id); + if (c != null) { + c.setStatus("CLOSED"); + complaintService.updateById(c); + } + return R.ok(); + } + + @DeleteMapping("/complaint/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteComplaint(@PathVariable Long id) { + complaintService.removeById(id); + return R.ok(); + } +} diff --git a/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/pathology/controller/PathologyController.java b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/pathology/controller/PathologyController.java new file mode 100644 index 000000000..0872b3f26 --- /dev/null +++ b/healthlink-his-server/healthlink-his-application/src/main/java/com/healthlink/his/web/pathology/controller/PathologyController.java @@ -0,0 +1,315 @@ +package com.healthlink.his.web.pathology.controller; + +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; +import com.baomidou.mybatisplus.extension.plugins.pagination.Page; +import com.core.common.core.domain.R; +import com.healthlink.his.pathology.domain.*; +import com.healthlink.his.pathology.service.*; +import lombok.AllArgsConstructor; +import lombok.extern.slf4j.Slf4j; +import org.springframework.format.annotation.DateTimeFormat; +import org.springframework.transaction.annotation.Transactional; +import org.springframework.util.StringUtils; +import org.springframework.web.bind.annotation.*; + +import java.time.LocalDate; +import java.util.Date; +import java.util.List; + +/** + * 病理管理 Controller — 深度业务逻辑 + * + * 业务说明: + * 1. 病理医嘱: 临床医生开具病理检查医嘱,包含标本类型、采集部位、紧急程度 + * 2. 标本管理: 标本采集→固定→接收→合格性检查→不合格退回,全流程条码追踪 + * 3. 病理报告: 取材→制片→初诊→审核→签发,三级审核制度(初诊→审核→终审) + * 4. 与手术模块联动: 手术中切除标本自动触发病理送检 + * 5. 与门诊/住院联动: 病理结果回写到电子病历,驱动后续治疗方案 + * + * 调用关系: + * PathologyController → IPathologyOrderService → PathologyOrderMapper → DB + * → IPathologySpecimenService → 标本全流程追踪 + * → IPathologyReportService → 三级审核报告签发 + */ +@RestController +@RequestMapping("/pathology") +@Slf4j +@AllArgsConstructor +public class PathologyController { + + private final IPathologyOrderService orderService; + private final IPathologySpecimenService specimenService; + private final IPathologyReportService reportService; + + // ==================== 病理医嘱 ==================== + + @GetMapping("/order/page") + public R getOrderPage( + @RequestParam(value = "patientName", required = false) String patientName, + @RequestParam(value = "specimenType", required = false) String specimenType, + @RequestParam(value = "urgency", required = false) String urgency, + @RequestParam(value = "orderStatus", required = false) String orderStatus, + @RequestParam(value = "applyDoctor", required = false) String applyDoctor, + @RequestParam(value = "encounterId", required = false) Long encounterId, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.like(StringUtils.hasText(patientName), PathologyOrder::getPatientName, patientName) + .eq(StringUtils.hasText(specimenType), PathologyOrder::getSpecimenType, specimenType) + .eq(StringUtils.hasText(urgency), PathologyOrder::getUrgency, urgency) + .eq(StringUtils.hasText(orderStatus), PathologyOrder::getOrderStatus, orderStatus) + .eq(StringUtils.hasText(applyDoctor), PathologyOrder::getApplyDoctor, applyDoctor) + .eq(encounterId != null, PathologyOrder::getEncounterId, encounterId) + .orderByDesc(PathologyOrder::getApplyTime); + return R.ok(orderService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/order/{id}") + public R getOrderById(@PathVariable Long id) { + return R.ok(orderService.getById(id)); + } + + @PostMapping("/order/add") + @Transactional(rollbackFor = Exception.class) + public R addOrder(@RequestBody PathologyOrder order) { + if (!StringUtils.hasText(order.getOrderStatus())) { + order.setOrderStatus("PENDING"); + } + order.setApplyTime(new Date()); + order.setCreateTime(new Date()); + orderService.save(order); + return R.ok(order); + } + + @PutMapping("/order/update") + @Transactional(rollbackFor = Exception.class) + public R updateOrder(@RequestBody PathologyOrder order) { + orderService.updateById(order); + return R.ok(order); + } + + @PutMapping("/order/cancel/{id}") + @Transactional(rollbackFor = Exception.class) + public R cancelOrder(@PathVariable Long id) { + PathologyOrder order = orderService.getById(id); + if (order != null) { + order.setOrderStatus("CANCELLED"); + orderService.updateById(order); + } + return R.ok(); + } + + @DeleteMapping("/order/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteOrder(@PathVariable Long id) { + orderService.removeById(id); + return R.ok(); + } + + // ==================== 标本管理 ==================== + + @GetMapping("/specimen/page") + public R getSpecimenPage( + @RequestParam(value = "orderId", required = false) Long orderId, + @RequestParam(value = "barcode", required = false) String barcode, + @RequestParam(value = "isQualified", required = false) Boolean isQualified, + @RequestParam(value = "receiver", required = false) String receiver, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(orderId != null, PathologySpecimen::getOrderId, orderId) + .like(StringUtils.hasText(barcode), PathologySpecimen::getBarcode, barcode) + .eq(isQualified != null, PathologySpecimen::getIsQualified, isQualified) + .eq(StringUtils.hasText(receiver), PathologySpecimen::getReceiver, receiver) + .orderByDesc(PathologySpecimen::getReceiveTime); + return R.ok(specimenService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/specimen/{id}") + public R getSpecimenById(@PathVariable Long id) { + return R.ok(specimenService.getById(id)); + } + + @GetMapping("/specimen/barcode/{barcode}") + public R getSpecimenByBarcode(@PathVariable String barcode) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(PathologySpecimen::getBarcode, barcode); + return R.ok(specimenService.getOne(w)); + } + + @PostMapping("/specimen/add") + @Transactional(rollbackFor = Exception.class) + public R addSpecimen(@RequestBody PathologySpecimen specimen) { + specimen.setCreateTime(new Date()); + specimenService.save(specimen); + // 联动更新病理医嘱状态为已采集 + if (specimen.getOrderId() != null) { + PathologyOrder order = orderService.getById(specimen.getOrderId()); + if (order != null && "PENDING".equals(order.getOrderStatus())) { + order.setOrderStatus("COLLECTED"); + orderService.updateById(order); + } + } + return R.ok(specimen); + } + + @PutMapping("/specimen/receive") + @Transactional(rollbackFor = Exception.class) + public R receiveSpecimen(@RequestBody PathologySpecimen specimen) { + specimen.setReceiveTime(new Date()); + specimenService.updateById(specimen); + // 联动更新病理医嘱状态为已接收 + if (specimen.getOrderId() != null) { + PathologyOrder order = orderService.getById(specimen.getOrderId()); + if (order != null && "COLLECTED".equals(order.getOrderStatus())) { + order.setOrderStatus("RECEIVED"); + orderService.updateById(order); + } + } + return R.ok(specimen); + } + + @PutMapping("/specimen/{id}/qualify") + @Transactional(rollbackFor = Exception.class) + public R qualifySpecimen(@PathVariable Long id, @RequestParam("qualified") boolean qualified, + @RequestParam(value = "rejectReason", required = false) String rejectReason) { + PathologySpecimen specimen = specimenService.getById(id); + if (specimen != null) { + specimen.setIsQualified(qualified); + if (!qualified) { + specimen.setRejectReason(rejectReason); + } + specimenService.updateById(specimen); + } + return R.ok(); + } + + @DeleteMapping("/specimen/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteSpecimen(@PathVariable Long id) { + specimenService.removeById(id); + return R.ok(); + } + + // ==================== 病理报告 ==================== + + @GetMapping("/report/page") + public R getReportPage( + @RequestParam(value = "orderId", required = false) Long orderId, + @RequestParam(value = "patientId", required = false) Long patientId, + @RequestParam(value = "status", required = false) String status, + @RequestParam(value = "reportDoctor", required = false) String reportDoctor, + @RequestParam(value = "auditDoctor", required = false) String auditDoctor, + @RequestParam(value = "pageNo", defaultValue = "1") Integer pageNo, + @RequestParam(value = "pageSize", defaultValue = "20") Integer pageSize) { + LambdaQueryWrapper w = new LambdaQueryWrapper<>(); + w.eq(orderId != null, PathologyReport::getOrderId, orderId) + .eq(patientId != null, PathologyReport::getPatientId, patientId) + .eq(StringUtils.hasText(status), PathologyReport::getStatus, status) + .eq(StringUtils.hasText(reportDoctor), PathologyReport::getReportDoctor, reportDoctor) + .eq(StringUtils.hasText(auditDoctor), PathologyReport::getAuditDoctor, auditDoctor) + .orderByDesc(PathologyReport::getReportTime); + return R.ok(reportService.page(new Page<>(pageNo, pageSize), w)); + } + + @GetMapping("/report/{id}") + public R getReportById(@PathVariable Long id) { + return R.ok(reportService.getById(id)); + } + + @PostMapping("/report/add") + @Transactional(rollbackFor = Exception.class) + public R addReport(@RequestBody PathologyReport report) { + if (!StringUtils.hasText(report.getStatus())) { + report.setStatus("DRAFT"); + } + report.setCreateTime(new Date()); + reportService.save(report); + return R.ok(report); + } + + @PutMapping("/report/update") + @Transactional(rollbackFor = Exception.class) + public R updateReport(@RequestBody PathologyReport report) { + reportService.updateById(report); + return R.ok(report); + } + + @PutMapping("/report/{id}/submit") + @Transactional(rollbackFor = Exception.class) + public R submitReport(@PathVariable Long id) { + PathologyReport report = reportService.getById(id); + if (report != null) { + report.setStatus("SUBMITTED"); + reportService.updateById(report); + } + return R.ok(); + } + + @PutMapping("/report/{id}/audit") + @Transactional(rollbackFor = Exception.class) + public R auditReport(@PathVariable Long id, @RequestBody PathologyReport auditData) { + PathologyReport report = reportService.getById(id); + if (report != null) { + report.setAuditDoctor(auditData.getAuditDoctor()); + report.setAuditTime(new Date()); + report.setStatus("AUDITED"); + reportService.updateById(report); + } + return R.ok(); + } + + @PutMapping("/report/{id}/final") + @Transactional(rollbackFor = Exception.class) + public R finalSignReport(@PathVariable Long id, @RequestBody PathologyReport finalData) { + PathologyReport report = reportService.getById(id); + if (report != null) { + report.setFinalDoctor(finalData.getFinalDoctor()); + report.setFinalTime(new Date()); + report.setStatus("SIGNED"); + reportService.updateById(report); + // 联动更新病理医嘱状态为已完成 + if (report.getOrderId() != null) { + PathologyOrder order = orderService.getById(report.getOrderId()); + if (order != null) { + order.setOrderStatus("COMPLETED"); + orderService.updateById(order); + } + } + } + return R.ok(); + } + + @DeleteMapping("/report/delete/{id}") + @Transactional(rollbackFor = Exception.class) + public R deleteReport(@PathVariable Long id) { + reportService.removeById(id); + return R.ok(); + } + + // ==================== 统计 ==================== + + @GetMapping("/stats/summary") + public R getStatsSummary( + @RequestParam(value = "startDate", required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") LocalDate startDate, + @RequestParam(value = "endDate", required = false) @DateTimeFormat(pattern = "yyyy-MM-dd") LocalDate endDate) { + java.util.Map stats = new java.util.HashMap<>(); + LambdaQueryWrapper ow = new LambdaQueryWrapper<>(); + ow.ge(startDate != null, PathologyOrder::getApplyTime, startDate != null ? java.sql.Date.valueOf(startDate) : null) + .le(endDate != null, PathologyOrder::getApplyTime, endDate != null ? java.sql.Date.valueOf(endDate) : null); + stats.put("totalOrders", orderService.count(ow)); + + LambdaQueryWrapper sw = new LambdaQueryWrapper<>(); + sw.eq(PathologySpecimen::getIsQualified, true); + stats.put("qualifiedSpecimens", specimenService.count(sw)); + + LambdaQueryWrapper sw2 = new LambdaQueryWrapper<>(); + sw2.eq(PathologySpecimen::getIsQualified, false); + stats.put("rejectedSpecimens", specimenService.count(sw2)); + + LambdaQueryWrapper rw = new LambdaQueryWrapper<>(); + rw.eq(PathologyReport::getStatus, "SIGNED"); + stats.put("signedReports", reportService.count(rw)); + return R.ok(stats); + } +} diff --git a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V24__outpatient_enhancement.sql b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V24__outpatient_enhancement.sql index a3de5158c..8725f058f 100644 --- a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V24__outpatient_enhancement.sql +++ b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V24__outpatient_enhancement.sql @@ -12,7 +12,7 @@ CREATE TABLE IF NOT EXISTS structured_emr_template ( is_system BOOLEAN DEFAULT FALSE, status VARCHAR(20) DEFAULT 'ACTIVE', tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_by VARCHAR(64), create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, update_by VARCHAR(64), @@ -34,26 +34,17 @@ CREATE TABLE IF NOT EXISTS icd10_diagnosis_code ( status VARCHAR(20) DEFAULT 'ACTIVE' ); COMMENT ON TABLE icd10_diagnosis_code IS 'ICD-10诊断编码库'; -CREATE UNIQUE INDEX idx_icd10_code ON icd10_diagnosis_code(code); -CREATE INDEX idx_icd10_name ON icd10_diagnosis_code(name); +CREATE UNIQUE INDEX IF NOT EXISTS idx_icd10_code ON icd10_diagnosis_code(code); +CREATE INDEX IF NOT EXISTS idx_icd10_name ON icd10_diagnosis_code(name); --- 3. 合理用药审核规则 -CREATE TABLE IF NOT EXISTS drug_interaction_rule ( - id BIGSERIAL PRIMARY KEY, - drug_a VARCHAR(200) NOT NULL, - drug_b VARCHAR(200), - interaction_type VARCHAR(50) NOT NULL, - severity VARCHAR(20) NOT NULL, - description TEXT, - suggestion TEXT, - status VARCHAR(20) DEFAULT 'ACTIVE', - tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, - create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP -); -COMMENT ON TABLE drug_interaction_rule IS '合理用药审核规则'; +-- 3. 合理用药审核规则 (table created in V2, add missing columns) +ALTER TABLE drug_interaction_rule ADD COLUMN IF NOT EXISTS interaction_type VARCHAR(50) DEFAULT 'INTERACTION'; +ALTER TABLE drug_interaction_rule ADD COLUMN IF NOT EXISTS status VARCHAR(20) DEFAULT 'ACTIVE'; +ALTER TABLE drug_interaction_rule ADD COLUMN IF NOT EXISTS drug_a VARCHAR(200); +ALTER TABLE drug_interaction_rule ADD COLUMN IF NOT EXISTS drug_b VARCHAR(200); +ALTER TABLE drug_interaction_rule ADD COLUMN IF NOT EXISTS delete_flag VARCHAR(1) DEFAULT '0'; +ALTER TABLE drug_interaction_rule ADD COLUMN IF NOT EXISTS tenant_id BIGINT DEFAULT 0; COMMENT ON COLUMN drug_interaction_rule.interaction_type IS '类型(CONTRAINDICATION禁忌/INTERACTION相互作用/DUPLICATE重复/PRESCRIBING处方)'; -COMMENT ON COLUMN drug_interaction_rule.severity IS '严重程度(HIGH/MEDIUM/LOW)'; -- 4. 出院小结 CREATE TABLE IF NOT EXISTS discharge_summary ( @@ -74,7 +65,7 @@ CREATE TABLE IF NOT EXISTS discharge_summary ( doctor_id BIGINT, status INT NOT NULL DEFAULT 0, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_by VARCHAR(64), create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, update_by VARCHAR(64), @@ -82,7 +73,7 @@ CREATE TABLE IF NOT EXISTS discharge_summary ( ); COMMENT ON TABLE discharge_summary IS '出院小结'; COMMENT ON COLUMN discharge_summary.status IS '状态(0草稿 1已完成 2已归档)'; -CREATE INDEX idx_ds_encounter ON discharge_summary(encounter_id); +CREATE INDEX IF NOT EXISTS idx_ds_encounter ON discharge_summary(encounter_id); -- 5. 处方前置拦截记录 CREATE TABLE IF NOT EXISTS prescription_intercept_log ( diff --git a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V25__vitalsigns_safety_barcode_audit.sql b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V25__vitalsigns_safety_barcode_audit.sql index 733a2720a..1345fc79c 100644 --- a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V25__vitalsigns_safety_barcode_audit.sql +++ b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V25__vitalsigns_safety_barcode_audit.sql @@ -22,12 +22,12 @@ CREATE TABLE IF NOT EXISTS nursing_vital_signs_chart ( stool_count INT, nurse_name VARCHAR(50), tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE nursing_vital_signs_chart IS '体温单数据(三测单)'; -CREATE INDEX idx_nvs_encounter ON nursing_vital_signs_chart(encounter_id); -CREATE INDEX idx_nvs_date ON nursing_vital_signs_chart(record_date); +CREATE INDEX IF NOT EXISTS idx_nvs_encounter ON nursing_vital_signs_chart(encounter_id); +CREATE INDEX IF NOT EXISTS idx_nvs_date ON nursing_vital_signs_chart(record_date); -- 2. 术前安全核查 CREATE TABLE IF NOT EXISTS surgery_safety_check ( @@ -50,13 +50,13 @@ CREATE TABLE IF NOT EXISTS surgery_safety_check ( surgeon_name VARCHAR(50), nurse_name VARCHAR(50), tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_by VARCHAR(64), create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE surgery_safety_check IS '术前安全核查(WS/T 313)'; COMMENT ON COLUMN surgery_safety_check.check_phase IS '核查阶段(ANESTHESIA_BEFORE麻醉前/SURGERY_BEFORE手术前/EXIT离室前)'; -CREATE INDEX idx_ssc_encounter ON surgery_safety_check(encounter_id); +CREATE INDEX IF NOT EXISTS idx_ssc_encounter ON surgery_safety_check(encounter_id); -- 3. 标本条码 CREATE TABLE IF NOT EXISTS specimen_barcode ( @@ -73,12 +73,12 @@ CREATE TABLE IF NOT EXISTS specimen_barcode ( scan_confirm_by VARCHAR(50), status VARCHAR(20) DEFAULT 'COLLECTED', tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE specimen_barcode IS '标本条码管理'; COMMENT ON COLUMN specimen_barcode.status IS '状态(COLLECTED已采集/SCANNED已扫码/REJECTED已拒收)'; -CREATE UNIQUE INDEX idx_sb_barcode ON specimen_barcode(barcode); +CREATE UNIQUE INDEX IF NOT EXISTS idx_sb_barcode ON specimen_barcode(barcode); -- 4. 审计日志 CREATE TABLE IF NOT EXISTS sys_audit_log ( @@ -97,9 +97,9 @@ CREATE TABLE IF NOT EXISTS sys_audit_log ( create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE sys_audit_log IS '审计日志(所有接口调用可追溯)'; -CREATE INDEX idx_audit_time ON sys_audit_log(create_time); -CREATE INDEX idx_audit_user ON sys_audit_log(user_id); -CREATE INDEX idx_audit_module ON sys_audit_log(module); +CREATE INDEX IF NOT EXISTS idx_audit_time ON sys_audit_log(create_time); +CREATE INDEX IF NOT EXISTS idx_audit_user ON sys_audit_log(user_id); +CREATE INDEX IF NOT EXISTS idx_audit_module ON sys_audit_log(module); -- 5. 身份证校验记录 CREATE TABLE IF NOT EXISTS empi_id_verification ( @@ -113,9 +113,9 @@ CREATE TABLE IF NOT EXISTS empi_id_verification ( verify_source VARCHAR(50), verify_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE empi_id_verification IS '身份证校验记录'; COMMENT ON COLUMN empi_id_verification.verify_result IS '校验结果(PASS通过/FAIL失败/PENDING待验)'; -CREATE INDEX idx_idv_patient ON empi_id_verification(patient_id); +CREATE INDEX IF NOT EXISTS idx_idv_patient ON empi_id_verification(patient_id); diff --git a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V26__nursing_assessment_enhancement.sql b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V26__nursing_assessment_enhancement.sql index 47f6549e7..a0f6c8a96 100644 --- a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V26__nursing_assessment_enhancement.sql +++ b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V26__nursing_assessment_enhancement.sql @@ -13,14 +13,14 @@ CREATE TABLE IF NOT EXISTS nursing_assessment_intervention ( execute_time TIMESTAMP, status VARCHAR(20) DEFAULT 'PENDING', tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE nursing_assessment_intervention IS '评估干预措施'; COMMENT ON COLUMN nursing_assessment_intervention.intervention_type IS '干预类型(PRESSURE_ULCER/FALL_RISK/NUTRITION/PAIN/TUBE)'; COMMENT ON COLUMN nursing_assessment_intervention.status IS '状态(PENDING/EXECUTED/CANCELLED)'; -CREATE INDEX idx_nai_encounter ON nursing_assessment_intervention(encounter_id); -CREATE INDEX idx_nai_status ON nursing_assessment_intervention(status); +CREATE INDEX IF NOT EXISTS idx_nai_encounter ON nursing_assessment_intervention(encounter_id); +CREATE INDEX IF NOT EXISTS idx_nai_status ON nursing_assessment_intervention(status); -- 评估统计视图 CREATE OR REPLACE VIEW v_assessment_stats AS diff --git a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V27__emr_revision_archive.sql b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V27__emr_revision_archive.sql index 120b7513a..866b580ec 100644 --- a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V27__emr_revision_archive.sql +++ b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V27__emr_revision_archive.sql @@ -18,12 +18,12 @@ CREATE TABLE IF NOT EXISTS emr_archive_record ( archived_by VARCHAR(64), file_path VARCHAR(500), tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE emr_archive_record IS '病历打印归档记录'; COMMENT ON COLUMN emr_archive_record.archive_type IS '归档类型(PRINT打印/ARCHIVE归档/REPRINT补打)'; COMMENT ON COLUMN emr_archive_record.archive_status IS '状态(PRINTED已打印/ARCHIVED已归档/LOST遗失)'; -CREATE INDEX idx_ear_encounter ON emr_archive_record(encounter_id); -CREATE INDEX idx_ear_patient ON emr_archive_record(patient_id); -CREATE INDEX idx_ear_status ON emr_archive_record(archive_status); +CREATE INDEX IF NOT EXISTS idx_ear_encounter ON emr_archive_record(encounter_id); +CREATE INDEX IF NOT EXISTS idx_ear_patient ON emr_archive_record(patient_id); +CREATE INDEX IF NOT EXISTS idx_ear_status ON emr_archive_record(archive_status); diff --git a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V28__drg_dip_grouping.sql b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V28__drg_dip_grouping.sql index 29f7e328b..daf727527 100644 --- a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V28__drg_dip_grouping.sql +++ b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V28__drg_dip_grouping.sql @@ -26,14 +26,14 @@ CREATE TABLE IF NOT EXISTS mr_drg_grouping ( is_valid BOOLEAN DEFAULT TRUE, invalid_reason VARCHAR(200), tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, - create_time TIMESTAMP DEFAULT CURRENT CURRENT_TIMESTAMP + delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE mr_drg_grouping IS 'DRG/DIP分组结果'; COMMENT ON COLUMN mr_drg_grouping.grouping_type IS '分组类型(DRG/DIP)'; -CREATE INDEX idx_drg_encounter ON mr_drg_grouping(encounter_id); -CREATE INDEX idx_drg_code ON mr_drg_grouping(drg_code); -CREATE INDEX idx_dip_code ON mr_drg_grouping(dip_code); +CREATE INDEX IF NOT EXISTS idx_drg_encounter ON mr_drg_grouping(encounter_id); +CREATE INDEX IF NOT EXISTS idx_drg_code ON mr_drg_grouping(drg_code); +CREATE INDEX IF NOT EXISTS idx_dip_code ON mr_drg_grouping(dip_code); -- 病案归档统计表 CREATE TABLE IF NOT EXISTS mr_archive_stats ( @@ -46,7 +46,7 @@ CREATE TABLE IF NOT EXISTS mr_archive_stats ( archive_rate DECIMAL(5,2), avg_archive_hours DECIMAL(8,2), tenant_id BIGINT DEFAULT 0, - create_time TIMESTAMP DEFAULT CURRENT CURRENT_TIMESTAMP + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE mr_archive_stats IS '病案归档统计(每日)'; -CREATE UNIQUE INDEX idx_mras_date_dept ON mr_archive_stats(stat_date, department_id); +CREATE UNIQUE INDEX IF NOT EXISTS idx_mras_date_dept ON mr_archive_stats(stat_date, department_id); diff --git a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V29__esb_reliability.sql b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V29__esb_reliability.sql index 93c600e46..de8baa7e2 100644 --- a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V29__esb_reliability.sql +++ b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V29__esb_reliability.sql @@ -17,13 +17,13 @@ CREATE TABLE IF NOT EXISTS esb_dead_letter ( resolved_by VARCHAR(64), resolved_time TIMESTAMP, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, - create_time TIMESTAMP DEFAULT CURRENT CURRENT_TIMESTAMP + delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE esb_dead_letter IS '死信队列(多次重试失败的消息)'; COMMENT ON COLUMN esb_dead_letter.status IS '状态(PENDING待处理/RESOLVED已解决/IGNORED已忽略)'; -CREATE INDEX idx_dl_status ON esb_dead_letter(status); -CREATE INDEX idx_dl_message ON esb_dead_letter(message_id); +CREATE INDEX IF NOT EXISTS idx_dl_status ON esb_dead_letter(status); +CREATE INDEX IF NOT EXISTS idx_dl_message ON esb_dead_letter(message_id); -- ESB监控统计表 CREATE TABLE IF NOT EXISTS esb_monitor_stats ( @@ -37,7 +37,7 @@ CREATE TABLE IF NOT EXISTS esb_monitor_stats ( retry_count INT DEFAULT 0, avg_duration_ms INT DEFAULT 0, tenant_id BIGINT DEFAULT 0, - create_time TIMESTAMP DEFAULT CURRENT CURRENT_TIMESTAMP + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE esb_monitor_stats IS 'ESB消息监控统计(每小时)'; -CREATE UNIQUE INDEX idx_ems_hour ON esb_monitor_stats(stat_hour, source_system, target_system); +CREATE UNIQUE INDEX IF NOT EXISTS idx_ems_hour ON esb_monitor_stats(stat_hour, source_system, target_system); diff --git a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V30__remaining_capabilities.sql b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V30__remaining_capabilities.sql index 8d468d1b3..af0ed842c 100644 --- a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V30__remaining_capabilities.sql +++ b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V30__remaining_capabilities.sql @@ -15,11 +15,11 @@ CREATE TABLE IF NOT EXISTS lab_reference_range ( critical_high DECIMAL(10,4), is_active BOOLEAN DEFAULT TRUE, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE lab_reference_range IS '检验参考范围(按年龄/性别)'; -CREATE INDEX idx_lrr_item ON lab_reference_range(item_code); +CREATE INDEX IF NOT EXISTS idx_lrr_item ON lab_reference_range(item_code); -- 2. 检查预约排队 CREATE TABLE IF NOT EXISTS exam_appointment ( @@ -37,13 +37,13 @@ CREATE TABLE IF NOT EXISTS exam_appointment ( room VARCHAR(50), device VARCHAR(100), tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE exam_appointment IS '检查预约排队'; COMMENT ON COLUMN exam_appointment.status IS '状态(APPOINTED已预约/CHECKED_IN已签到/EXAMINING检查中/COMPLETED已完成/CANCELLED已取消)'; -CREATE INDEX idx_ea_date ON exam_appointment(appoint_date); -CREATE INDEX idx_ea_status ON exam_appointment(status); +CREATE INDEX IF NOT EXISTS idx_ea_date ON exam_appointment(appoint_date); +CREATE INDEX IF NOT EXISTS idx_ea_status ON exam_appointment(status); -- 3. 影像图像记录 CREATE TABLE IF NOT EXISTS radiology_image ( @@ -60,11 +60,11 @@ CREATE TABLE IF NOT EXISTS radiology_image ( series_desc VARCHAR(200), instance_number INT, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE radiology_image IS '影像图像记录(DICOM)'; -CREATE INDEX idx_ri_apply ON radiology_image(apply_id); +CREATE INDEX IF NOT EXISTS idx_ri_apply ON radiology_image(apply_id); -- 4. 图文报告 CREATE TABLE IF NOT EXISTS radiology_image_report ( @@ -84,12 +84,12 @@ CREATE TABLE IF NOT EXISTS radiology_image_report ( verify_time TIMESTAMP, status VARCHAR(20) DEFAULT 'DRAFT', tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE radiology_image_report IS '影像图文报告'; COMMENT ON COLUMN radiology_image_report.status IS '状态(DRAFT草稿/REPORTED已报告/VERIFIED已审核)'; -CREATE INDEX idx_rir_apply ON radiology_image_report(apply_id); +CREATE INDEX IF NOT EXISTS idx_rir_apply ON radiology_image_report(apply_id); -- 5. DICOM打印记录 CREATE TABLE IF NOT EXISTS dicom_print_record ( @@ -103,7 +103,7 @@ CREATE TABLE IF NOT EXISTS dicom_print_record ( print_by VARCHAR(64), print_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE dicom_print_record IS 'DICOM胶片打印记录'; @@ -121,11 +121,11 @@ CREATE TABLE IF NOT EXISTS clinical_pathway ( version INT DEFAULT 1, status VARCHAR(20) DEFAULT 'ACTIVE', tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE clinical_pathway IS '临床路径定义'; -CREATE INDEX idx_cp_disease ON clinical_pathway(disease_code); +CREATE INDEX IF NOT EXISTS idx_cp_disease ON clinical_pathway(disease_code); -- 临床路径执行记录 CREATE TABLE IF NOT EXISTS clinical_pathway_execution ( @@ -143,12 +143,12 @@ CREATE TABLE IF NOT EXISTS clinical_pathway_execution ( status VARCHAR(20) DEFAULT 'IN_PATH', complete_date DATE, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE clinical_pathway_execution IS '临床路径执行记录'; COMMENT ON COLUMN clinical_pathway_execution.status IS '状态(IN_PATH入径/COMPLETED完成/VARIATION变异/EXIT退出)'; -CREATE INDEX idx_cpe_pathway ON clinical_pathway_execution(pathway_id); +CREATE INDEX IF NOT EXISTS idx_cpe_pathway ON clinical_pathway_execution(pathway_id); -- 7. DRG/DIP分析统计 CREATE TABLE IF NOT EXISTS drg_analysis_stats ( @@ -166,7 +166,7 @@ CREATE TABLE IF NOT EXISTS drg_analysis_stats ( create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE drg_analysis_stats IS 'DRG/DIP月度分析统计'; -CREATE UNIQUE INDEX idx_das_month ON drg_analysis_stats(stat_month, department_name, drg_code); +CREATE UNIQUE INDEX IF NOT EXISTS idx_das_month ON drg_analysis_stats(stat_month, department_name, drg_code); -- 8. ICD-10编码库 CREATE TABLE IF NOT EXISTS icd10_code ( @@ -182,5 +182,5 @@ CREATE TABLE IF NOT EXISTS icd10_code ( create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE icd10_code IS 'ICD-10诊断编码库'; -CREATE UNIQUE INDEX idx_icd10_code ON icd10_code(code); -CREATE INDEX idx_icd10_pinyin ON icd10_code(pinyin); +CREATE UNIQUE INDEX IF NOT EXISTS idx_icd10_code_v2 ON icd10_code(code); +CREATE INDEX IF NOT EXISTS idx_icd10_pinyin ON icd10_code(pinyin); diff --git a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V31__cssd_3d_reconstruction.sql b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V31__cssd_3d_reconstruction.sql index d1b121156..a019df7d9 100644 --- a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V31__cssd_3d_reconstruction.sql +++ b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V31__cssd_3d_reconstruction.sql @@ -14,13 +14,13 @@ CREATE TABLE IF NOT EXISTS cssd_tray ( last_sterilize_time TIMESTAMP, max_uses INT DEFAULT 100, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE cssd_tray IS 'CSSD器械包'; COMMENT ON COLUMN cssd_tray.tray_type IS '类型(OPERATION手术/TUBE管腔/PRECISION精密/COMMON普通)'; COMMENT ON COLUMN cssd_tray.status IS '状态(IN_USE在用/WASHING清洗中/STERILIZING灭菌中/STORED储存中/DISTRIBUTED已发放)'; -CREATE UNIQUE INDEX idx_ct_code ON cssd_tray(tray_code); +CREATE UNIQUE INDEX IF NOT EXISTS idx_ct_code ON cssd_tray(tray_code); -- 2. CSSD追溯记录 CREATE TABLE IF NOT EXISTS cssd_trace_record ( @@ -41,8 +41,8 @@ CREATE TABLE IF NOT EXISTS cssd_trace_record ( ); COMMENT ON TABLE cssd_trace_record IS 'CSSD追溯记录'; COMMENT ON COLUMN cssd_trace_record.step_type IS '步骤(RECYCLE回收/WASH清洗/DISINFECT消毒/PACK包装/STERILIZE灭菌/STORE储存/DISTRIBUTE发放)'; -CREATE INDEX idx_ctr_tray ON cssd_trace_record(tray_id); -CREATE INDEX idx_ctr_time ON cssd_trace_record(operation_time); +CREATE INDEX IF NOT EXISTS idx_ctr_tray ON cssd_trace_record(tray_id); +CREATE INDEX IF NOT EXISTS idx_ctr_time ON cssd_trace_record(operation_time); -- 3. CSSD灭菌批次 CREATE TABLE IF NOT EXISTS cssd_sterilize_batch ( @@ -63,12 +63,12 @@ CREATE TABLE IF NOT EXISTS cssd_sterilize_batch ( release_by VARCHAR(64), release_time TIMESTAMP, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE cssd_sterilize_batch IS 'CSSD灭菌批次'; COMMENT ON COLUMN cssd_sterilize_batch.batch_status IS '状态(RUNNING进行中/COMPLETED已完成/RELEASED已释放/REJECTED已拒绝)'; -CREATE UNIQUE INDEX idx_csb_code ON cssd_sterilize_batch(batch_code); +CREATE UNIQUE INDEX IF NOT EXISTS idx_csb_code ON cssd_sterilize_batch(batch_code); -- 4. CSSD灭菌包明细 CREATE TABLE IF NOT EXISTS cssd_sterilize_item ( @@ -81,7 +81,7 @@ CREATE TABLE IF NOT EXISTS cssd_sterilize_item ( create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE cssd_sterilize_item IS '灭菌包明细'; -CREATE INDEX idx_csi_batch ON cssd_sterilize_item(batch_id); +CREATE INDEX IF NOT EXISTS idx_csi_batch ON cssd_sterilize_item(batch_id); -- 5. CSSD过期预警 CREATE TABLE IF NOT EXISTS cssd_expiry_alert ( @@ -97,7 +97,7 @@ CREATE TABLE IF NOT EXISTS cssd_expiry_alert ( ); COMMENT ON TABLE cssd_expiry_alert IS 'CSSD过期预警'; COMMENT ON COLUMN cssd_expiry_alert.status IS '状态(NORMAL正常/ALERT预警/EXPIRED过期)'; -CREATE INDEX idx_cea_status ON cssd_expiry_alert(status); +CREATE INDEX IF NOT EXISTS idx_cea_status ON cssd_expiry_alert(status); -- 6. 影像3D重建任务 CREATE TABLE IF NOT EXISTS reconstruction_task ( @@ -118,12 +118,12 @@ CREATE TABLE IF NOT EXISTS reconstruction_task ( request_doctor VARCHAR(64), complete_time TIMESTAMP, tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE reconstruction_task IS '影像3D重建任务'; COMMENT ON COLUMN reconstruction_task.reconstruction_type IS '重建类型(VR容积渲染/MPR多平面/MIP最大密度投影)'; -CREATE INDEX idx_rt_status ON reconstruction_task(task_status); +CREATE INDEX IF NOT EXISTS idx_rt_status ON reconstruction_task(task_status); -- 7. 影像3D重建结果 CREATE TABLE IF NOT EXISTS reconstruction_result ( @@ -137,7 +137,7 @@ CREATE TABLE IF NOT EXISTS reconstruction_result ( create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE reconstruction_result IS '3D重建结果'; -CREATE INDEX idx_rr_task ON reconstruction_result(task_id); +CREATE INDEX IF NOT EXISTS idx_rr_task ON reconstruction_result(task_id); -- 8. 影像3D重建报告 CREATE TABLE IF NOT EXISTS reconstruction_report ( @@ -154,8 +154,8 @@ CREATE TABLE IF NOT EXISTS reconstruction_report ( verify_time TIMESTAMP, status VARCHAR(20) DEFAULT 'DRAFT', tenant_id BIGINT DEFAULT 0, - is_deleted INT NOT NULL DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP ); COMMENT ON TABLE reconstruction_report IS '3D重建报告'; -CREATE INDEX idx_rrp_task ON reconstruction_report(task_id); +CREATE INDEX IF NOT EXISTS idx_rrp_task ON reconstruction_report(task_id); diff --git a/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V32__followup_pathology_emergency.sql b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V32__followup_pathology_emergency.sql new file mode 100644 index 000000000..def23482a --- /dev/null +++ b/healthlink-his-server/healthlink-his-application/src/main/resources/db/migration/V32__followup_pathology_emergency.sql @@ -0,0 +1,149 @@ +-- V32: Phase A 核心模块 — 随访/病理/急诊 + +-- ===== 1. 门诊随访管理 ===== +CREATE TABLE IF NOT EXISTS followup_plan ( + id BIGSERIAL PRIMARY KEY, patient_id BIGINT NOT NULL, patient_name VARCHAR(50), + encounter_id BIGINT, disease_code VARCHAR(20), disease_name VARCHAR(100), + followup_type VARCHAR(20) NOT NULL, frequency VARCHAR(20), + total_times INT DEFAULT 1, completed_times INT DEFAULT 0, + responsible_doctor VARCHAR(64), responsible_nurse VARCHAR(64), + start_date DATE, end_date DATE, status VARCHAR(20) DEFAULT 'ACTIVE', + tenant_id BIGINT DEFAULT 0, delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE followup_plan IS '随访计划'; +CREATE INDEX IF NOT EXISTS idx_fp_patient ON followup_plan(patient_id); +CREATE INDEX IF NOT EXISTS idx_fp_status ON followup_plan(status); + +CREATE TABLE IF NOT EXISTS followup_task ( + id BIGSERIAL PRIMARY KEY, plan_id BIGINT NOT NULL, patient_id BIGINT NOT NULL, + patient_name VARCHAR(50), phone VARCHAR(20), scheduled_date DATE NOT NULL, + actual_date DATE, contact_method VARCHAR(20), operator_name VARCHAR(64), + result VARCHAR(20), abnormal_flag BOOLEAN DEFAULT FALSE, next_action VARCHAR(200), + tenant_id BIGINT DEFAULT 0, delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE followup_task IS '随访任务'; +CREATE INDEX IF NOT EXISTS idx_ft_plan ON followup_task(plan_id); +CREATE INDEX IF NOT EXISTS idx_ft_date ON followup_task(scheduled_date); + +CREATE TABLE IF NOT EXISTS followup_record ( + id BIGSERIAL PRIMARY KEY, task_id BIGINT NOT NULL, patient_id BIGINT NOT NULL, + contact_content TEXT, patient_condition TEXT, medication_compliance VARCHAR(20), + symptoms TEXT, reappointment_flag BOOLEAN DEFAULT FALSE, reappointment_date DATE, + transfer_flag BOOLEAN DEFAULT FALSE, transfer_reason TEXT, + operator_name VARCHAR(64), operate_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + tenant_id BIGINT DEFAULT 0, create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE followup_record IS '随访记录'; + +CREATE TABLE IF NOT EXISTS satisfaction_survey ( + id BIGSERIAL PRIMARY KEY, patient_id BIGINT, patient_name VARCHAR(50), + survey_type VARCHAR(20) NOT NULL, department_name VARCHAR(100), doctor_name VARCHAR(64), + overall_score INT, service_score INT, environment_score INT, suggestions TEXT, + survey_date DATE DEFAULT CURRENT_DATE, tenant_id BIGINT DEFAULT 0, + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE satisfaction_survey IS '满意度调查'; + +CREATE TABLE IF NOT EXISTS complaint_record ( + id BIGSERIAL PRIMARY KEY, patient_id BIGINT, patient_name VARCHAR(50), + complaint_type VARCHAR(30) NOT NULL, complaint_content TEXT NOT NULL, + department_name VARCHAR(100), handler VARCHAR(64), handle_result TEXT, + handle_time TIMESTAMP, status VARCHAR(20) DEFAULT 'PENDING', + satisfaction_after INT, tenant_id BIGINT DEFAULT 0, + delete_flag VARCHAR(1) DEFAULT '0', create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE complaint_record IS '投诉记录'; + +-- ===== 2. 病理管理 ===== +CREATE TABLE IF NOT EXISTS pathology_order ( + id BIGSERIAL PRIMARY KEY, patient_id BIGINT NOT NULL, patient_name VARCHAR(50), + encounter_id BIGINT, specimen_type VARCHAR(50), clinical_diagnosis TEXT, + sample_site VARCHAR(100), urgency VARCHAR(20) DEFAULT 'NORMAL', + order_status VARCHAR(20) DEFAULT 'PENDING', apply_doctor VARCHAR(64), + apply_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + tenant_id BIGINT DEFAULT 0, delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE pathology_order IS '病理申请'; +CREATE INDEX IF NOT EXISTS idx_po_patient ON pathology_order(patient_id); + +CREATE TABLE IF NOT EXISTS pathology_specimen ( + id BIGSERIAL PRIMARY KEY, order_id BIGINT NOT NULL, barcode VARCHAR(100) NOT NULL, + specimen_desc TEXT, collection_site VARCHAR(100), fixative VARCHAR(50), + fixative_time TIMESTAMP, receive_time TIMESTAMP, receiver VARCHAR(64), + is_qualified BOOLEAN DEFAULT TRUE, reject_reason TEXT, + tenant_id BIGINT DEFAULT 0, delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE pathology_specimen IS '病理标本'; +CREATE UNIQUE INDEX IF NOT EXISTS idx_ps_barcode ON pathology_specimen(barcode); + +CREATE TABLE IF NOT EXISTS pathology_process ( + id BIGSERIAL PRIMARY KEY, specimen_id BIGINT NOT NULL, + process_type VARCHAR(30), process_desc TEXT, operator VARCHAR(64), + operate_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + tenant_id BIGINT DEFAULT 0, create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE pathology_process IS '病理处理记录'; + +CREATE TABLE IF NOT EXISTS pathology_report ( + id BIGSERIAL PRIMARY KEY, order_id BIGINT NOT NULL, patient_id BIGINT, + specimen_desc TEXT, macroscopic_desc TEXT, microscopic_desc TEXT, + diagnosis_result TEXT, suggestion TEXT, + report_doctor VARCHAR(64), report_time TIMESTAMP, + audit_doctor VARCHAR(64), audit_time TIMESTAMP, + final_doctor VARCHAR(64), final_time TIMESTAMP, + status VARCHAR(20) DEFAULT 'DRAFT', + tenant_id BIGINT DEFAULT 0, delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE pathology_report IS '病理报告'; +CREATE INDEX IF NOT EXISTS idx_pr_order ON pathology_report(order_id); + +-- ===== 3. 急诊分诊+抢救 ===== +CREATE TABLE IF NOT EXISTS emergency_triage ( + id BIGSERIAL PRIMARY KEY, patient_id BIGINT, patient_name VARCHAR(50), + triage_level INT NOT NULL, chief_complaint TEXT, + temperature DECIMAL(4,1), pulse INT, respiration INT, + systolic_bp INT, diastolic_bp INT, spo2 INT, consciousness VARCHAR(20), + triage_nurse VARCHAR(64), triage_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP, + area VARCHAR(20), status VARCHAR(20) DEFAULT 'WAITING', + tenant_id BIGINT DEFAULT 0, delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE emergency_triage IS '急诊分诊'; +CREATE INDEX IF NOT EXISTS idx_et_level ON emergency_triage(triage_level); +CREATE INDEX IF NOT EXISTS idx_et_time ON emergency_triage(triage_time); + +CREATE TABLE IF NOT EXISTS emergency_rescue ( + id BIGSERIAL PRIMARY KEY, patient_id BIGINT NOT NULL, triage_id BIGINT, + rescue_start TIMESTAMP, rescue_end TIMESTAMP, rescue_result VARCHAR(20), + chief_doctor VARCHAR(64), rescue_team TEXT, + procedures TEXT, medications TEXT, + outcome VARCHAR(20), + tenant_id BIGINT DEFAULT 0, delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE emergency_rescue IS '抢救记录'; + +CREATE TABLE IF NOT EXISTS emergency_observation ( + id BIGSERIAL PRIMARY KEY, patient_id BIGINT NOT NULL, triage_id BIGINT, + observation_start TIMESTAMP, observation_end TIMESTAMP, bed_no VARCHAR(20), + doctor VARCHAR(64), diagnosis TEXT, disposition VARCHAR(20), + observation_hours INT, + tenant_id BIGINT DEFAULT 0, delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE emergency_observation IS '留观记录'; + +CREATE TABLE IF NOT EXISTS emergency_green_channel ( + id BIGSERIAL PRIMARY KEY, patient_id BIGINT NOT NULL, + disease_type VARCHAR(30), + door_to_treatment_time INT, target_time INT, is_achieved BOOLEAN, + doctor VARCHAR(64), activate_time TIMESTAMP, complete_time TIMESTAMP, + tenant_id BIGINT DEFAULT 0, delete_flag VARCHAR(1) DEFAULT '0', + create_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP +); +COMMENT ON TABLE emergency_green_channel IS '绿色通道'; diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyGreenChannel.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyGreenChannel.java new file mode 100644 index 000000000..91356963d --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyGreenChannel.java @@ -0,0 +1,10 @@ +package com.healthlink.his.emergency.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.util.Date; +@Data @EqualsAndHashCode(callSuper=true) @TableName("emergency_green_channel") +public class EmergencyGreenChannel extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long patientId; private String diseaseType; + private Integer doorToTreatmentTime; private Integer targetTime; private Boolean isAchieved; + private String doctor; private Date activateTime; private Date completeTime; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyObservation.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyObservation.java new file mode 100644 index 000000000..e1576fe32 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyObservation.java @@ -0,0 +1,10 @@ +package com.healthlink.his.emergency.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.util.Date; +@Data @EqualsAndHashCode(callSuper=true) @TableName("emergency_observation") +public class EmergencyObservation extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long patientId; private Long triageId; private Date observationStart; private Date observationEnd; + private String bedNo; private String doctor; private String diagnosis; + private String disposition; private Integer observationHours; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyRescue.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyRescue.java new file mode 100644 index 000000000..00a2010ab --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyRescue.java @@ -0,0 +1,10 @@ +package com.healthlink.his.emergency.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.util.Date; +@Data @EqualsAndHashCode(callSuper=true) @TableName("emergency_rescue") +public class EmergencyRescue extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long patientId; private Long triageId; private Date rescueStart; private Date rescueEnd; + private String rescueResult; private String chiefDoctor; private String rescueTeam; + private String procedures; private String medications; private String outcome; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyTriage.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyTriage.java new file mode 100644 index 000000000..89a492a17 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/domain/EmergencyTriage.java @@ -0,0 +1,12 @@ +package com.healthlink.his.emergency.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.math.BigDecimal;import java.util.Date; +@Data @EqualsAndHashCode(callSuper=true) @TableName("emergency_triage") +public class EmergencyTriage extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long patientId; private String patientName; private Integer triageLevel; + private String chiefComplaint; private BigDecimal temperature; private Integer pulse; + private Integer respiration; private Integer systolicBp; private Integer diastolicBp; + private Integer spo2; private String consciousness; private String triageNurse; + private Date triageTime; private String area; private String status; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyGreenChannelMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyGreenChannelMapper.java new file mode 100644 index 000000000..180b6b415 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyGreenChannelMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.emergency.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.emergency.domain.EmergencyGreenChannel; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface EmergencyGreenChannelMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyObservationMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyObservationMapper.java new file mode 100644 index 000000000..3b2565afd --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyObservationMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.emergency.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.emergency.domain.EmergencyObservation; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface EmergencyObservationMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyRescueMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyRescueMapper.java new file mode 100644 index 000000000..3a364d850 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyRescueMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.emergency.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.emergency.domain.EmergencyRescue; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface EmergencyRescueMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyTriageMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyTriageMapper.java new file mode 100644 index 000000000..fff28014e --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/mapper/EmergencyTriageMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.emergency.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.emergency.domain.EmergencyTriage; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface EmergencyTriageMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyGreenChannelService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyGreenChannelService.java new file mode 100644 index 000000000..ac857b587 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyGreenChannelService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.emergency.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.emergency.domain.EmergencyGreenChannel; +public interface IEmergencyGreenChannelService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyObservationService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyObservationService.java new file mode 100644 index 000000000..5b5b6203f --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyObservationService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.emergency.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.emergency.domain.EmergencyObservation; +public interface IEmergencyObservationService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyRescueService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyRescueService.java new file mode 100644 index 000000000..828249198 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyRescueService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.emergency.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.emergency.domain.EmergencyRescue; +public interface IEmergencyRescueService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyTriageService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyTriageService.java new file mode 100644 index 000000000..824ffad34 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/IEmergencyTriageService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.emergency.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.emergency.domain.EmergencyTriage; +public interface IEmergencyTriageService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyGreenChannelServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyGreenChannelServiceImpl.java new file mode 100644 index 000000000..a2a352344 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyGreenChannelServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.emergency.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.emergency.domain.EmergencyGreenChannel; +import com.healthlink.his.emergency.mapper.EmergencyGreenChannelMapper; +import com.healthlink.his.emergency.service.IEmergencyGreenChannelService; +import org.springframework.stereotype.Service; +@Service +public class EmergencyGreenChannelServiceImpl extends ServiceImpl implements IEmergencyGreenChannelService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyObservationServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyObservationServiceImpl.java new file mode 100644 index 000000000..486010bf3 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyObservationServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.emergency.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.emergency.domain.EmergencyObservation; +import com.healthlink.his.emergency.mapper.EmergencyObservationMapper; +import com.healthlink.his.emergency.service.IEmergencyObservationService; +import org.springframework.stereotype.Service; +@Service +public class EmergencyObservationServiceImpl extends ServiceImpl implements IEmergencyObservationService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyRescueServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyRescueServiceImpl.java new file mode 100644 index 000000000..0b56b6c77 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyRescueServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.emergency.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.emergency.domain.EmergencyRescue; +import com.healthlink.his.emergency.mapper.EmergencyRescueMapper; +import com.healthlink.his.emergency.service.IEmergencyRescueService; +import org.springframework.stereotype.Service; +@Service +public class EmergencyRescueServiceImpl extends ServiceImpl implements IEmergencyRescueService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyTriageServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyTriageServiceImpl.java new file mode 100644 index 000000000..67eabb1cb --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/emergency/service/impl/EmergencyTriageServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.emergency.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.emergency.domain.EmergencyTriage; +import com.healthlink.his.emergency.mapper.EmergencyTriageMapper; +import com.healthlink.his.emergency.service.IEmergencyTriageService; +import org.springframework.stereotype.Service; +@Service +public class EmergencyTriageServiceImpl extends ServiceImpl implements IEmergencyTriageService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/ComplaintRecord.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/ComplaintRecord.java new file mode 100644 index 000000000..3e40a81a3 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/ComplaintRecord.java @@ -0,0 +1,11 @@ +package com.healthlink.his.followup.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.util.Date; +@Data @EqualsAndHashCode(callSuper=true) @TableName("complaint_record") +public class ComplaintRecord extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long patientId; private String patientName; private String complaintType; + private String complaintContent; private String departmentName; + private String handler; private String handleResult; private Date handleTime; + private String status; private Integer satisfactionAfter; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupPlan.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupPlan.java new file mode 100644 index 000000000..e51f91a67 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupPlan.java @@ -0,0 +1,12 @@ +package com.healthlink.his.followup.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.time.LocalDate; +@Data @EqualsAndHashCode(callSuper=true) @TableName("followup_plan") +public class FollowupPlan extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long patientId; private String patientName; private Long encounterId; + private String diseaseCode; private String diseaseName; private String followupType; + private String frequency; private Integer totalTimes; private Integer completedTimes; + private String responsibleDoctor; private String responsibleNurse; + private LocalDate startDate; private LocalDate endDate; private String status; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupRecord.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupRecord.java new file mode 100644 index 000000000..03eeaaceb --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupRecord.java @@ -0,0 +1,12 @@ +package com.healthlink.his.followup.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.time.LocalDate;import java.util.Date; +@Data @EqualsAndHashCode(callSuper=true) @TableName("followup_record") +public class FollowupRecord extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long taskId; private Long patientId; private String contactContent; + private String patientCondition; private String medicationCompliance; private String symptoms; + private Boolean reappointmentFlag; private LocalDate reappointmentDate; + private Boolean transferFlag; private String transferReason; + private String operatorName; private Date operateTime; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupTask.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupTask.java new file mode 100644 index 000000000..493b5bfaa --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/FollowupTask.java @@ -0,0 +1,10 @@ +package com.healthlink.his.followup.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.time.LocalDate; +@Data @EqualsAndHashCode(callSuper=true) @TableName("followup_task") +public class FollowupTask extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long planId; private Long patientId; private String patientName; private String phone; + private LocalDate scheduledDate; private LocalDate actualDate; private String contactMethod; + private String operatorName; private String result; private Boolean abnormalFlag; private String nextAction; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/SatisfactionSurvey.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/SatisfactionSurvey.java new file mode 100644 index 000000000..973365a27 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/domain/SatisfactionSurvey.java @@ -0,0 +1,11 @@ +package com.healthlink.his.followup.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.time.LocalDate; +@Data @EqualsAndHashCode(callSuper=true) @TableName("satisfaction_survey") +public class SatisfactionSurvey extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long patientId; private String patientName; private String surveyType; + private String departmentName; private String doctorName; + private Integer overallScore; private Integer serviceScore; private Integer environmentScore; + private String suggestions; private LocalDate surveyDate; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/ComplaintRecordMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/ComplaintRecordMapper.java new file mode 100644 index 000000000..cad1e0c08 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/ComplaintRecordMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.followup.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.followup.domain.ComplaintRecord; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface ComplaintRecordMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupPlanMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupPlanMapper.java new file mode 100644 index 000000000..51e1a3a57 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupPlanMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.followup.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.followup.domain.FollowupPlan; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface FollowupPlanMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupRecordMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupRecordMapper.java new file mode 100644 index 000000000..2eb15c7c4 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupRecordMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.followup.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.followup.domain.FollowupRecord; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface FollowupRecordMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupTaskMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupTaskMapper.java new file mode 100644 index 000000000..7b675509b --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/FollowupTaskMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.followup.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.followup.domain.FollowupTask; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface FollowupTaskMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/SatisfactionSurveyMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/SatisfactionSurveyMapper.java new file mode 100644 index 000000000..d442d3722 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/mapper/SatisfactionSurveyMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.followup.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.followup.domain.SatisfactionSurvey; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface SatisfactionSurveyMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IComplaintRecordService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IComplaintRecordService.java new file mode 100644 index 000000000..bedd512ea --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IComplaintRecordService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.followup.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.followup.domain.ComplaintRecord; +public interface IComplaintRecordService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupPlanService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupPlanService.java new file mode 100644 index 000000000..813cc5c67 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupPlanService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.followup.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.followup.domain.FollowupPlan; +public interface IFollowupPlanService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupRecordService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupRecordService.java new file mode 100644 index 000000000..40e00ae8f --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupRecordService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.followup.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.followup.domain.FollowupRecord; +public interface IFollowupRecordService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupTaskService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupTaskService.java new file mode 100644 index 000000000..c80f30e9d --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/IFollowupTaskService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.followup.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.followup.domain.FollowupTask; +public interface IFollowupTaskService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/ISatisfactionSurveyService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/ISatisfactionSurveyService.java new file mode 100644 index 000000000..669eb2c9c --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/ISatisfactionSurveyService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.followup.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.followup.domain.SatisfactionSurvey; +public interface ISatisfactionSurveyService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/ComplaintRecordServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/ComplaintRecordServiceImpl.java new file mode 100644 index 000000000..2b48cafaa --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/ComplaintRecordServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.followup.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.followup.domain.ComplaintRecord; +import com.healthlink.his.followup.mapper.ComplaintRecordMapper; +import com.healthlink.his.followup.service.IComplaintRecordService; +import org.springframework.stereotype.Service; +@Service +public class ComplaintRecordServiceImpl extends ServiceImpl implements IComplaintRecordService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupPlanServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupPlanServiceImpl.java new file mode 100644 index 000000000..6c995ceb2 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupPlanServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.followup.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.followup.domain.FollowupPlan; +import com.healthlink.his.followup.mapper.FollowupPlanMapper; +import com.healthlink.his.followup.service.IFollowupPlanService; +import org.springframework.stereotype.Service; +@Service +public class FollowupPlanServiceImpl extends ServiceImpl implements IFollowupPlanService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupRecordServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupRecordServiceImpl.java new file mode 100644 index 000000000..89ab5c947 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupRecordServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.followup.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.followup.domain.FollowupRecord; +import com.healthlink.his.followup.mapper.FollowupRecordMapper; +import com.healthlink.his.followup.service.IFollowupRecordService; +import org.springframework.stereotype.Service; +@Service +public class FollowupRecordServiceImpl extends ServiceImpl implements IFollowupRecordService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupTaskServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupTaskServiceImpl.java new file mode 100644 index 000000000..dd8aa1acf --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/FollowupTaskServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.followup.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.followup.domain.FollowupTask; +import com.healthlink.his.followup.mapper.FollowupTaskMapper; +import com.healthlink.his.followup.service.IFollowupTaskService; +import org.springframework.stereotype.Service; +@Service +public class FollowupTaskServiceImpl extends ServiceImpl implements IFollowupTaskService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/SatisfactionSurveyServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/SatisfactionSurveyServiceImpl.java new file mode 100644 index 000000000..4e8882939 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/followup/service/impl/SatisfactionSurveyServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.followup.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.followup.domain.SatisfactionSurvey; +import com.healthlink.his.followup.mapper.SatisfactionSurveyMapper; +import com.healthlink.his.followup.service.ISatisfactionSurveyService; +import org.springframework.stereotype.Service; +@Service +public class SatisfactionSurveyServiceImpl extends ServiceImpl implements ISatisfactionSurveyService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologyOrder.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologyOrder.java new file mode 100644 index 000000000..9197bb202 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologyOrder.java @@ -0,0 +1,10 @@ +package com.healthlink.his.pathology.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.util.Date; +@Data @EqualsAndHashCode(callSuper=true) @TableName("pathology_order") +public class PathologyOrder extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long patientId; private String patientName; private Long encounterId; + private String specimenType; private String clinicalDiagnosis; private String sampleSite; + private String urgency; private String orderStatus; private String applyDoctor; private Date applyTime; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologyReport.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologyReport.java new file mode 100644 index 000000000..5223a40bd --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologyReport.java @@ -0,0 +1,13 @@ +package com.healthlink.his.pathology.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.util.Date; +@Data @EqualsAndHashCode(callSuper=true) @TableName("pathology_report") +public class PathologyReport extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long orderId; private Long patientId; private String specimenDesc; + private String macroscopicDesc; private String microscopicDesc; + private String diagnosisResult; private String suggestion; + private String reportDoctor; private Date reportTime; + private String auditDoctor; private Date auditTime; + private String finalDoctor; private Date finalTime; private String status; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologySpecimen.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologySpecimen.java new file mode 100644 index 000000000..83caae122 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/domain/PathologySpecimen.java @@ -0,0 +1,10 @@ +package com.healthlink.his.pathology.domain; +import com.baomidou.mybatisplus.annotation.*;import com.core.common.core.domain.HisBaseEntity; +import lombok.Data;import lombok.EqualsAndHashCode;import java.util.Date; +@Data @EqualsAndHashCode(callSuper=true) @TableName("pathology_specimen") +public class PathologySpecimen extends HisBaseEntity { + @TableId(value="id",type=IdType.ASSIGN_ID) private Long id; + private Long orderId; private String barcode; private String specimenDesc; + private String collectionSite; private String fixative; private Date fixativeTime; + private Date receiveTime; private String receiver; private Boolean isQualified; private String rejectReason; +} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologyOrderMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologyOrderMapper.java new file mode 100644 index 000000000..bf01caad8 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologyOrderMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.pathology.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.pathology.domain.PathologyOrder; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface PathologyOrderMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologyReportMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologyReportMapper.java new file mode 100644 index 000000000..af12ca7bd --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologyReportMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.pathology.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.pathology.domain.PathologyReport; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface PathologyReportMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologySpecimenMapper.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologySpecimenMapper.java new file mode 100644 index 000000000..fa1e25229 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/mapper/PathologySpecimenMapper.java @@ -0,0 +1,6 @@ +package com.healthlink.his.pathology.mapper; +import com.baomidou.mybatisplus.core.mapper.BaseMapper; +import com.healthlink.his.pathology.domain.PathologySpecimen; +import org.apache.ibatis.annotations.Mapper; +@Mapper +public interface PathologySpecimenMapper extends BaseMapper {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologyOrderService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologyOrderService.java new file mode 100644 index 000000000..540e718e9 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologyOrderService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.pathology.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.pathology.domain.PathologyOrder; +public interface IPathologyOrderService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologyReportService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologyReportService.java new file mode 100644 index 000000000..7596c96d7 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologyReportService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.pathology.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.pathology.domain.PathologyReport; +public interface IPathologyReportService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologySpecimenService.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologySpecimenService.java new file mode 100644 index 000000000..27f2956ed --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/IPathologySpecimenService.java @@ -0,0 +1,4 @@ +package com.healthlink.his.pathology.service; +import com.baomidou.mybatisplus.extension.service.IService; +import com.healthlink.his.pathology.domain.PathologySpecimen; +public interface IPathologySpecimenService extends IService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologyOrderServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologyOrderServiceImpl.java new file mode 100644 index 000000000..5a3f49432 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologyOrderServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.pathology.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.pathology.domain.PathologyOrder; +import com.healthlink.his.pathology.mapper.PathologyOrderMapper; +import com.healthlink.his.pathology.service.IPathologyOrderService; +import org.springframework.stereotype.Service; +@Service +public class PathologyOrderServiceImpl extends ServiceImpl implements IPathologyOrderService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologyReportServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologyReportServiceImpl.java new file mode 100644 index 000000000..a48cceba3 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologyReportServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.pathology.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.pathology.domain.PathologyReport; +import com.healthlink.his.pathology.mapper.PathologyReportMapper; +import com.healthlink.his.pathology.service.IPathologyReportService; +import org.springframework.stereotype.Service; +@Service +public class PathologyReportServiceImpl extends ServiceImpl implements IPathologyReportService {} diff --git a/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologySpecimenServiceImpl.java b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologySpecimenServiceImpl.java new file mode 100644 index 000000000..8b02d0828 --- /dev/null +++ b/healthlink-his-server/healthlink-his-domain/src/main/java/com/healthlink/his/pathology/service/impl/PathologySpecimenServiceImpl.java @@ -0,0 +1,8 @@ +package com.healthlink.his.pathology.service.impl; +import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl; +import com.healthlink.his.pathology.domain.PathologySpecimen; +import com.healthlink.his.pathology.mapper.PathologySpecimenMapper; +import com.healthlink.his.pathology.service.IPathologySpecimenService; +import org.springframework.stereotype.Service; +@Service +public class PathologySpecimenServiceImpl extends ServiceImpl implements IPathologySpecimenService {} diff --git a/healthlink-his-ui/src/views/emergency/greentrack/api.js b/healthlink-his-ui/src/views/emergency/greentrack/api.js new file mode 100644 index 000000000..db53f4d44 --- /dev/null +++ b/healthlink-his-ui/src/views/emergency/greentrack/api.js @@ -0,0 +1,7 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/emergency/green-channel/page',method:'get',params:p})} +export function getById(id){return request({url:'/emergency/green-channel/'+id,method:'get'})} +export function activate(d){return request({url:'/emergency/green-channel/activate',method:'post',data:d})} +export function complete(id,d){return request({url:'/emergency/green-channel/'+id+'/complete',method:'put',data:d})} +export function getStats(p){return request({url:'/emergency/green-channel/stats',method:'get',params:p})} +export function del(id){return request({url:'/emergency/green-channel/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/emergency/greentrack/index.vue b/healthlink-his-ui/src/views/emergency/greentrack/index.vue new file mode 100644 index 000000000..84e414c9c --- /dev/null +++ b/healthlink-his-ui/src/views/emergency/greentrack/index.vue @@ -0,0 +1,89 @@ + + diff --git a/healthlink-his-ui/src/views/emergency/observation/api.js b/healthlink-his-ui/src/views/emergency/observation/api.js new file mode 100644 index 000000000..b35ea8f21 --- /dev/null +++ b/healthlink-his-ui/src/views/emergency/observation/api.js @@ -0,0 +1,7 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/emergency/observation/page',method:'get',params:p})} +export function getById(id){return request({url:'/emergency/observation/'+id,method:'get'})} +export function add(d){return request({url:'/emergency/observation/add',method:'post',data:d})} +export function discharge(d){return request({url:'/emergency/observation/discharge',method:'put',data:d})} +export function updateDisposition(id,params){return request({url:'/emergency/observation/'+id+'/disposition',method:'put',params})} +export function del(id){return request({url:'/emergency/observation/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/emergency/observation/index.vue b/healthlink-his-ui/src/views/emergency/observation/index.vue new file mode 100644 index 000000000..5fd7e1d10 --- /dev/null +++ b/healthlink-his-ui/src/views/emergency/observation/index.vue @@ -0,0 +1,86 @@ + + diff --git a/healthlink-his-ui/src/views/emergency/rescue/api.js b/healthlink-his-ui/src/views/emergency/rescue/api.js new file mode 100644 index 000000000..76475807e --- /dev/null +++ b/healthlink-his-ui/src/views/emergency/rescue/api.js @@ -0,0 +1,7 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/emergency/rescue/page',method:'get',params:p})} +export function getById(id){return request({url:'/emergency/rescue/'+id,method:'get'})} +export function add(d){return request({url:'/emergency/rescue/add',method:'post',data:d})} +export function endRescue(d){return request({url:'/emergency/rescue/end',method:'put',data:d})} +export function updateResult(id,d){return request({url:'/emergency/rescue/'+id+'/result',method:'put',data:d})} +export function del(id){return request({url:'/emergency/rescue/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/emergency/rescue/index.vue b/healthlink-his-ui/src/views/emergency/rescue/index.vue new file mode 100644 index 000000000..b51459b84 --- /dev/null +++ b/healthlink-his-ui/src/views/emergency/rescue/index.vue @@ -0,0 +1,85 @@ + + diff --git a/healthlink-his-ui/src/views/emergency/triage/api.js b/healthlink-his-ui/src/views/emergency/triage/api.js new file mode 100644 index 000000000..8f7d1b1a1 --- /dev/null +++ b/healthlink-his-ui/src/views/emergency/triage/api.js @@ -0,0 +1,9 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/emergency/triage/page',method:'get',params:p})} +export function getRealtime(){return request({url:'/emergency/triage/realtime',method:'get'})} +export function getById(id){return request({url:'/emergency/triage/'+id,method:'get'})} +export function add(d){return request({url:'/emergency/triage/add',method:'post',data:d})} +export function update(d){return request({url:'/emergency/triage/update',method:'put',data:d})} +export function startTreatment(id){return request({url:'/emergency/triage/'+id+'/start-treatment',method:'put'})} +export function complete(id){return request({url:'/emergency/triage/'+id+'/complete',method:'put'})} +export function del(id){return request({url:'/emergency/triage/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/emergency/triage/index.vue b/healthlink-his-ui/src/views/emergency/triage/index.vue new file mode 100644 index 000000000..b56bbfe46 --- /dev/null +++ b/healthlink-his-ui/src/views/emergency/triage/index.vue @@ -0,0 +1,123 @@ + + + diff --git a/healthlink-his-ui/src/views/followup/complaint/api.js b/healthlink-his-ui/src/views/followup/complaint/api.js new file mode 100644 index 000000000..1d4e1ff9a --- /dev/null +++ b/healthlink-his-ui/src/views/followup/complaint/api.js @@ -0,0 +1,6 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/followup/complaint/page',method:'get',params:p})} +export function add(d){return request({url:'/followup/complaint/add',method:'post',data:d})} +export function handle(d){return request({url:'/followup/complaint/handle',method:'put',data:d})} +export function close(id){return request({url:'/followup/complaint/close/'+id,method:'put'})} +export function del(id){return request({url:'/followup/complaint/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/followup/complaint/index.vue b/healthlink-his-ui/src/views/followup/complaint/index.vue new file mode 100644 index 000000000..5db9b6a43 --- /dev/null +++ b/healthlink-his-ui/src/views/followup/complaint/index.vue @@ -0,0 +1,91 @@ + + diff --git a/healthlink-his-ui/src/views/followup/plan/api.js b/healthlink-his-ui/src/views/followup/plan/api.js new file mode 100644 index 000000000..f53c734b2 --- /dev/null +++ b/healthlink-his-ui/src/views/followup/plan/api.js @@ -0,0 +1,8 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/followup/plan/page',method:'get',params:p})} +export function getList(p){return request({url:'/followup/plan/list',method:'get',params:p})} +export function getById(id){return request({url:'/followup/plan/'+id,method:'get'})} +export function add(d){return request({url:'/followup/plan/add',method:'post',data:d})} +export function update(d){return request({url:'/followup/plan/update',method:'put',data:d})} +export function del(id){return request({url:'/followup/plan/delete/'+id,method:'delete'})} +export function complete(id){return request({url:'/followup/plan/complete/'+id,method:'put'})} diff --git a/healthlink-his-ui/src/views/followup/plan/index.vue b/healthlink-his-ui/src/views/followup/plan/index.vue new file mode 100644 index 000000000..60663e7d1 --- /dev/null +++ b/healthlink-his-ui/src/views/followup/plan/index.vue @@ -0,0 +1,95 @@ + + diff --git a/healthlink-his-ui/src/views/followup/record/api.js b/healthlink-his-ui/src/views/followup/record/api.js new file mode 100644 index 000000000..cb6a3707f --- /dev/null +++ b/healthlink-his-ui/src/views/followup/record/api.js @@ -0,0 +1,5 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/followup/record/page',method:'get',params:p})} +export function add(d){return request({url:'/followup/record/add',method:'post',data:d})} +export function update(d){return request({url:'/followup/record/update',method:'put',data:d})} +export function del(id){return request({url:'/followup/record/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/followup/record/index.vue b/healthlink-his-ui/src/views/followup/record/index.vue new file mode 100644 index 000000000..173840792 --- /dev/null +++ b/healthlink-his-ui/src/views/followup/record/index.vue @@ -0,0 +1,52 @@ + + diff --git a/healthlink-his-ui/src/views/followup/survey/api.js b/healthlink-his-ui/src/views/followup/survey/api.js new file mode 100644 index 000000000..b4cde33c4 --- /dev/null +++ b/healthlink-his-ui/src/views/followup/survey/api.js @@ -0,0 +1,5 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/followup/survey/page',method:'get',params:p})} +export function getStats(p){return request({url:'/followup/survey/stats',method:'get',params:p})} +export function add(d){return request({url:'/followup/survey/add',method:'post',data:d})} +export function del(id){return request({url:'/followup/survey/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/followup/survey/index.vue b/healthlink-his-ui/src/views/followup/survey/index.vue new file mode 100644 index 000000000..504b9cdd5 --- /dev/null +++ b/healthlink-his-ui/src/views/followup/survey/index.vue @@ -0,0 +1,75 @@ + + diff --git a/healthlink-his-ui/src/views/followup/task/api.js b/healthlink-his-ui/src/views/followup/task/api.js new file mode 100644 index 000000000..b37eec580 --- /dev/null +++ b/healthlink-his-ui/src/views/followup/task/api.js @@ -0,0 +1,8 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/followup/task/page',method:'get',params:p})} +export function getToday(p){return request({url:'/followup/task/today',method:'get',params:p})} +export function getById(id){return request({url:'/followup/task/'+id,method:'get'})} +export function add(d){return request({url:'/followup/task/add',method:'post',data:d})} +export function execute(d){return request({url:'/followup/task/execute',method:'put',data:d})} +export function markAbnormal(id,params){return request({url:'/followup/task/'+id+'/abnormal',method:'put',params})} +export function del(id){return request({url:'/followup/task/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/followup/task/index.vue b/healthlink-his-ui/src/views/followup/task/index.vue new file mode 100644 index 000000000..c911dfba8 --- /dev/null +++ b/healthlink-his-ui/src/views/followup/task/index.vue @@ -0,0 +1,92 @@ + + diff --git a/healthlink-his-ui/src/views/pathology/order/api.js b/healthlink-his-ui/src/views/pathology/order/api.js new file mode 100644 index 000000000..ac04e9b7e --- /dev/null +++ b/healthlink-his-ui/src/views/pathology/order/api.js @@ -0,0 +1,8 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/pathology/order/page',method:'get',params:p})} +export function getById(id){return request({url:'/pathology/order/'+id,method:'get'})} +export function add(d){return request({url:'/pathology/order/add',method:'post',data:d})} +export function update(d){return request({url:'/pathology/order/update',method:'put',data:d})} +export function cancel(id){return request({url:'/pathology/order/cancel/'+id,method:'put'})} +export function del(id){return request({url:'/pathology/order/delete/'+id,method:'delete'})} +export function getStats(p){return request({url:'/pathology/stats/summary',method:'get',params:p})} diff --git a/healthlink-his-ui/src/views/pathology/order/index.vue b/healthlink-his-ui/src/views/pathology/order/index.vue new file mode 100644 index 000000000..adb118b4c --- /dev/null +++ b/healthlink-his-ui/src/views/pathology/order/index.vue @@ -0,0 +1,85 @@ + + diff --git a/healthlink-his-ui/src/views/pathology/report/api.js b/healthlink-his-ui/src/views/pathology/report/api.js new file mode 100644 index 000000000..175716e26 --- /dev/null +++ b/healthlink-his-ui/src/views/pathology/report/api.js @@ -0,0 +1,9 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/pathology/report/page',method:'get',params:p})} +export function getById(id){return request({url:'/pathology/report/'+id,method:'get'})} +export function add(d){return request({url:'/pathology/report/add',method:'post',data:d})} +export function update(d){return request({url:'/pathology/report/update',method:'put',data:d})} +export function submitReport(id){return request({url:'/pathology/report/'+id+'/submit',method:'put'})} +export function auditReport(id,d){return request({url:'/pathology/report/'+id+'/audit',method:'put',data:d})} +export function finalSign(id,d){return request({url:'/pathology/report/'+id+'/final',method:'put',data:d})} +export function del(id){return request({url:'/pathology/report/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/pathology/report/index.vue b/healthlink-his-ui/src/views/pathology/report/index.vue new file mode 100644 index 000000000..5766f6d24 --- /dev/null +++ b/healthlink-his-ui/src/views/pathology/report/index.vue @@ -0,0 +1,97 @@ + + diff --git a/healthlink-his-ui/src/views/pathology/specimen/api.js b/healthlink-his-ui/src/views/pathology/specimen/api.js new file mode 100644 index 000000000..5942105a0 --- /dev/null +++ b/healthlink-his-ui/src/views/pathology/specimen/api.js @@ -0,0 +1,8 @@ +import request from '@/utils/request' +export function getPage(p){return request({url:'/pathology/specimen/page',method:'get',params:p})} +export function getById(id){return request({url:'/pathology/specimen/'+id,method:'get'})} +export function getByBarcode(barcode){return request({url:'/pathology/specimen/barcode/'+barcode,method:'get'})} +export function add(d){return request({url:'/pathology/specimen/add',method:'post',data:d})} +export function receive(d){return request({url:'/pathology/specimen/receive',method:'put',data:d})} +export function qualify(id,params){return request({url:'/pathology/specimen/'+id+'/qualify',method:'put',params})} +export function del(id){return request({url:'/pathology/specimen/delete/'+id,method:'delete'})} diff --git a/healthlink-his-ui/src/views/pathology/specimen/index.vue b/healthlink-his-ui/src/views/pathology/specimen/index.vue new file mode 100644 index 000000000..8e5e105ab --- /dev/null +++ b/healthlink-his-ui/src/views/pathology/specimen/index.vue @@ -0,0 +1,106 @@ + +