feat:农垦同步转科信息
commit
173b598e9a
@ -0,0 +1,35 @@
|
|||||||
|
target/
|
||||||
|
!.mvn/wrapper/maven-wrapper.jar
|
||||||
|
|
||||||
|
### STS ###
|
||||||
|
.apt_generated
|
||||||
|
.classpath
|
||||||
|
.factorypath
|
||||||
|
.project
|
||||||
|
.settings
|
||||||
|
.springBeans
|
||||||
|
.sts4-cache
|
||||||
|
docus-services/docus-services-system1/
|
||||||
|
|
||||||
|
### IntelliJ IDEA ###
|
||||||
|
*.log
|
||||||
|
.idea
|
||||||
|
*.iws
|
||||||
|
*.iml
|
||||||
|
*.ipr
|
||||||
|
mvnw*
|
||||||
|
*.cmd
|
||||||
|
*.mvn
|
||||||
|
### NetBeans ###
|
||||||
|
/nbproject/private/
|
||||||
|
/nbbuild/
|
||||||
|
/dist/
|
||||||
|
/nbdist/
|
||||||
|
/.nb-gradle/
|
||||||
|
build/
|
||||||
|
!**/src/main/**/build/
|
||||||
|
!**/src/test/**/build/
|
||||||
|
|
||||||
|
### VS Code ###
|
||||||
|
.vscode/
|
||||||
|
logs*
|
@ -0,0 +1,73 @@
|
|||||||
|
<assembly xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/assembly-1.0.0.xsd">
|
||||||
|
|
||||||
|
<id>exe</id>
|
||||||
|
<formats>
|
||||||
|
<format>dir</format>
|
||||||
|
</formats>
|
||||||
|
<includeBaseDirectory>false</includeBaseDirectory>
|
||||||
|
|
||||||
|
<fileSets>
|
||||||
|
|
||||||
|
<fileSet>
|
||||||
|
<outputDirectory>/lib</outputDirectory>
|
||||||
|
<directory>${basedir}/target/lib</directory>
|
||||||
|
</fileSet>
|
||||||
|
|
||||||
|
<fileSet>
|
||||||
|
<outputDirectory>/config</outputDirectory>
|
||||||
|
<directory>${basedir}/target/resources</directory>
|
||||||
|
<fileMode>0755</fileMode>
|
||||||
|
<includes>
|
||||||
|
<include>*.xml</include>
|
||||||
|
<include>*.yml</include>
|
||||||
|
<include>*.properties</include>
|
||||||
|
</includes>
|
||||||
|
</fileSet>
|
||||||
|
|
||||||
|
<fileSet>
|
||||||
|
<outputDirectory>/dataConfig</outputDirectory>
|
||||||
|
<directory>${basedir}/target/dataConfig</directory>
|
||||||
|
<fileMode>0755</fileMode>
|
||||||
|
<includes>
|
||||||
|
<include>*.json</include>
|
||||||
|
</includes>
|
||||||
|
</fileSet>
|
||||||
|
|
||||||
|
<fileSet>
|
||||||
|
<outputDirectory>/</outputDirectory>
|
||||||
|
<directory>${basedir}/target/resources/bin</directory>
|
||||||
|
<fileMode>0755</fileMode>
|
||||||
|
<includes>
|
||||||
|
<include>*.bat</include>
|
||||||
|
</includes>
|
||||||
|
</fileSet>
|
||||||
|
|
||||||
|
<fileSet>
|
||||||
|
<outputDirectory>/</outputDirectory>
|
||||||
|
<directory>${basedir}/target/resources/bin</directory>
|
||||||
|
<fileMode>0755</fileMode>
|
||||||
|
<includes>
|
||||||
|
<include>*.xml</include>
|
||||||
|
</includes>
|
||||||
|
</fileSet>
|
||||||
|
|
||||||
|
<fileSet>
|
||||||
|
<outputDirectory>/</outputDirectory>
|
||||||
|
<directory>${basedir}</directory>
|
||||||
|
<fileMode>0755</fileMode>
|
||||||
|
<includes>
|
||||||
|
<include>*.exe</include>
|
||||||
|
</includes>
|
||||||
|
</fileSet>
|
||||||
|
<!-- 将项目启动jar打包到boot目录中 -->
|
||||||
|
<fileSet>
|
||||||
|
<directory>${basedir}/target</directory>
|
||||||
|
<outputDirectory>/</outputDirectory>
|
||||||
|
<fileMode>0755</fileMode>
|
||||||
|
<includes>
|
||||||
|
<include>${project.build.finalName}.jar</include>
|
||||||
|
</includes>
|
||||||
|
</fileSet>
|
||||||
|
</fileSets>
|
||||||
|
</assembly>
|
@ -0,0 +1,29 @@
|
|||||||
|
package com.docus.server;
|
||||||
|
|
||||||
|
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.mybatis.spring.annotation.MapperScan;
|
||||||
|
import org.springframework.boot.SpringApplication;
|
||||||
|
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||||
|
import org.springframework.cloud.openfeign.EnableFeignClients;
|
||||||
|
|
||||||
|
import java.util.Properties;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author wyb
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@SpringBootApplication(scanBasePackages ={"com.docus"})
|
||||||
|
@MapperScan("com.docus.server.**.mapper")
|
||||||
|
@EnableFeignClients(basePackages = {"com.docus"})
|
||||||
|
public class AppRunBootstrap {
|
||||||
|
public static void main(String[] args) {
|
||||||
|
Properties props = System.getProperties();
|
||||||
|
props.setProperty("org.apache.cxf.stax.allowInsecureParser", "1");
|
||||||
|
props.setProperty("UseSunHttpHandler", "true");
|
||||||
|
System.setProperty("javax.xml.parsers.DocumentBuilderFactory", "com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl");
|
||||||
|
SpringApplication.run(AppRunBootstrap.class, args);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,68 @@
|
|||||||
|
package com.docus.server.archive.entity;
|
||||||
|
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <p>
|
||||||
|
* 病案基本信息
|
||||||
|
* </p>
|
||||||
|
*
|
||||||
|
* @author jiashi
|
||||||
|
* @since 2021-04-14
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value = "TBasic对象", description = "病案基本信息")
|
||||||
|
public class TBasic implements Serializable {
|
||||||
|
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "病案主键")
|
||||||
|
private String patientId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "记账号")
|
||||||
|
private String jzh;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "病案号")
|
||||||
|
private String inpatientNo;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "住院次数")
|
||||||
|
private Integer admissTimes;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "患者姓名")
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "住院日期")
|
||||||
|
private Date admissDate;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "住院科室")
|
||||||
|
private String admissDept;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "住院科室名称")
|
||||||
|
private String admissDeptName;
|
||||||
|
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "主管医生工号")
|
||||||
|
private String attending;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "主管医生姓名")
|
||||||
|
private String attendingName;
|
||||||
|
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "出院日期")
|
||||||
|
private Date disDate;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "出院科室")
|
||||||
|
private String disDept;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "出院科室名称")
|
||||||
|
private String disDeptName;
|
||||||
|
|
||||||
|
}
|
@ -0,0 +1,47 @@
|
|||||||
|
package com.docus.server.archive.entity;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 转科信息
|
||||||
|
*
|
||||||
|
* @author YongBin Wen
|
||||||
|
* @date 2024/4/9 13:53
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class TBasicZkInfo {
|
||||||
|
/**
|
||||||
|
* 主键
|
||||||
|
**/
|
||||||
|
private Long id;
|
||||||
|
/**
|
||||||
|
* 病案主键
|
||||||
|
**/
|
||||||
|
private String patientId;
|
||||||
|
/**
|
||||||
|
* 转出科室编号
|
||||||
|
**/
|
||||||
|
private String outDeptCode;
|
||||||
|
/**
|
||||||
|
* 转出科室名称
|
||||||
|
**/
|
||||||
|
private String outDeptName;
|
||||||
|
/**
|
||||||
|
* 转出日期
|
||||||
|
**/
|
||||||
|
private Date outDate;
|
||||||
|
/**
|
||||||
|
* 转入科室编号
|
||||||
|
**/
|
||||||
|
private String inDeptCode;
|
||||||
|
/**
|
||||||
|
* 转入科室名称
|
||||||
|
**/
|
||||||
|
private String inDeptName;
|
||||||
|
/**
|
||||||
|
* 数据创建时间
|
||||||
|
**/
|
||||||
|
private Date createTime;
|
||||||
|
}
|
@ -0,0 +1,15 @@
|
|||||||
|
package com.docus.server.archive.mapper;
|
||||||
|
|
||||||
|
|
||||||
|
import com.docus.server.archive.entity.TBasic;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Mapper
|
||||||
|
public interface TBasicMapper {
|
||||||
|
|
||||||
|
|
||||||
|
List<TBasic> getByDisDate(@Param("disDateStart") String disDateStart, @Param("disDateEnd") String disDateEnd, @Param("offset") int offset, @Param("size") int size);
|
||||||
|
}
|
@ -0,0 +1,23 @@
|
|||||||
|
package com.docus.server.archive.mapper;
|
||||||
|
|
||||||
|
import com.docus.server.archive.entity.TBasicZkInfo;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 转科信息
|
||||||
|
*
|
||||||
|
* @author YongBin Wen
|
||||||
|
* @date 2024/4/9 13:53
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface TBasicZkInfoMapper {
|
||||||
|
|
||||||
|
int deleteByPatientIds(@Param("patientIds") List<String> patientIds);
|
||||||
|
|
||||||
|
int saveBatch(@Param("zkInfos") List<TBasicZkInfo> zkInfos);
|
||||||
|
|
||||||
|
List<String> existsZkInfoPatientIds(@Param("patientIds") List<String> patientIds);
|
||||||
|
}
|
@ -0,0 +1,9 @@
|
|||||||
|
package com.docus.server.archive.service;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author YongBin Wen
|
||||||
|
* @date 2024/4/9 14:16
|
||||||
|
*/
|
||||||
|
public interface ZkInfoSyncService {
|
||||||
|
int syncZkInfo(String disDateStart, String disDateEnd, Integer pageNumber, Integer pageSize);
|
||||||
|
}
|
@ -0,0 +1,39 @@
|
|||||||
|
package com.docus.server.his.entity;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 嘉时无纸化转科信息视图
|
||||||
|
*
|
||||||
|
* @author YongBin Wen
|
||||||
|
* @date 2024/4/9 13:46
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class VJswzhZkxx {
|
||||||
|
/**
|
||||||
|
* 记账号
|
||||||
|
*/
|
||||||
|
private String jzh;
|
||||||
|
/**
|
||||||
|
* 转出病区编号
|
||||||
|
*/
|
||||||
|
private String zcbq;
|
||||||
|
/**
|
||||||
|
* 转出科室名称
|
||||||
|
*/
|
||||||
|
private String zcks;
|
||||||
|
/**
|
||||||
|
* 转出时间
|
||||||
|
*/
|
||||||
|
private Date zcrq;
|
||||||
|
/**
|
||||||
|
* 转入病区编号
|
||||||
|
*/
|
||||||
|
private String zrbq;
|
||||||
|
/**
|
||||||
|
* 转入科室名称
|
||||||
|
*/
|
||||||
|
private String zrks;
|
||||||
|
}
|
@ -0,0 +1,19 @@
|
|||||||
|
package com.docus.server.his.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||||
|
import com.docus.server.his.entity.VJswzhZkxx;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 嘉时无纸化转科信息视图
|
||||||
|
* @author YongBin Wen
|
||||||
|
* @date 2024/4/9 13:46
|
||||||
|
*/
|
||||||
|
@DS("his")
|
||||||
|
@Mapper
|
||||||
|
public interface VJswzhZkxxMapper {
|
||||||
|
List<VJswzhZkxx> getZkInfoByJzhs(@Param("jzhs") List<String> jzhs);
|
||||||
|
}
|
@ -0,0 +1,33 @@
|
|||||||
|
@echo off
|
||||||
|
|
||||||
|
for /f "delims=" %%t in ('winsw.exe status') do set str=%%t
|
||||||
|
echo %str%
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if %str%==Started (
|
||||||
|
echo "restart....."
|
||||||
|
winsw stop
|
||||||
|
PING 127.0.0.1 -n 10 -w 30000 >NUL
|
||||||
|
winsw start
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if %str%==Stopped (
|
||||||
|
echo "start....."
|
||||||
|
winsw start
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
if %str%==NonExistent (
|
||||||
|
echo "deploy and start....."
|
||||||
|
winsw install
|
||||||
|
winsw start
|
||||||
|
echo c
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,21 @@
|
|||||||
|
set java_opts=-Xms512m -Xmx512m
|
||||||
|
set key="java_opts"
|
||||||
|
|
||||||
|
|
||||||
|
rem 文件不存在,就跳过
|
||||||
|
if not exist java-ops.ini goto end
|
||||||
|
|
||||||
|
for /f "tokens=1,2 delims==" %%i in (java-ops.ini) do (
|
||||||
|
if "%%i"==%key% set java_opts=%%j)
|
||||||
|
echo java_opts is : %java_opts%
|
||||||
|
|
||||||
|
:end
|
||||||
|
|
||||||
|
rem 启动java
|
||||||
|
|
||||||
|
java %java_opts% -Dfile.encoding=utf-8 -jar -Dspring.profiles.active=@profile.name@ -Dloader.path=config,lib @project.build.finalName@.jar
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -0,0 +1,13 @@
|
|||||||
|
@echo off
|
||||||
|
|
||||||
|
for /f "delims=" %%t in ('winsw.exe status') do set str=%%t
|
||||||
|
echo %str%
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
if %str%==Started (
|
||||||
|
winsw stop
|
||||||
|
@echo wait program stop .....
|
||||||
|
PING 127.0.0.1 -n 30 -w 10000 >NUL
|
||||||
|
)
|
||||||
|
|
@ -0,0 +1,19 @@
|
|||||||
|
@echo off
|
||||||
|
|
||||||
|
set deployDir=%1\docus-collect-nkzxyy
|
||||||
|
if %deployDir%=="" set deployDir=d:\webroot\docus-collect-nkzxyy
|
||||||
|
|
||||||
|
set curr_file=%cd%
|
||||||
|
cd /d %deployDir%
|
||||||
|
call stop.bat
|
||||||
|
cd %curr_file%
|
||||||
|
sc query docus-backup-sys |Find "RUNNING" && ping 127.0.0.1 -n 10 >nul
|
||||||
|
rd/s/q %deployDir%\lib
|
||||||
|
rd/s/q %deployDir%\dataConfig
|
||||||
|
rd/s/q %deployDir%\config
|
||||||
|
del /s/q %deployDir%\*.jar
|
||||||
|
xcopy /Y/E/I * %deployDir%
|
||||||
|
|
||||||
|
cd /d %deployDir%
|
||||||
|
call install.bat
|
||||||
|
|
@ -0,0 +1,8 @@
|
|||||||
|
<service>
|
||||||
|
<id>docus-collect-nkzxyy</id>
|
||||||
|
<name>生产-嘉时-佛山三院采集服务</name>
|
||||||
|
<description>生产-嘉时-佛山三院采集服务</description>
|
||||||
|
<startmode>Automatic</startmode>
|
||||||
|
<executable>%BASE%\start.bat</executable>
|
||||||
|
<log mode="none"></log>
|
||||||
|
</service>
|
@ -0,0 +1,2 @@
|
|||||||
|
# If you use SLF4J. First, you need to tell log4jdbc-log4j2 that you want to use the SLF4J logger
|
||||||
|
log4jdbc.spylogdelegator.name=net.sf.log4jdbc.log.slf4j.Slf4jSpyLogDelegator
|
@ -0,0 +1,12 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.docus.server.archive.mapper.TBasicMapper">
|
||||||
|
|
||||||
|
<select id="getByDisDate" resultType="com.docus.server.archive.entity.TBasic">
|
||||||
|
select patient_id,jzh from docus_medicalrecord.t_basic
|
||||||
|
where dis_date BETWEEN #{disDateStart} AND #{disDateEnd}
|
||||||
|
LIMIT ${offset},${size}
|
||||||
|
</select>
|
||||||
|
</mapper>
|
@ -0,0 +1,30 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
|
||||||
|
<mapper namespace="com.docus.server.archive.mapper.TBasicZkInfoMapper">
|
||||||
|
<insert id="saveBatch">
|
||||||
|
INSERT INTO `docus_medicalrecord`.`t_basic_zk_info`
|
||||||
|
(`id`, `patient_id`, `out_dept_code`, `out_dept_name`, `out_date`, `in_dept_code`, `in_dept_name`, `create_time`) VALUES
|
||||||
|
<foreach collection="zkInfos" item="zkInfo" separator=",">
|
||||||
|
(
|
||||||
|
#{zkInfo.id},#{zkInfo.patientId},#{zkInfo.outDeptCode},#{zkInfo.outDate},#{zkInfo.outDate},
|
||||||
|
#{zkInfo.inDeptCode},#{zkInfo.inDeptName},#{zkInfo.createTime}
|
||||||
|
)
|
||||||
|
</foreach>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<delete id="deleteByPatientIds">
|
||||||
|
delete from docus_medicalrecord.t_basic_zk_info
|
||||||
|
where patient_id in <foreach collection="patientIds" item="patientId" separator="," open="(" close=")">
|
||||||
|
#{patientId}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
<select id="existsZkInfoPatientIds" resultType="java.lang.String">
|
||||||
|
select patient_id from docus_medicalrecord.t_basic_zk_info
|
||||||
|
where patient_id in <foreach collection="patientIds" item="patientId" separator="," open="(" close=")">
|
||||||
|
#{patientId}
|
||||||
|
</foreach>
|
||||||
|
</select>
|
||||||
|
</mapper>
|
@ -0,0 +1,15 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.docus.server.his.mapper.VJswzhZkxxMapper">
|
||||||
|
|
||||||
|
|
||||||
|
<select id="getZkInfoByJzhs" resultType="com.docus.server.his.entity.VJswzhZkxx">
|
||||||
|
SELECT jzh,zcbq,zcks,zcrq,zrbq,zrks
|
||||||
|
FROM V_JSWZH_ZKXX
|
||||||
|
where jzh in <foreach collection="jzhs" separator="," item="jzh" open="(" close=")">
|
||||||
|
#{jzh}
|
||||||
|
</foreach>
|
||||||
|
</select>
|
||||||
|
</mapper>
|
Loading…
Reference in New Issue