jh-module-ecg/jh-module-ecg-biz/pom.xml
@@ -179,6 +179,12 @@ <artifactId>spring-boot-configuration-processor</artifactId> <optional>true</optional> </dependency> <dependency> <groupId>cn.lihu</groupId> <artifactId>jh-module-infra-biz</artifactId> <version>2.2.0-jdk8-snapshot</version> <scope>compile</scope> </dependency> </dependencies> jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/appointment/vo/AppointmentPageReqVO.java
@@ -125,4 +125,19 @@ */ private String orderCreateTime; /** * 开单医生 */ private String doctor; /** * 开单医生编码 */ private String doctorCode; /** * 开单时间 */ private java.util.Date doctorTime; } jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/appointment/vo/AppointmentRespVO.java
@@ -153,4 +153,19 @@ private LocalDateTime createTime; /** * 开单医生 */ private String doctor; /** * 开单医生编码 */ private String doctorCode; /** * 开单时间 */ private Date doctorTime; } jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/controller/admin/appointment/vo/AppointmentSaveReqVO.java
@@ -117,4 +117,19 @@ * 登记时间 */ private Date registerDate; /** * 开单医生 */ private String doctor; /** * 开单医生编码 */ private String doctorCode; /** * 开单时间 */ private Date doctorTime; } jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/dal/dataobject/appointment/AppointmentDO.java
@@ -161,4 +161,19 @@ */ private String outpatientNo; /** * 开单医生 */ private String doctor; /** * 开单医生编码 */ private String doctorCode; /** * 开单时间 */ private Date doctorTime; } jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/appointment/AppointmentServiceImpl.java
@@ -30,13 +30,11 @@ import org.springframework.validation.annotation.Validated; import javax.annotation.Resource; import java.text.SimpleDateFormat; import java.time.LocalDate; import java.time.LocalDateTime; import java.time.format.DateTimeFormatter; import java.util.Date; import java.util.List; import java.util.Map; import java.util.Optional; import java.util.*; import java.util.stream.Collectors; import static cn.lihu.jh.framework.common.exception.util.ServiceExceptionUtil.exception; @@ -377,6 +375,23 @@ return null; }).ifPresent(appointment::setTolerance); // 医生开单时间 Optional.ofNullable(dataMap.get("controlActProcess")).map(controlActProcess -> (Map<String, Object>) controlActProcess).map(controlActProcess -> (Map<String, Object>) controlActProcess.get("subject")).map(subject -> (Map<String, Object>) subject.get("observationRequest")).map(observationRequest -> (Map<String, Object>) observationRequest.get("author")).map(author -> (Map<String, Object>) author.get("time")).map(time -> (String) time.get("value")).map(str -> { try { return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").parse(str); } catch (Exception e) { e.printStackTrace(); return null; } }).filter(Objects::nonNull).ifPresent(appointment::setDoctorTime); //设置开单医生姓名 Optional.ofNullable(dataMap.get("controlActProcess")).map(controlActProcess -> (Map<String, Object>) controlActProcess).map(controlActProcess -> (Map<String, Object>) controlActProcess.get("subject")).map(subject -> (Map<String, Object>) subject.get("observationRequest")).map(observationRequest -> (Map<String, Object>) observationRequest.get("author")).map(author -> (Map<String, Object>) author.get("assignedEntity")).map(assignedEntity -> (Map<String, Object>) assignedEntity.get("assignedPerson")).map(assignedPerson -> (Map<String, Object>) assignedPerson.get("name")).map(name -> (Map<String, Object>) name.get("item")).map(item -> (Map<String, Object>) item.get("part")).map(part -> (String) part.get("value")).ifPresent(appointment::setDoctor); //设置开单医生编码 Optional.ofNullable(dataMap.get("controlActProcess")).map(controlActProcess -> (Map<String, Object>) controlActProcess).map(controlActProcess -> (Map<String, Object>) controlActProcess.get("subject")).map(subject -> (Map<String, Object>) subject.get("observationRequest")).map(observationRequest -> (Map<String, Object>) observationRequest.get("author")).map(author -> (Map<String, Object>) author.get("assignedEntity")).map(assignedEntity -> (Map<String, Object>) assignedEntity.get("id")).map(id -> (Map<String, Object>) id.get("item")).map(item -> (String) item.get("extension")).ifPresent(appointment::setDoctorCode); // 设置患者来源类型 Optional.ofNullable(encounter.get("code")).map(code -> (Map<String, Object>) code).map(code -> (String) code.get("code")).map(Integer::parseInt).ifPresent(appointment::setPatSrc); jh-module-ecg/jh-module-ecg-biz/src/main/java/cn/lihu/jh/module/ecg/service/devrent/DevRentServiceImpl.java
@@ -25,6 +25,9 @@ import cn.lihu.jh.module.ecg.feign.FeeConfirmFeignService; import cn.lihu.jh.module.ecg.service.queue.QueueServiceTxFunctions; import cn.lihu.jh.module.ecg.webservice.WebServiceClient; import cn.lihu.jh.module.infra.dal.dataobject.config.ConfigDO; import cn.lihu.jh.module.infra.dal.mysql.config.ConfigMapper; import cn.lihu.jh.module.infra.service.config.ConfigService; import lombok.extern.slf4j.Slf4j; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Value; @@ -76,11 +79,11 @@ @Resource CheckTypeMapper checkTypeMapper; @Resource private ConfigService configService; @Autowired private WebServiceClient webServiceClient; @Value("${spring.profiles.active}") private String active; @Override @@ -163,7 +166,8 @@ } //检查完成后,此时检查登记写成了,需要将这个回写给集成平台(线上环境才回写) if (active.equals("prod")) { ConfigDO configDO = configService.getConfigByKey("ecg.back.data"); if (configDO.getValue().equals("1")) { if (createReqVO.getCheckType() != 100 && createReqVO.getCheckType() != 1000 && createReqVO.getCheckType() != 1100 && createReqVO.getCheckType() != 1400 && createReqVO.getCheckType() != 1500) { AppointmentDO appointmentDO = appointmentMapper.getByApplyNo(createReqVO.getApplyNo()); ApplicationTemplate app = new ApplicationTemplate(); @@ -175,15 +179,6 @@ //需要根据applyNo,将appiontment表里的status改成3 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "3", new Date()); } } else { //检查类型是床边的或常规的,需要根据applyNo,将appiontment表里的status改成7 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "7", null); } } else { if (createReqVO.getCheckType() != 100 && createReqVO.getCheckType() != 1000 && createReqVO.getCheckType() != 1100 && createReqVO.getCheckType() != 1400 && createReqVO.getCheckType() != 1500) { //需要根据applyNo,将appiontment表里的status改成3 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "4", null); } else { //检查类型是床边的或常规的,需要根据applyNo,将appiontment表里的status改成7 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "7", null); @@ -215,7 +210,8 @@ } //设备领取完成后,此时检查登记写成了,需要将这个回写给集成平台(线上环境才回写) if (active.equals("prod")) { ConfigDO configDO = configService.getConfigByKey("ecg.back.data"); if (configDO.getValue().equals("1")) { AppointmentDO appointmentDO = appointmentMapper.getByApplyNo(createReqVO.getApplyNo()); ApplicationTemplate app = new ApplicationTemplate(); String action = "S0405"; @@ -226,9 +222,6 @@ //需要根据applyNo,将appiontment表里的status改成3 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "3", new Date()); } } else { appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "3", new Date()); } List<Integer> jobTypeList = new ArrayList<Integer>(); jobTypeList.add(DevRentStateEnum.RECEIVED.getState()); @@ -488,7 +481,8 @@ createReqVO.setState(DevRentStateEnum.ROUTINE_CANCELLED.getState()); updateDevRent(createReqVO); if (active.equals("prod")) { ConfigDO configDO = configService.getConfigByKey("ecg.back.data"); if (configDO.getValue().equals("1")) { if (cancelReqVO.getCheckType() != 100 && cancelReqVO.getCheckType() != 1000 && cancelReqVO.getCheckType() != 1100 && cancelReqVO.getCheckType() != 1400 && cancelReqVO.getCheckType() != 1500) { AppointmentDO appointmentDO = appointmentMapper.getByApplyNo(createReqVO.getApplyNo()); ApplicationTemplate app = new ApplicationTemplate(); @@ -500,15 +494,6 @@ //需要根据applyNo,将appiontment表里的status改成3 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "4", null); } } else { //检查类型是床边的或常规的,需要根据applyNo,将appiontment表里的status改成7 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "7", null); } } else { if (cancelReqVO.getCheckType() != 100 && cancelReqVO.getCheckType() != 1000 && cancelReqVO.getCheckType() != 1100 && cancelReqVO.getCheckType() != 1400 && cancelReqVO.getCheckType() != 1500) { //需要根据applyNo,将appiontment表里的status改成3 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "4", null); } else { //检查类型是床边的或常规的,需要根据applyNo,将appiontment表里的status改成7 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "7", null); @@ -580,7 +565,8 @@ createReqVO.setState(DevRentStateEnum.RECEIVED_CANCELLED.getState()); updateDevRent(createReqVO); if (active.equals("prod")) { ConfigDO configDO = configService.getConfigByKey("ecg.back.data"); if (configDO.getValue().equals("1")) { AppointmentDO appointmentDO = appointmentMapper.getByApplyNo(createReqVO.getApplyNo()); ApplicationTemplate app = new ApplicationTemplate(); String action = "S0405"; @@ -590,15 +576,6 @@ if (s.contains("更新成功")) { //需要根据applyNo,将appiontment表里的status改成3 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "4", null); } } else { if (cancelReqVO.getCheckType() != 100 && cancelReqVO.getCheckType() != 1000 && cancelReqVO.getCheckType() != 1100 && cancelReqVO.getCheckType() != 1400 && cancelReqVO.getCheckType() != 1500) { //需要根据applyNo,将appiontment表里的status改成3 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "4", null); } else { //检查类型是床边的或常规的,需要根据applyNo,将appiontment表里的status改成7 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "7", null); } } @@ -663,7 +640,8 @@ createReqVO.setState(DevRentStateEnum.INSTALL_CANCELLED.getState()); updateDevRent(createReqVO); if (active.equals("prod")) { ConfigDO configDO = configService.getConfigByKey("ecg.back.data"); if (configDO.getValue().equals("1")) { AppointmentDO appointmentDO = appointmentMapper.getByApplyNo(createReqVO.getApplyNo()); ApplicationTemplate app = new ApplicationTemplate(); String action = "S0405"; @@ -673,14 +651,6 @@ if (s.contains("更新成功")) { //需要根据applyNo,将appiontment表里的status改成3 appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "4", null); } } else { //这里是测试本地修改 if (cancelReqVO.getCheckType() != 100 && cancelReqVO.getCheckType() != 1000 && cancelReqVO.getCheckType() != 1100 && cancelReqVO.getCheckType() != 1400 && cancelReqVO.getCheckType() != 1500) { appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "4", null); } else { appointmentMapper.updateStatusByApplyNo(createReqVO.getApplyNo(), "7", null); } } jh-server/src/main/resources/application-stage.yaml
@@ -75,7 +75,7 @@ # Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优 redis: host: 116.62.18.175 #r-bp1zyjl0g07e1ry08rpd.redis.rds.aliyuncs.com # 地址 host: 127.0.0.1 #r-bp1zyjl0g07e1ry08rpd.redis.rds.aliyuncs.com # 地址 port: 6020 #端口 6379 database: 15 # 数据库索引 password: Smartor #Root@yinyu # 密码,建议生产环境开启 jh-server/src/main/resources/application.yaml
@@ -4,7 +4,7 @@ profiles: active: prod # active: stage # active: stage main: allow-circular-references: true # 允许循环依赖,因为项目是三层架构,无法避免这个情况。 @@ -71,9 +71,9 @@ global-config: db-config: id-type: NONE # “智能”模式,基于 IdTypeEnvironmentPostProcessor + 数据源的类型,自动适配成 AUTO、INPUT 模式。 # id-type: AUTO # 自增 ID,适合 MySQL 等直接自增的数据库 # id-type: INPUT # 用户输入 ID,适合 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库 # id-type: ASSIGN_ID # 分配 ID,默认使用雪花算法。注意,Oracle、PostgreSQL、Kingbase、DB2、H2 数据库时,需要去除实体类上的 @KeySequence 注解 # id-type: AUTO # 自增 ID,适合 MySQL 等直接自增的数据库 # id-type: INPUT # 用户输入 ID,适合 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库 # id-type: ASSIGN_ID # 分配 ID,默认使用雪花算法。注意,Oracle、PostgreSQL、Kingbase、DB2、H2 数据库时,需要去除实体类上的 @KeySequence 注解 logic-delete-value: 1 # 逻辑已删除值(默认为 1) logic-not-delete-value: 0 # 逻辑未删除值(默认为 0) banner: false # 关闭控制台的 Banner 打印 @@ -182,13 +182,13 @@ model: generalv3.5 midjourney: enable: true # base-url: https://api.holdai.top/mj-relax/mj # base-url: https://api.holdai.top/mj-relax/mj base-url: https://api.holdai.top/mj api-key: sk-dZEPiVaNcT3FHhef51996bAa0bC74806BeAb620dA5Da10Bf notify-url: http://java.nat300.top/admin-api/ai/image/midjourney/notify suno: enable: true # base-url: https://suno-55ishh05u-status2xxs-projects.vercel.app # base-url: https://suno-55ishh05u-status2xxs-projects.vercel.app base-url: http://127.0.0.1:3001 --- #################### 芋道相关配置 ####################