Browse Source

Merge branch 'master' into master-dev

# Conflicts:
#	ruisi_java/ruisi-cc-generator/src/main/resources/mbg.xml
#	ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/dto/RmsDto.java
#	ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/vo/RmsVo.java
#	ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/persist/dao/RmsDao.java
#	ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/service/IRmsService.java
#	ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/service/impl/RmsServiceImpl.java
#	ruisi_java/ruisi-web-admin/src/main/resources/mapper/dao/RmsDao.xml
#	ruisi_java/ruisi-web-client/src/main/resources/application-dev.yml
#	ruisi_java/ruisi-web-client/src/main/resources/application-prod.yml
master-admin
zhangye 2 weeks ago
parent
commit
e623eae2df
  1. 3
      ruisi_java/ruisi-cc-common/src/main/java/com/ccsens/common/constant/ErrorConstant.java
  2. 12
      ruisi_java/ruisi-cc-common/src/main/java/com/ccsens/common/constant/UserConstants.java
  3. 10
      ruisi_java/ruisi-cc-common/src/main/java/com/ccsens/common/core/domain/entity/SysDept.java
  4. 14
      ruisi_java/ruisi-cc-common/src/main/java/com/ccsens/common/core/domain/entity/SysUser.java
  5. 12
      ruisi_java/ruisi-cc-generator/src/main/resources/mbg.xml
  6. 298
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/dto/DockDto.java
  7. 25
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/dto/RmsDto.java
  8. 161
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DmsRunningLog.java
  9. 1011
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DmsRunningLogExample.java
  10. 117
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockDept.java
  11. 801
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockDeptExample.java
  12. 139
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockEmpl.java
  13. 941
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockEmplExample.java
  14. 326
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientBaseInfo.java
  15. 2138
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientBaseInfoExample.java
  16. 172
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientDiagnosis.java
  17. 1148
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientDiagnosisExample.java
  18. 162
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientMedicationInfo.java
  19. 1062
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientMedicationInfoExample.java
  20. 514
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientVisitInfo.java
  21. 3042
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientVisitInfoExample.java
  22. 11
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/PmsPatient.java
  23. 70
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/PmsPatientExample.java
  24. 33
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/vo/RmsVo.java
  25. 18
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/dao/DockDao.java
  26. 30
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DmsRunningLogMapper.java
  27. 30
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockDeptMapper.java
  28. 30
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockEmplMapper.java
  29. 30
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockPatientBaseInfoMapper.java
  30. 30
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockPatientDiagnosisMapper.java
  31. 30
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockPatientMedicationInfoMapper.java
  32. 30
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockPatientVisitInfoMapper.java
  33. 2
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/SysUserMapper.java
  34. 26
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/service/DmsDataValueService.java
  35. 35
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/service/DockService.java
  36. 63
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/service/impl/DmsDataValueServiceImpl.java
  37. 869
      ruisi_java/ruisi-system/src/main/java/com/ccsens/system/service/impl/DockServiceImpl.java
  38. 30
      ruisi_java/ruisi-system/src/main/resources/mapper/dao/DockDao.xml
  39. 338
      ruisi_java/ruisi-system/src/main/resources/mapper/system/DmsRunningLogMapper.xml
  40. 276
      ruisi_java/ruisi-system/src/main/resources/mapper/system/DockDeptMapper.xml
  41. 306
      ruisi_java/ruisi-system/src/main/resources/mapper/system/DockEmplMapper.xml
  42. 575
      ruisi_java/ruisi-system/src/main/resources/mapper/system/DockPatientBaseInfoMapper.xml
  43. 354
      ruisi_java/ruisi-system/src/main/resources/mapper/system/DockPatientDiagnosisMapper.xml
  44. 338
      ruisi_java/ruisi-system/src/main/resources/mapper/system/DockPatientMedicationInfoMapper.xml
  45. 845
      ruisi_java/ruisi-system/src/main/resources/mapper/system/DockPatientVisitInfoMapper.xml
  46. 25
      ruisi_java/ruisi-system/src/main/resources/mapper/system/PmsPatientMapper.xml
  47. 8
      ruisi_java/ruisi-system/src/main/resources/mapper/system/SysDeptMapper.xml
  48. 25
      ruisi_java/ruisi-system/src/main/resources/mapper/system/SysUserMapper.xml
  49. 21
      ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/controller/ReportPdfController.java
  50. 4
      ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/persist/dao/RmsDao.java
  51. 4
      ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/service/IRmsService.java
  52. 50
      ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/service/impl/RmsServiceImpl.java
  53. 2
      ruisi_java/ruisi-web-admin/src/main/resources/application-stage.yml
  54. 67
      ruisi_java/ruisi-web-admin/src/main/resources/mapper/dao/RmsDao.xml
  55. 57
      ruisi_java/ruisi-web-client/src/main/java/com/ccsens/client/controller/DockController.java
  56. 65
      ruisi_java/ruisi-web-client/src/main/java/com/ccsens/client/controller/scheduled/SyncHospitalData.java
  57. 24
      ruisi_java/ruisi-web-client/src/main/resources/application-prod.yml
  58. 209
      sql/数据对接.sql

3
ruisi_java/ruisi-cc-common/src/main/java/com/ccsens/common/constant/ErrorConstant.java

@ -128,7 +128,10 @@ public enum ErrorConstant implements BaseEnum {
KEY_RE(50016, "KEY重复"), KEY_RE(50016, "KEY重复"),
EXPORT_SCALE_IS_NULL(50017, "请选择要导出的量表类型"), EXPORT_SCALE_IS_NULL(50017, "请选择要导出的量表类型"),
EXPORT_REPORT_IS_NULL(50018, "没有可以导出的报告单"), EXPORT_REPORT_IS_NULL(50018, "没有可以导出的报告单"),
DCS_RUNNING_ERROR(50019, "数据治理服务正在运行中"),
DateRangeError (50020, "日期范围错误"),
DcsLogError (50021, "lastSyncId和lastMakeupDate不应该为null"),
; ;
private Integer code; private Integer code;

12
ruisi_java/ruisi-cc-common/src/main/java/com/ccsens/common/constant/UserConstants.java

@ -247,4 +247,16 @@ public class UserConstants {
private String key; private String key;
private String desc; private String desc;
} }
@Getter
@AllArgsConstructor
public enum DcsRunningStatus implements BaseEnum {
Processing(0, "进行中", ""), Success(1, "成功", ""), Failed(2, "失败", ""),
;
private Integer code;
private String desc;
private String key;
}
} }

10
ruisi_java/ruisi-cc-common/src/main/java/com/ccsens/common/core/domain/entity/SysDept.java

@ -74,6 +74,8 @@ public class SysDept extends BaseEntity {
*/ */
private String parentName; private String parentName;
private String deptCode;
/** /**
* 子部门 * 子部门
*/ */
@ -181,6 +183,14 @@ public class SysDept extends BaseEntity {
this.children = children; this.children = children;
} }
public String getDeptCode() {
return deptCode;
}
public void setDeptCode(String deptCode) {
this.deptCode = deptCode;
}
@Override @Override
public String toString() { public String toString() {
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)

14
ruisi_java/ruisi-cc-common/src/main/java/com/ccsens/common/core/domain/entity/SysUser.java

@ -68,6 +68,12 @@ public class SysUser extends BaseEntity {
@ExcelTable(name = "登录名称") @ExcelTable(name = "登录名称")
private String userName; private String userName;
/**
* 工号
*/
@ExcelTable(name = "工号")
private String emplCode;
/** /**
* 用户昵称 * 用户昵称
*/ */
@ -296,6 +302,14 @@ public class SysUser extends BaseEntity {
this.userName = userName; this.userName = userName;
} }
public String getEmplCode() {
return emplCode;
}
public void setEmplCode(String emplCode) {
this.emplCode = emplCode;
}
@Email(message = "邮箱格式不正确") @Email(message = "邮箱格式不正确")
@Size(min = 0, max = 50, message = "邮箱长度不能超过50个字符") @Size(min = 0, max = 50, message = "邮箱长度不能超过50个字符")
public String getEmail() { public String getEmail() {

12
ruisi_java/ruisi-cc-generator/src/main/resources/mbg.xml

@ -64,13 +64,19 @@
<!-- <table tableName="ld_patient_record" domainObjectName="LdPatientRecord"/>--> <!-- <table tableName="ld_patient_record" domainObjectName="LdPatientRecord"/>-->
<!-- <table tableName="pms_patient_record" domainObjectName="PmsPatientRecord"/>--> <!-- <table tableName="pms_patient_record" domainObjectName="PmsPatientRecord"/>-->
<!-- <table tableName="pms_patient_acp" domainObjectName="PmsPatientAcp"/>--> <!-- <table tableName="pms_patient_acp" domainObjectName="PmsPatientAcp"/>-->
<!-- <table tableName="pms_patient_body" domainObjectName="PmsPatientBody"/>--> <table tableName="pms_patient_body" domainObjectName="PmsPatientBody"/>
<!-- <table tableName="pms_patient_family_illness" domainObjectName="PmsPatientFamilyIllness"/>--> <!-- <table tableName="pms_patient_family_illness" domainObjectName="PmsPatientFamilyIllness"/>-->
<!-- <table tableName="pms_patient_illness_history" domainObjectName="PmsPatientIllnessHistory"/>--> <!-- <table tableName="pms_patient_illness_history" domainObjectName="PmsPatientIllnessHistory"/>-->
<!-- <table tableName="pms_patient_parent_illness" domainObjectName="PmsPatientParentIllness"/>--> <!-- <table tableName="pms_patient_parent_illness" domainObjectName="PmsPatientParentIllness"/>-->
<!-- <table tableName="pms_patient_personal" domainObjectName="PmsPatientPersonal"/>--> <!-- <table tableName="pms_patient_personal" domainObjectName="PmsPatientPersonal"/>-->
<!-- <table tableName="pms_patient_diagnosis" domainObjectName="PmsPatientDiagnosis"/>--> <!-- <table tableName="pms_patient_diagnosis" domainObjectName="PmsPatientDiagnosis"/>-->
<!-- <table tableName="ems_evaluation_scale_cognitive_relevance" domainObjectName="EmsEvaluationScaleCognitiveRelevance"/>--> <table tableName="dock_patient_base_info" domainObjectName="DockPatientBaseInfo"/>
<table tableName="dock_patient_diagnosis" domainObjectName="DockPatientDiagnosis"/>
<table tableName="dock_patient_medication_info" domainObjectName="DockPatientMedicationInfo"/>
<table tableName="dock_patient_visit_info" domainObjectName="DockPatientVisitInfo"/>
<table tableName="dock_empl" domainObjectName="DockEmpl"/>
<table tableName="dock_dept" domainObjectName="DockDept"/>
<!-- <table tableName="dms_running_log" domainObjectName="DmsRunningLog"/>-->
<!-- <table tableName="hms_combo" domainObjectName="HmsCombo"/>--> <!-- <table tableName="hms_combo" domainObjectName="HmsCombo"/>-->
<!-- <table tableName="hms_combo_scale_relevance" domainObjectName="HmsComboScaleRelevance"/>--> <!-- <table tableName="hms_combo_scale_relevance" domainObjectName="HmsComboScaleRelevance"/>-->
<!-- <table tableName="hms_doctor" domainObjectName="HmsDoctor"/>--> <!-- <table tableName="hms_doctor" domainObjectName="HmsDoctor"/>-->
@ -115,7 +121,7 @@
<!-- <table tableName="ams_patient_question_record" domainObjectName="AmsPatientQuestionRecord"/>--> <!-- <table tableName="ams_patient_question_record" domainObjectName="AmsPatientQuestionRecord"/>-->
<!-- <table tableName="ams_patient_question_record_desc" domainObjectName="AmsPatientQuestionRecordDesc"/>--> <!-- <table tableName="ams_patient_question_record_desc" domainObjectName="AmsPatientQuestionRecordDesc"/>-->
<table tableName="rms_report" domainObjectName="RmsReport"/> <!-- <table tableName="rms_report" domainObjectName="RmsReport"/>-->
<!-- <table tableName="rms_report_basics_record" domainObjectName="RmsReportBasicsRecord"/>--> <!-- <table tableName="rms_report_basics_record" domainObjectName="RmsReportBasicsRecord"/>-->
<!-- <table tableName="rms_report_range" domainObjectName="RmsReportRange"/>--> <!-- <table tableName="rms_report_range" domainObjectName="RmsReportRange"/>-->
<!-- <table tableName="rms_report_scale_score" domainObjectName="RmsReportScaleScore"/>--> <!-- <table tableName="rms_report_scale_score" domainObjectName="RmsReportScaleScore"/>-->

298
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/dto/DockDto.java

@ -0,0 +1,298 @@
package com.ccsens.system.domain.dto;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.date.DateUtil;
import cn.hutool.core.util.StrUtil;
import com.ccsens.system.domain.po.DockEmpl;
import com.ccsens.system.domain.po.DockPatientBaseInfo;
import com.ccsens.system.domain.po.DockPatientVisitInfo;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;
/**
* @Author zzc
* @Package com.ccsens.system.domain.dto
* @Date 2026/2/9 11:00
* @description:
*/
public class DockDto {
@Data
public static class AddPatientDto {
@ApiModelProperty("患者信息")
private PatientInfo basicInfo;
@ApiModelProperty("就诊信息")
private Jiuzhen visitInfo;
}
@Data
public static class PatientInfo {
@ApiModelProperty("主键")
private Long id;
@ApiModelProperty("姓名")
private String name;
@NotNull(message = "证件号码不能为空")
@ApiModelProperty("证件号码")
private String idCard;
@ApiModelProperty("联系电话")
private String phone;
@ApiModelProperty("性别")
private String sex;
@ApiModelProperty("出生日期")
private String birthday;
@ApiModelProperty("受教育程度 0文盲、1小学、2初中、3高中/技校/中专、4大学/专科及以上")
private String educationalStatus;
@ApiModelProperty("职业类型 1:农林牧渔水利生产人员 2:教师 3:医务工作者 4:专业技术人员 5:生产、运输设备操作人员及有关人员6:商业、服务业人员7:国家机关、事业单位、企业负责人8:国家机关、事业单位、企业办事人员和有关人员9:军人 10:媒体、文体类工作人员 11:在校学生 12:未就业 13:家务 14:其他")
private String career;
@ApiModelProperty("婚姻状况 0已婚、1未婚、2离婚、3丧偶、4未知")
private String maritalStatus;
@ApiModelProperty("民族")
private String nation;
@ApiModelProperty("籍贯")
private String nativePlace;
@ApiModelProperty("现住址")
private String address;
@ApiModelProperty("居住状态 0独居、1夫妻同住、2多代加入同住、3养老院、4其他")
private String dwellingState;
@ApiModelProperty("联系人姓名")
private String contactName;
@ApiModelProperty("联系人电话")
private String contactMobile;
@ApiModelProperty("与联系人关系")
private String contactRelation;
@ApiModelProperty("ABO血型")
private String aboBloodType;
@ApiModelProperty("Rh血型")
private String rhBloodType;
@ApiModelProperty("信仰")
private String belief;
@ApiModelProperty("爱好")
private String hobby;
public static DockPatientBaseInfo toPatientInfo(PatientInfo patientInfo) {
DockPatientBaseInfo info = new DockPatientBaseInfo();
info.setId(patientInfo.getId());
info.setName(patientInfo.getName());
info.setIdCard(patientInfo.getIdCard());
info.setPhone(patientInfo.getPhone());
info.setSex(patientInfo.getSex());
info.setBirthday(DateUtil.parse(patientInfo.getBirthday(), "yyyy-MM-dd"));
info.setEducationalStatus(patientInfo.getEducationalStatus());
info.setCareer(patientInfo.getCareer());
info.setMaritalStatus(patientInfo.getMaritalStatus());
info.setNation(patientInfo.getNation());
info.setNativePlace(patientInfo.getNativePlace());
info.setAddress(patientInfo.getAddress());
info.setDwellingState(patientInfo.getDwellingState());
info.setContactName(patientInfo.getContactName());
info.setContactMobile(patientInfo.getContactMobile());
info.setContactRelation(patientInfo.getContactRelation());
info.setAboBloodType(patientInfo.getAboBloodType());
info.setRhBloodType(patientInfo.getRhBloodType());
info.setBelief(patientInfo.getBelief());
info.setHobby(patientInfo.getHobby());
return info;
}
}
@Data
public static class Jiuzhen {
@ApiModelProperty("")
private String id;
@ApiModelProperty("证件号码")
private String idCard;
@ApiModelProperty("就诊类型")
private String visitType;
@ApiModelProperty("就诊流水号")
private String visitNo;
@ApiModelProperty("年龄")
private String age;
@ApiModelProperty("就诊/住院科室")
private String department;
@ApiModelProperty("就诊/主治医师")
private String doctor;
@ApiModelProperty("就诊/入院日期")
private String admissionDate;
@ApiModelProperty("住院次数")
private String admissionCount;
@ApiModelProperty("床位号")
private String bedNumber;
@ApiModelProperty("出院日期")
private String dischargeDate;
@ApiModelProperty("入院途径")
private String admissionMethod;
@ApiModelProperty("离院方式")
private String dischargeMethod;
@ApiModelProperty("身高")
private String height;
@ApiModelProperty("体重")
private String weight;
@ApiModelProperty("T值")
private String tz;
@ApiModelProperty("体温")
private String temperature;
@ApiModelProperty("收缩压")
private String bloodPressureShrink;
@ApiModelProperty("舒张压")
private String bloodPressureDiastole;
@ApiModelProperty("脉搏")
private String pulse;
@ApiModelProperty("肌酐")
private String creatinine;
@ApiModelProperty("血氧饱和度")
private String oxygenSaturation;
@ApiModelProperty("白蛋白")
private String albumin;
@ApiModelProperty("总蛋白")
private String totalProtein;
@ApiModelProperty("维生素D3测定")
private String vitaminD3;
@ApiModelProperty("凝血酶原时间")
private String hematocrit;
@ApiModelProperty("D-二聚体")
private String dimer;
@ApiModelProperty("是否吸烟")
private String smokingHistory;
@ApiModelProperty("吸烟年限")
private String smokingYear;
@ApiModelProperty("是否戒烟")
private String smokingQuit;
@ApiModelProperty("戒烟年限")
private String smokingQuitYear;
@ApiModelProperty("是否饮酒")
private String drinkHistory;
@ApiModelProperty("饮酒年限")
private String drinkYear;
@ApiModelProperty("是否戒酒")
private String drinkQuit;
@ApiModelProperty("戒酒年限")
private String drinkQuitYear;
@ApiModelProperty("是否过敏")
private String hasAllergy;
@ApiModelProperty("过敏药")
private String allergyDrug;
@ApiModelProperty("诊断信息")
private List<Zhenduan> diagnosis;
@ApiModelProperty("用药信息")
private List<Yongyao> medications;
public List<Zhenduan> getDiagnosis() {
if (CollUtil.isNotEmpty(diagnosis)) {
diagnosis.forEach(z -> {
z.setVisitNo(visitNo);
});
}
return diagnosis;
}
public List<Yongyao> getMedications() {
if (CollUtil.isNotEmpty(medications)) {
medications.forEach(z -> {
z.setVisitNo(visitNo);
});
}
return medications;
}
public static DockPatientVisitInfo toJiuzhen(Jiuzhen jiuzhen) {
DockPatientVisitInfo dockPatientVisitInfo = new DockPatientVisitInfo();
dockPatientVisitInfo.setIdCard(jiuzhen.getIdCard());
dockPatientVisitInfo.setVisitType(jiuzhen.getVisitType());
dockPatientVisitInfo.setVisitNo(jiuzhen.getVisitNo());
dockPatientVisitInfo.setAge(Integer.parseInt(jiuzhen.getAge()));
dockPatientVisitInfo.setDepartment(jiuzhen.getDepartment());
dockPatientVisitInfo.setDoctor(jiuzhen.getDoctor());
dockPatientVisitInfo.setAdmissionDate(DateUtil.parse(jiuzhen.getAdmissionDate()));
dockPatientVisitInfo.setAdmissionCount(Integer.parseInt(jiuzhen.getAdmissionCount()));
dockPatientVisitInfo.setBedNumber(jiuzhen.getBedNumber());
dockPatientVisitInfo.setDischargeDate(DateUtil.parse(jiuzhen.getDischargeDate()));
dockPatientVisitInfo.setAdmissionMethod(jiuzhen.getAdmissionMethod());
dockPatientVisitInfo.setDischargeMethod(jiuzhen.getDischargeMethod());
dockPatientVisitInfo.setHeight(new BigDecimal(jiuzhen.getHeight()));
dockPatientVisitInfo.setWeight(new BigDecimal(jiuzhen.getWeight()));
dockPatientVisitInfo.setTz(new BigDecimal(jiuzhen.getTz()));
dockPatientVisitInfo.setTemperature(new BigDecimal(jiuzhen.getTemperature()));
dockPatientVisitInfo.setBloodPressureShrink(Integer.parseInt(jiuzhen.getBloodPressureShrink()));
dockPatientVisitInfo.setBloodPressureDiastole(Integer.parseInt(jiuzhen.getBloodPressureDiastole()));
dockPatientVisitInfo.setPulse(Integer.parseInt(jiuzhen.getPulse()));
dockPatientVisitInfo.setCreatinine(new BigDecimal(jiuzhen.getCreatinine()));
dockPatientVisitInfo.setOxygenSaturation(new BigDecimal(jiuzhen.getOxygenSaturation()));
dockPatientVisitInfo.setAlbumin(new BigDecimal(jiuzhen.getAlbumin()));
dockPatientVisitInfo.setTotalProtein(new BigDecimal(jiuzhen.getTotalProtein()));
dockPatientVisitInfo.setVitaminD3(new BigDecimal(jiuzhen.getVitaminD3()));
dockPatientVisitInfo.setHematocrit(new BigDecimal(jiuzhen.getHematocrit()));
dockPatientVisitInfo.setDimer(new BigDecimal(jiuzhen.getDimer()));
dockPatientVisitInfo.setSmokingHistory(Byte.parseByte(jiuzhen.getSmokingHistory()));
dockPatientVisitInfo.setSmokingYear(Integer.parseInt(jiuzhen.getSmokingYear()));
dockPatientVisitInfo.setSmokingQuit(Byte.parseByte(jiuzhen.getSmokingQuit()));
dockPatientVisitInfo.setSmokingQuitYear(Integer.parseInt(jiuzhen.getSmokingQuitYear()));
dockPatientVisitInfo.setDrinkHistory(Byte.parseByte(jiuzhen.getDrinkHistory()));
dockPatientVisitInfo.setDrinkYear(StrUtil.isNotEmpty(jiuzhen.getDrinkYear()) ? Integer.parseInt(jiuzhen.getDrinkYear()) : null);
dockPatientVisitInfo.setDrinkQuit(StrUtil.isNotEmpty(jiuzhen.getDrinkQuit()) ? Byte.parseByte(jiuzhen.getDrinkQuit()) : null);
dockPatientVisitInfo.setDrinkQuitYear(StrUtil.isNotEmpty(jiuzhen.getDrinkQuitYear()) ? Integer.parseInt(jiuzhen.getDrinkQuitYear()) : null);
dockPatientVisitInfo.setHasAllergy(StrUtil.isNotEmpty(jiuzhen.getHasAllergy()) ? Byte.parseByte(jiuzhen.getHasAllergy()) : null);
dockPatientVisitInfo.setAllergyDrug(StrUtil.isNotEmpty(jiuzhen.getAllergyDrug()) ? jiuzhen.getAllergyDrug() : null);
return dockPatientVisitInfo;
}
}
@Data
public static class Zhenduan {
private Long id;
@ApiModelProperty("门诊/住院号")
private String visitNo;
@ApiModelProperty("诊断类型")
private String diagnosisType;
@ApiModelProperty("是否主要诊断")
private String isMainDiagnosis;
@ApiModelProperty("诊断名称")
private String diagnosisName;
@ApiModelProperty("诊断编码")
private String diagnosisCode;
@ApiModelProperty("诊断日期")
private String diagnosisDate;
}
@Data
public static class Yongyao {
private Long id;
@ApiModelProperty("门诊/住院号")
private String visitNo;
@ApiModelProperty("药物名称")
private String drugName;
@ApiModelProperty("剂量")
private String dose;
@ApiModelProperty("单位")
private String unit;
@ApiModelProperty("频率")
private String frequency;
}
@Data
public static class DockDeptInfo {
@ApiModelProperty("编号")
private String deptCode;
@ApiModelProperty("姓名")
private String deptName;
}
@Data
public static class DockEmplInfo {
@ApiModelProperty("编号")
private String emplCode;
@ApiModelProperty("姓名")
private String emplName;
@ApiModelProperty("医生/护士")
private String emplType;
@ApiModelProperty("部门编号")
private String deptCode;
}
}

25
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/dto/RmsDto.java

@ -17,7 +17,7 @@ public class RmsDto {
@ApiModel("PatientReportDtoGenerate") @ApiModel("PatientReportDtoGenerate")
@Data @Data
public static class Generate { public static class Generate{
@ApiModelProperty("病人ID") @ApiModelProperty("病人ID")
@NotNull(message = "病人ID不能为空") @NotNull(message = "病人ID不能为空")
private Long patientId; private Long patientId;
@ -31,7 +31,7 @@ public class RmsDto {
@ApiModel("PatientReportDtoQueryDetail") @ApiModel("PatientReportDtoQueryDetail")
@Data @Data
public static class QueryDetail { public static class QueryDetail{
@NotNull(message = "测评ID不能为空") @NotNull(message = "测评ID不能为空")
@ApiModelProperty("测评ID") @ApiModelProperty("测评ID")
private Long evaluationId; private Long evaluationId;
@ -261,11 +261,24 @@ public class RmsDto {
@ApiModel("导出历史报告单-DTO") @ApiModel("导出历史报告单-DTO")
@Data @Data
public static class ReportPDF { public static class ReportPDF{
@ApiModelProperty("患者的就诊流水号") @ApiModelProperty("患者唯一标识")
private String patientNo; private String patientNo;
@ApiModelProperty("医护人员工号") @ApiModelProperty("就诊流水号")
private String emplCode; private String visitNo;
}
@ApiModel("导出历史报告单(查看详细的报告单文件)-DTO")
@Data
public static class queryPdfUrl{
@ApiModelProperty("报告单ID")
private Long reportId;
@ApiModelProperty("测评ID")
private Long evaluationId;
@ApiModelProperty("导出类型 0医生版 1个人版 2阳性版")
private String version;
@ApiModelProperty("评估医生id")
private Long assessorId;
} }
@Data @Data

161
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DmsRunningLog.java

@ -0,0 +1,161 @@
package com.ccsens.system.domain.po;
import java.io.Serializable;
import java.util.Date;
public class DmsRunningLog implements Serializable {
private Long id;
private Date startTime;
private Date endTime;
private Long syncRecords;
private Long syncSeconds;
private Date lastSyncDate;
private String remark;
private Byte status;
private Date createdAt;
private Date updatedAt;
private String createdBy;
private String updatedBy;
private Byte delStatus;
private static final long serialVersionUID = 1L;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public Date getStartTime() {
return startTime;
}
public void setStartTime(Date startTime) {
this.startTime = startTime;
}
public Date getEndTime() {
return endTime;
}
public void setEndTime(Date endTime) {
this.endTime = endTime;
}
public Long getSyncRecords() {
return syncRecords;
}
public void setSyncRecords(Long syncRecords) {
this.syncRecords = syncRecords;
}
public Long getSyncSeconds() {
return syncSeconds;
}
public void setSyncSeconds(Long syncSeconds) {
this.syncSeconds = syncSeconds;
}
public Date getLastSyncDate() {
return lastSyncDate;
}
public void setLastSyncDate(Date lastSyncDate) {
this.lastSyncDate = lastSyncDate;
}
public String getRemark() {
return remark;
}
public void setRemark(String remark) {
this.remark = remark == null ? null : remark.trim();
}
public Byte getStatus() {
return status;
}
public void setStatus(Byte status) {
this.status = status;
}
public Date getCreatedAt() {
return createdAt;
}
public void setCreatedAt(Date createdAt) {
this.createdAt = createdAt;
}
public Date getUpdatedAt() {
return updatedAt;
}
public void setUpdatedAt(Date updatedAt) {
this.updatedAt = updatedAt;
}
public String getCreatedBy() {
return createdBy;
}
public void setCreatedBy(String createdBy) {
this.createdBy = createdBy == null ? null : createdBy.trim();
}
public String getUpdatedBy() {
return updatedBy;
}
public void setUpdatedBy(String updatedBy) {
this.updatedBy = updatedBy == null ? null : updatedBy.trim();
}
public Byte getDelStatus() {
return delStatus;
}
public void setDelStatus(Byte delStatus) {
this.delStatus = delStatus;
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(getClass().getSimpleName());
sb.append(" [");
sb.append("Hash = ").append(hashCode());
sb.append(", id=").append(id);
sb.append(", startTime=").append(startTime);
sb.append(", endTime=").append(endTime);
sb.append(", syncRecords=").append(syncRecords);
sb.append(", syncSeconds=").append(syncSeconds);
sb.append(", lastSyncDate=").append(lastSyncDate);
sb.append(", remark=").append(remark);
sb.append(", status=").append(status);
sb.append(", createdAt=").append(createdAt);
sb.append(", updatedAt=").append(updatedAt);
sb.append(", createdBy=").append(createdBy);
sb.append(", updatedBy=").append(updatedBy);
sb.append(", delStatus=").append(delStatus);
sb.append("]");
return sb.toString();
}
}

1011
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DmsRunningLogExample.java

File diff suppressed because it is too large

117
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockDept.java

@ -0,0 +1,117 @@
package com.ccsens.system.domain.po;
import java.io.Serializable;
import java.util.Date;
public class DockDept implements Serializable {
private Long id;
private String deptName;
private String deptCode;
private String delFlag;
private String createBy;
private Date createTime;
private String updateBy;
private Date updateTime;
private String sync;
private static final long serialVersionUID = 1L;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getDeptName() {
return deptName;
}
public void setDeptName(String deptName) {
this.deptName = deptName == null ? null : deptName.trim();
}
public String getDeptCode() {
return deptCode;
}
public void setDeptCode(String deptCode) {
this.deptCode = deptCode == null ? null : deptCode.trim();
}
public String getDelFlag() {
return delFlag;
}
public void setDelFlag(String delFlag) {
this.delFlag = delFlag == null ? null : delFlag.trim();
}
public String getCreateBy() {
return createBy;
}
public void setCreateBy(String createBy) {
this.createBy = createBy == null ? null : createBy.trim();
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public String getUpdateBy() {
return updateBy;
}
public void setUpdateBy(String updateBy) {
this.updateBy = updateBy == null ? null : updateBy.trim();
}
public Date getUpdateTime() {
return updateTime;
}
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
public String getSync() {
return sync;
}
public void setSync(String sync) {
this.sync = sync == null ? null : sync.trim();
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(getClass().getSimpleName());
sb.append(" [");
sb.append("Hash = ").append(hashCode());
sb.append(", id=").append(id);
sb.append(", deptName=").append(deptName);
sb.append(", deptCode=").append(deptCode);
sb.append(", delFlag=").append(delFlag);
sb.append(", createBy=").append(createBy);
sb.append(", createTime=").append(createTime);
sb.append(", updateBy=").append(updateBy);
sb.append(", updateTime=").append(updateTime);
sb.append(", sync=").append(sync);
sb.append("]");
return sb.toString();
}
}

801
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockDeptExample.java

@ -0,0 +1,801 @@
package com.ccsens.system.domain.po;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
public class DockDeptExample {
protected String orderByClause;
protected boolean distinct;
protected List<Criteria> oredCriteria;
public DockDeptExample() {
oredCriteria = new ArrayList<Criteria>();
}
public void setOrderByClause(String orderByClause) {
this.orderByClause = orderByClause;
}
public String getOrderByClause() {
return orderByClause;
}
public void setDistinct(boolean distinct) {
this.distinct = distinct;
}
public boolean isDistinct() {
return distinct;
}
public List<Criteria> getOredCriteria() {
return oredCriteria;
}
public void or(Criteria criteria) {
oredCriteria.add(criteria);
}
public Criteria or() {
Criteria criteria = createCriteriaInternal();
oredCriteria.add(criteria);
return criteria;
}
public Criteria createCriteria() {
Criteria criteria = createCriteriaInternal();
if (oredCriteria.size() == 0) {
oredCriteria.add(criteria);
}
return criteria;
}
protected Criteria createCriteriaInternal() {
Criteria criteria = new Criteria();
return criteria;
}
public void clear() {
oredCriteria.clear();
orderByClause = null;
distinct = false;
}
protected abstract static class GeneratedCriteria {
protected List<Criterion> criteria;
protected GeneratedCriteria() {
super();
criteria = new ArrayList<Criterion>();
}
public boolean isValid() {
return criteria.size() > 0;
}
public List<Criterion> getAllCriteria() {
return criteria;
}
public List<Criterion> getCriteria() {
return criteria;
}
protected void addCriterion(String condition) {
if (condition == null) {
throw new RuntimeException("Value for condition cannot be null");
}
criteria.add(new Criterion(condition));
}
protected void addCriterion(String condition, Object value, String property) {
if (value == null) {
throw new RuntimeException("Value for " + property + " cannot be null");
}
criteria.add(new Criterion(condition, value));
}
protected void addCriterion(String condition, Object value1, Object value2, String property) {
if (value1 == null || value2 == null) {
throw new RuntimeException("Between values for " + property + " cannot be null");
}
criteria.add(new Criterion(condition, value1, value2));
}
public Criteria andIdIsNull() {
addCriterion("id is null");
return (Criteria) this;
}
public Criteria andIdIsNotNull() {
addCriterion("id is not null");
return (Criteria) this;
}
public Criteria andIdEqualTo(Long value) {
addCriterion("id =", value, "id");
return (Criteria) this;
}
public Criteria andIdNotEqualTo(Long value) {
addCriterion("id <>", value, "id");
return (Criteria) this;
}
public Criteria andIdGreaterThan(Long value) {
addCriterion("id >", value, "id");
return (Criteria) this;
}
public Criteria andIdGreaterThanOrEqualTo(Long value) {
addCriterion("id >=", value, "id");
return (Criteria) this;
}
public Criteria andIdLessThan(Long value) {
addCriterion("id <", value, "id");
return (Criteria) this;
}
public Criteria andIdLessThanOrEqualTo(Long value) {
addCriterion("id <=", value, "id");
return (Criteria) this;
}
public Criteria andIdIn(List<Long> values) {
addCriterion("id in", values, "id");
return (Criteria) this;
}
public Criteria andIdNotIn(List<Long> values) {
addCriterion("id not in", values, "id");
return (Criteria) this;
}
public Criteria andIdBetween(Long value1, Long value2) {
addCriterion("id between", value1, value2, "id");
return (Criteria) this;
}
public Criteria andIdNotBetween(Long value1, Long value2) {
addCriterion("id not between", value1, value2, "id");
return (Criteria) this;
}
public Criteria andDeptNameIsNull() {
addCriterion("dept_name is null");
return (Criteria) this;
}
public Criteria andDeptNameIsNotNull() {
addCriterion("dept_name is not null");
return (Criteria) this;
}
public Criteria andDeptNameEqualTo(String value) {
addCriterion("dept_name =", value, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameNotEqualTo(String value) {
addCriterion("dept_name <>", value, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameGreaterThan(String value) {
addCriterion("dept_name >", value, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameGreaterThanOrEqualTo(String value) {
addCriterion("dept_name >=", value, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameLessThan(String value) {
addCriterion("dept_name <", value, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameLessThanOrEqualTo(String value) {
addCriterion("dept_name <=", value, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameLike(String value) {
addCriterion("dept_name like", value, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameNotLike(String value) {
addCriterion("dept_name not like", value, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameIn(List<String> values) {
addCriterion("dept_name in", values, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameNotIn(List<String> values) {
addCriterion("dept_name not in", values, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameBetween(String value1, String value2) {
addCriterion("dept_name between", value1, value2, "deptName");
return (Criteria) this;
}
public Criteria andDeptNameNotBetween(String value1, String value2) {
addCriterion("dept_name not between", value1, value2, "deptName");
return (Criteria) this;
}
public Criteria andDeptCodeIsNull() {
addCriterion("dept_code is null");
return (Criteria) this;
}
public Criteria andDeptCodeIsNotNull() {
addCriterion("dept_code is not null");
return (Criteria) this;
}
public Criteria andDeptCodeEqualTo(String value) {
addCriterion("dept_code =", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeNotEqualTo(String value) {
addCriterion("dept_code <>", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeGreaterThan(String value) {
addCriterion("dept_code >", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeGreaterThanOrEqualTo(String value) {
addCriterion("dept_code >=", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeLessThan(String value) {
addCriterion("dept_code <", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeLessThanOrEqualTo(String value) {
addCriterion("dept_code <=", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeLike(String value) {
addCriterion("dept_code like", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeNotLike(String value) {
addCriterion("dept_code not like", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeIn(List<String> values) {
addCriterion("dept_code in", values, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeNotIn(List<String> values) {
addCriterion("dept_code not in", values, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeBetween(String value1, String value2) {
addCriterion("dept_code between", value1, value2, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeNotBetween(String value1, String value2) {
addCriterion("dept_code not between", value1, value2, "deptCode");
return (Criteria) this;
}
public Criteria andDelFlagIsNull() {
addCriterion("del_flag is null");
return (Criteria) this;
}
public Criteria andDelFlagIsNotNull() {
addCriterion("del_flag is not null");
return (Criteria) this;
}
public Criteria andDelFlagEqualTo(String value) {
addCriterion("del_flag =", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagNotEqualTo(String value) {
addCriterion("del_flag <>", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagGreaterThan(String value) {
addCriterion("del_flag >", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagGreaterThanOrEqualTo(String value) {
addCriterion("del_flag >=", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagLessThan(String value) {
addCriterion("del_flag <", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagLessThanOrEqualTo(String value) {
addCriterion("del_flag <=", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagLike(String value) {
addCriterion("del_flag like", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagNotLike(String value) {
addCriterion("del_flag not like", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagIn(List<String> values) {
addCriterion("del_flag in", values, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagNotIn(List<String> values) {
addCriterion("del_flag not in", values, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagBetween(String value1, String value2) {
addCriterion("del_flag between", value1, value2, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagNotBetween(String value1, String value2) {
addCriterion("del_flag not between", value1, value2, "delFlag");
return (Criteria) this;
}
public Criteria andCreateByIsNull() {
addCriterion("create_by is null");
return (Criteria) this;
}
public Criteria andCreateByIsNotNull() {
addCriterion("create_by is not null");
return (Criteria) this;
}
public Criteria andCreateByEqualTo(String value) {
addCriterion("create_by =", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByNotEqualTo(String value) {
addCriterion("create_by <>", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByGreaterThan(String value) {
addCriterion("create_by >", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByGreaterThanOrEqualTo(String value) {
addCriterion("create_by >=", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByLessThan(String value) {
addCriterion("create_by <", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByLessThanOrEqualTo(String value) {
addCriterion("create_by <=", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByLike(String value) {
addCriterion("create_by like", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByNotLike(String value) {
addCriterion("create_by not like", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByIn(List<String> values) {
addCriterion("create_by in", values, "createBy");
return (Criteria) this;
}
public Criteria andCreateByNotIn(List<String> values) {
addCriterion("create_by not in", values, "createBy");
return (Criteria) this;
}
public Criteria andCreateByBetween(String value1, String value2) {
addCriterion("create_by between", value1, value2, "createBy");
return (Criteria) this;
}
public Criteria andCreateByNotBetween(String value1, String value2) {
addCriterion("create_by not between", value1, value2, "createBy");
return (Criteria) this;
}
public Criteria andCreateTimeIsNull() {
addCriterion("create_time is null");
return (Criteria) this;
}
public Criteria andCreateTimeIsNotNull() {
addCriterion("create_time is not null");
return (Criteria) this;
}
public Criteria andCreateTimeEqualTo(Date value) {
addCriterion("create_time =", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeNotEqualTo(Date value) {
addCriterion("create_time <>", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeGreaterThan(Date value) {
addCriterion("create_time >", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) {
addCriterion("create_time >=", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeLessThan(Date value) {
addCriterion("create_time <", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeLessThanOrEqualTo(Date value) {
addCriterion("create_time <=", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeIn(List<Date> values) {
addCriterion("create_time in", values, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeNotIn(List<Date> values) {
addCriterion("create_time not in", values, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeBetween(Date value1, Date value2) {
addCriterion("create_time between", value1, value2, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeNotBetween(Date value1, Date value2) {
addCriterion("create_time not between", value1, value2, "createTime");
return (Criteria) this;
}
public Criteria andUpdateByIsNull() {
addCriterion("update_by is null");
return (Criteria) this;
}
public Criteria andUpdateByIsNotNull() {
addCriterion("update_by is not null");
return (Criteria) this;
}
public Criteria andUpdateByEqualTo(String value) {
addCriterion("update_by =", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByNotEqualTo(String value) {
addCriterion("update_by <>", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByGreaterThan(String value) {
addCriterion("update_by >", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByGreaterThanOrEqualTo(String value) {
addCriterion("update_by >=", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByLessThan(String value) {
addCriterion("update_by <", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByLessThanOrEqualTo(String value) {
addCriterion("update_by <=", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByLike(String value) {
addCriterion("update_by like", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByNotLike(String value) {
addCriterion("update_by not like", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByIn(List<String> values) {
addCriterion("update_by in", values, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByNotIn(List<String> values) {
addCriterion("update_by not in", values, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByBetween(String value1, String value2) {
addCriterion("update_by between", value1, value2, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByNotBetween(String value1, String value2) {
addCriterion("update_by not between", value1, value2, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateTimeIsNull() {
addCriterion("update_time is null");
return (Criteria) this;
}
public Criteria andUpdateTimeIsNotNull() {
addCriterion("update_time is not null");
return (Criteria) this;
}
public Criteria andUpdateTimeEqualTo(Date value) {
addCriterion("update_time =", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeNotEqualTo(Date value) {
addCriterion("update_time <>", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeGreaterThan(Date value) {
addCriterion("update_time >", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) {
addCriterion("update_time >=", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeLessThan(Date value) {
addCriterion("update_time <", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeLessThanOrEqualTo(Date value) {
addCriterion("update_time <=", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeIn(List<Date> values) {
addCriterion("update_time in", values, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeNotIn(List<Date> values) {
addCriterion("update_time not in", values, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeBetween(Date value1, Date value2) {
addCriterion("update_time between", value1, value2, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeNotBetween(Date value1, Date value2) {
addCriterion("update_time not between", value1, value2, "updateTime");
return (Criteria) this;
}
public Criteria andSyncIsNull() {
addCriterion("sync is null");
return (Criteria) this;
}
public Criteria andSyncIsNotNull() {
addCriterion("sync is not null");
return (Criteria) this;
}
public Criteria andSyncEqualTo(String value) {
addCriterion("sync =", value, "sync");
return (Criteria) this;
}
public Criteria andSyncNotEqualTo(String value) {
addCriterion("sync <>", value, "sync");
return (Criteria) this;
}
public Criteria andSyncGreaterThan(String value) {
addCriterion("sync >", value, "sync");
return (Criteria) this;
}
public Criteria andSyncGreaterThanOrEqualTo(String value) {
addCriterion("sync >=", value, "sync");
return (Criteria) this;
}
public Criteria andSyncLessThan(String value) {
addCriterion("sync <", value, "sync");
return (Criteria) this;
}
public Criteria andSyncLessThanOrEqualTo(String value) {
addCriterion("sync <=", value, "sync");
return (Criteria) this;
}
public Criteria andSyncLike(String value) {
addCriterion("sync like", value, "sync");
return (Criteria) this;
}
public Criteria andSyncNotLike(String value) {
addCriterion("sync not like", value, "sync");
return (Criteria) this;
}
public Criteria andSyncIn(List<String> values) {
addCriterion("sync in", values, "sync");
return (Criteria) this;
}
public Criteria andSyncNotIn(List<String> values) {
addCriterion("sync not in", values, "sync");
return (Criteria) this;
}
public Criteria andSyncBetween(String value1, String value2) {
addCriterion("sync between", value1, value2, "sync");
return (Criteria) this;
}
public Criteria andSyncNotBetween(String value1, String value2) {
addCriterion("sync not between", value1, value2, "sync");
return (Criteria) this;
}
}
public static class Criteria extends GeneratedCriteria {
protected Criteria() {
super();
}
}
public static class Criterion {
private String condition;
private Object value;
private Object secondValue;
private boolean noValue;
private boolean singleValue;
private boolean betweenValue;
private boolean listValue;
private String typeHandler;
public String getCondition() {
return condition;
}
public Object getValue() {
return value;
}
public Object getSecondValue() {
return secondValue;
}
public boolean isNoValue() {
return noValue;
}
public boolean isSingleValue() {
return singleValue;
}
public boolean isBetweenValue() {
return betweenValue;
}
public boolean isListValue() {
return listValue;
}
public String getTypeHandler() {
return typeHandler;
}
protected Criterion(String condition) {
super();
this.condition = condition;
this.typeHandler = null;
this.noValue = true;
}
protected Criterion(String condition, Object value, String typeHandler) {
super();
this.condition = condition;
this.value = value;
this.typeHandler = typeHandler;
if (value instanceof List<?>) {
this.listValue = true;
} else {
this.singleValue = true;
}
}
protected Criterion(String condition, Object value) {
this(condition, value, null);
}
protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
super();
this.condition = condition;
this.value = value;
this.secondValue = secondValue;
this.typeHandler = typeHandler;
this.betweenValue = true;
}
protected Criterion(String condition, Object value, Object secondValue) {
this(condition, value, secondValue, null);
}
}
}

139
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockEmpl.java

@ -0,0 +1,139 @@
package com.ccsens.system.domain.po;
import java.io.Serializable;
import java.util.Date;
public class DockEmpl implements Serializable {
private Long id;
private String emplName;
private String emplCode;
private String emplType;
private String deptCode;
private String delFlag;
private String createBy;
private Date createTime;
private String updateBy;
private Date updateTime;
private String sync;
private static final long serialVersionUID = 1L;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getEmplName() {
return emplName;
}
public void setEmplName(String emplName) {
this.emplName = emplName == null ? null : emplName.trim();
}
public String getEmplCode() {
return emplCode;
}
public void setEmplCode(String emplCode) {
this.emplCode = emplCode == null ? null : emplCode.trim();
}
public String getEmplType() {
return emplType;
}
public void setEmplType(String emplType) {
this.emplType = emplType == null ? null : emplType.trim();
}
public String getDeptCode() {
return deptCode;
}
public void setDeptCode(String deptCode) {
this.deptCode = deptCode == null ? null : deptCode.trim();
}
public String getDelFlag() {
return delFlag;
}
public void setDelFlag(String delFlag) {
this.delFlag = delFlag == null ? null : delFlag.trim();
}
public String getCreateBy() {
return createBy;
}
public void setCreateBy(String createBy) {
this.createBy = createBy == null ? null : createBy.trim();
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public String getUpdateBy() {
return updateBy;
}
public void setUpdateBy(String updateBy) {
this.updateBy = updateBy == null ? null : updateBy.trim();
}
public Date getUpdateTime() {
return updateTime;
}
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
public String getSync() {
return sync;
}
public void setSync(String sync) {
this.sync = sync == null ? null : sync.trim();
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(getClass().getSimpleName());
sb.append(" [");
sb.append("Hash = ").append(hashCode());
sb.append(", id=").append(id);
sb.append(", emplName=").append(emplName);
sb.append(", emplCode=").append(emplCode);
sb.append(", emplType=").append(emplType);
sb.append(", deptCode=").append(deptCode);
sb.append(", delFlag=").append(delFlag);
sb.append(", createBy=").append(createBy);
sb.append(", createTime=").append(createTime);
sb.append(", updateBy=").append(updateBy);
sb.append(", updateTime=").append(updateTime);
sb.append(", sync=").append(sync);
sb.append("]");
return sb.toString();
}
}

941
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockEmplExample.java

@ -0,0 +1,941 @@
package com.ccsens.system.domain.po;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
public class DockEmplExample {
protected String orderByClause;
protected boolean distinct;
protected List<Criteria> oredCriteria;
public DockEmplExample() {
oredCriteria = new ArrayList<Criteria>();
}
public void setOrderByClause(String orderByClause) {
this.orderByClause = orderByClause;
}
public String getOrderByClause() {
return orderByClause;
}
public void setDistinct(boolean distinct) {
this.distinct = distinct;
}
public boolean isDistinct() {
return distinct;
}
public List<Criteria> getOredCriteria() {
return oredCriteria;
}
public void or(Criteria criteria) {
oredCriteria.add(criteria);
}
public Criteria or() {
Criteria criteria = createCriteriaInternal();
oredCriteria.add(criteria);
return criteria;
}
public Criteria createCriteria() {
Criteria criteria = createCriteriaInternal();
if (oredCriteria.size() == 0) {
oredCriteria.add(criteria);
}
return criteria;
}
protected Criteria createCriteriaInternal() {
Criteria criteria = new Criteria();
return criteria;
}
public void clear() {
oredCriteria.clear();
orderByClause = null;
distinct = false;
}
protected abstract static class GeneratedCriteria {
protected List<Criterion> criteria;
protected GeneratedCriteria() {
super();
criteria = new ArrayList<Criterion>();
}
public boolean isValid() {
return criteria.size() > 0;
}
public List<Criterion> getAllCriteria() {
return criteria;
}
public List<Criterion> getCriteria() {
return criteria;
}
protected void addCriterion(String condition) {
if (condition == null) {
throw new RuntimeException("Value for condition cannot be null");
}
criteria.add(new Criterion(condition));
}
protected void addCriterion(String condition, Object value, String property) {
if (value == null) {
throw new RuntimeException("Value for " + property + " cannot be null");
}
criteria.add(new Criterion(condition, value));
}
protected void addCriterion(String condition, Object value1, Object value2, String property) {
if (value1 == null || value2 == null) {
throw new RuntimeException("Between values for " + property + " cannot be null");
}
criteria.add(new Criterion(condition, value1, value2));
}
public Criteria andIdIsNull() {
addCriterion("id is null");
return (Criteria) this;
}
public Criteria andIdIsNotNull() {
addCriterion("id is not null");
return (Criteria) this;
}
public Criteria andIdEqualTo(Long value) {
addCriterion("id =", value, "id");
return (Criteria) this;
}
public Criteria andIdNotEqualTo(Long value) {
addCriterion("id <>", value, "id");
return (Criteria) this;
}
public Criteria andIdGreaterThan(Long value) {
addCriterion("id >", value, "id");
return (Criteria) this;
}
public Criteria andIdGreaterThanOrEqualTo(Long value) {
addCriterion("id >=", value, "id");
return (Criteria) this;
}
public Criteria andIdLessThan(Long value) {
addCriterion("id <", value, "id");
return (Criteria) this;
}
public Criteria andIdLessThanOrEqualTo(Long value) {
addCriterion("id <=", value, "id");
return (Criteria) this;
}
public Criteria andIdIn(List<Long> values) {
addCriterion("id in", values, "id");
return (Criteria) this;
}
public Criteria andIdNotIn(List<Long> values) {
addCriterion("id not in", values, "id");
return (Criteria) this;
}
public Criteria andIdBetween(Long value1, Long value2) {
addCriterion("id between", value1, value2, "id");
return (Criteria) this;
}
public Criteria andIdNotBetween(Long value1, Long value2) {
addCriterion("id not between", value1, value2, "id");
return (Criteria) this;
}
public Criteria andEmplNameIsNull() {
addCriterion("empl_name is null");
return (Criteria) this;
}
public Criteria andEmplNameIsNotNull() {
addCriterion("empl_name is not null");
return (Criteria) this;
}
public Criteria andEmplNameEqualTo(String value) {
addCriterion("empl_name =", value, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameNotEqualTo(String value) {
addCriterion("empl_name <>", value, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameGreaterThan(String value) {
addCriterion("empl_name >", value, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameGreaterThanOrEqualTo(String value) {
addCriterion("empl_name >=", value, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameLessThan(String value) {
addCriterion("empl_name <", value, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameLessThanOrEqualTo(String value) {
addCriterion("empl_name <=", value, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameLike(String value) {
addCriterion("empl_name like", value, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameNotLike(String value) {
addCriterion("empl_name not like", value, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameIn(List<String> values) {
addCriterion("empl_name in", values, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameNotIn(List<String> values) {
addCriterion("empl_name not in", values, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameBetween(String value1, String value2) {
addCriterion("empl_name between", value1, value2, "emplName");
return (Criteria) this;
}
public Criteria andEmplNameNotBetween(String value1, String value2) {
addCriterion("empl_name not between", value1, value2, "emplName");
return (Criteria) this;
}
public Criteria andEmplCodeIsNull() {
addCriterion("empl_code is null");
return (Criteria) this;
}
public Criteria andEmplCodeIsNotNull() {
addCriterion("empl_code is not null");
return (Criteria) this;
}
public Criteria andEmplCodeEqualTo(String value) {
addCriterion("empl_code =", value, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeNotEqualTo(String value) {
addCriterion("empl_code <>", value, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeGreaterThan(String value) {
addCriterion("empl_code >", value, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeGreaterThanOrEqualTo(String value) {
addCriterion("empl_code >=", value, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeLessThan(String value) {
addCriterion("empl_code <", value, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeLessThanOrEqualTo(String value) {
addCriterion("empl_code <=", value, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeLike(String value) {
addCriterion("empl_code like", value, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeNotLike(String value) {
addCriterion("empl_code not like", value, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeIn(List<String> values) {
addCriterion("empl_code in", values, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeNotIn(List<String> values) {
addCriterion("empl_code not in", values, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeBetween(String value1, String value2) {
addCriterion("empl_code between", value1, value2, "emplCode");
return (Criteria) this;
}
public Criteria andEmplCodeNotBetween(String value1, String value2) {
addCriterion("empl_code not between", value1, value2, "emplCode");
return (Criteria) this;
}
public Criteria andEmplTypeIsNull() {
addCriterion("empl_type is null");
return (Criteria) this;
}
public Criteria andEmplTypeIsNotNull() {
addCriterion("empl_type is not null");
return (Criteria) this;
}
public Criteria andEmplTypeEqualTo(String value) {
addCriterion("empl_type =", value, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeNotEqualTo(String value) {
addCriterion("empl_type <>", value, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeGreaterThan(String value) {
addCriterion("empl_type >", value, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeGreaterThanOrEqualTo(String value) {
addCriterion("empl_type >=", value, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeLessThan(String value) {
addCriterion("empl_type <", value, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeLessThanOrEqualTo(String value) {
addCriterion("empl_type <=", value, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeLike(String value) {
addCriterion("empl_type like", value, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeNotLike(String value) {
addCriterion("empl_type not like", value, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeIn(List<String> values) {
addCriterion("empl_type in", values, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeNotIn(List<String> values) {
addCriterion("empl_type not in", values, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeBetween(String value1, String value2) {
addCriterion("empl_type between", value1, value2, "emplType");
return (Criteria) this;
}
public Criteria andEmplTypeNotBetween(String value1, String value2) {
addCriterion("empl_type not between", value1, value2, "emplType");
return (Criteria) this;
}
public Criteria andDeptCodeIsNull() {
addCriterion("dept_code is null");
return (Criteria) this;
}
public Criteria andDeptCodeIsNotNull() {
addCriterion("dept_code is not null");
return (Criteria) this;
}
public Criteria andDeptCodeEqualTo(String value) {
addCriterion("dept_code =", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeNotEqualTo(String value) {
addCriterion("dept_code <>", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeGreaterThan(String value) {
addCriterion("dept_code >", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeGreaterThanOrEqualTo(String value) {
addCriterion("dept_code >=", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeLessThan(String value) {
addCriterion("dept_code <", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeLessThanOrEqualTo(String value) {
addCriterion("dept_code <=", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeLike(String value) {
addCriterion("dept_code like", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeNotLike(String value) {
addCriterion("dept_code not like", value, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeIn(List<String> values) {
addCriterion("dept_code in", values, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeNotIn(List<String> values) {
addCriterion("dept_code not in", values, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeBetween(String value1, String value2) {
addCriterion("dept_code between", value1, value2, "deptCode");
return (Criteria) this;
}
public Criteria andDeptCodeNotBetween(String value1, String value2) {
addCriterion("dept_code not between", value1, value2, "deptCode");
return (Criteria) this;
}
public Criteria andDelFlagIsNull() {
addCriterion("del_flag is null");
return (Criteria) this;
}
public Criteria andDelFlagIsNotNull() {
addCriterion("del_flag is not null");
return (Criteria) this;
}
public Criteria andDelFlagEqualTo(String value) {
addCriterion("del_flag =", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagNotEqualTo(String value) {
addCriterion("del_flag <>", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagGreaterThan(String value) {
addCriterion("del_flag >", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagGreaterThanOrEqualTo(String value) {
addCriterion("del_flag >=", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagLessThan(String value) {
addCriterion("del_flag <", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagLessThanOrEqualTo(String value) {
addCriterion("del_flag <=", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagLike(String value) {
addCriterion("del_flag like", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagNotLike(String value) {
addCriterion("del_flag not like", value, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagIn(List<String> values) {
addCriterion("del_flag in", values, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagNotIn(List<String> values) {
addCriterion("del_flag not in", values, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagBetween(String value1, String value2) {
addCriterion("del_flag between", value1, value2, "delFlag");
return (Criteria) this;
}
public Criteria andDelFlagNotBetween(String value1, String value2) {
addCriterion("del_flag not between", value1, value2, "delFlag");
return (Criteria) this;
}
public Criteria andCreateByIsNull() {
addCriterion("create_by is null");
return (Criteria) this;
}
public Criteria andCreateByIsNotNull() {
addCriterion("create_by is not null");
return (Criteria) this;
}
public Criteria andCreateByEqualTo(String value) {
addCriterion("create_by =", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByNotEqualTo(String value) {
addCriterion("create_by <>", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByGreaterThan(String value) {
addCriterion("create_by >", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByGreaterThanOrEqualTo(String value) {
addCriterion("create_by >=", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByLessThan(String value) {
addCriterion("create_by <", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByLessThanOrEqualTo(String value) {
addCriterion("create_by <=", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByLike(String value) {
addCriterion("create_by like", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByNotLike(String value) {
addCriterion("create_by not like", value, "createBy");
return (Criteria) this;
}
public Criteria andCreateByIn(List<String> values) {
addCriterion("create_by in", values, "createBy");
return (Criteria) this;
}
public Criteria andCreateByNotIn(List<String> values) {
addCriterion("create_by not in", values, "createBy");
return (Criteria) this;
}
public Criteria andCreateByBetween(String value1, String value2) {
addCriterion("create_by between", value1, value2, "createBy");
return (Criteria) this;
}
public Criteria andCreateByNotBetween(String value1, String value2) {
addCriterion("create_by not between", value1, value2, "createBy");
return (Criteria) this;
}
public Criteria andCreateTimeIsNull() {
addCriterion("create_time is null");
return (Criteria) this;
}
public Criteria andCreateTimeIsNotNull() {
addCriterion("create_time is not null");
return (Criteria) this;
}
public Criteria andCreateTimeEqualTo(Date value) {
addCriterion("create_time =", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeNotEqualTo(Date value) {
addCriterion("create_time <>", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeGreaterThan(Date value) {
addCriterion("create_time >", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) {
addCriterion("create_time >=", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeLessThan(Date value) {
addCriterion("create_time <", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeLessThanOrEqualTo(Date value) {
addCriterion("create_time <=", value, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeIn(List<Date> values) {
addCriterion("create_time in", values, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeNotIn(List<Date> values) {
addCriterion("create_time not in", values, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeBetween(Date value1, Date value2) {
addCriterion("create_time between", value1, value2, "createTime");
return (Criteria) this;
}
public Criteria andCreateTimeNotBetween(Date value1, Date value2) {
addCriterion("create_time not between", value1, value2, "createTime");
return (Criteria) this;
}
public Criteria andUpdateByIsNull() {
addCriterion("update_by is null");
return (Criteria) this;
}
public Criteria andUpdateByIsNotNull() {
addCriterion("update_by is not null");
return (Criteria) this;
}
public Criteria andUpdateByEqualTo(String value) {
addCriterion("update_by =", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByNotEqualTo(String value) {
addCriterion("update_by <>", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByGreaterThan(String value) {
addCriterion("update_by >", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByGreaterThanOrEqualTo(String value) {
addCriterion("update_by >=", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByLessThan(String value) {
addCriterion("update_by <", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByLessThanOrEqualTo(String value) {
addCriterion("update_by <=", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByLike(String value) {
addCriterion("update_by like", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByNotLike(String value) {
addCriterion("update_by not like", value, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByIn(List<String> values) {
addCriterion("update_by in", values, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByNotIn(List<String> values) {
addCriterion("update_by not in", values, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByBetween(String value1, String value2) {
addCriterion("update_by between", value1, value2, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateByNotBetween(String value1, String value2) {
addCriterion("update_by not between", value1, value2, "updateBy");
return (Criteria) this;
}
public Criteria andUpdateTimeIsNull() {
addCriterion("update_time is null");
return (Criteria) this;
}
public Criteria andUpdateTimeIsNotNull() {
addCriterion("update_time is not null");
return (Criteria) this;
}
public Criteria andUpdateTimeEqualTo(Date value) {
addCriterion("update_time =", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeNotEqualTo(Date value) {
addCriterion("update_time <>", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeGreaterThan(Date value) {
addCriterion("update_time >", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeGreaterThanOrEqualTo(Date value) {
addCriterion("update_time >=", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeLessThan(Date value) {
addCriterion("update_time <", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeLessThanOrEqualTo(Date value) {
addCriterion("update_time <=", value, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeIn(List<Date> values) {
addCriterion("update_time in", values, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeNotIn(List<Date> values) {
addCriterion("update_time not in", values, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeBetween(Date value1, Date value2) {
addCriterion("update_time between", value1, value2, "updateTime");
return (Criteria) this;
}
public Criteria andUpdateTimeNotBetween(Date value1, Date value2) {
addCriterion("update_time not between", value1, value2, "updateTime");
return (Criteria) this;
}
public Criteria andSyncIsNull() {
addCriterion("sync is null");
return (Criteria) this;
}
public Criteria andSyncIsNotNull() {
addCriterion("sync is not null");
return (Criteria) this;
}
public Criteria andSyncEqualTo(String value) {
addCriterion("sync =", value, "sync");
return (Criteria) this;
}
public Criteria andSyncNotEqualTo(String value) {
addCriterion("sync <>", value, "sync");
return (Criteria) this;
}
public Criteria andSyncGreaterThan(String value) {
addCriterion("sync >", value, "sync");
return (Criteria) this;
}
public Criteria andSyncGreaterThanOrEqualTo(String value) {
addCriterion("sync >=", value, "sync");
return (Criteria) this;
}
public Criteria andSyncLessThan(String value) {
addCriterion("sync <", value, "sync");
return (Criteria) this;
}
public Criteria andSyncLessThanOrEqualTo(String value) {
addCriterion("sync <=", value, "sync");
return (Criteria) this;
}
public Criteria andSyncLike(String value) {
addCriterion("sync like", value, "sync");
return (Criteria) this;
}
public Criteria andSyncNotLike(String value) {
addCriterion("sync not like", value, "sync");
return (Criteria) this;
}
public Criteria andSyncIn(List<String> values) {
addCriterion("sync in", values, "sync");
return (Criteria) this;
}
public Criteria andSyncNotIn(List<String> values) {
addCriterion("sync not in", values, "sync");
return (Criteria) this;
}
public Criteria andSyncBetween(String value1, String value2) {
addCriterion("sync between", value1, value2, "sync");
return (Criteria) this;
}
public Criteria andSyncNotBetween(String value1, String value2) {
addCriterion("sync not between", value1, value2, "sync");
return (Criteria) this;
}
}
public static class Criteria extends GeneratedCriteria {
protected Criteria() {
super();
}
}
public static class Criterion {
private String condition;
private Object value;
private Object secondValue;
private boolean noValue;
private boolean singleValue;
private boolean betweenValue;
private boolean listValue;
private String typeHandler;
public String getCondition() {
return condition;
}
public Object getValue() {
return value;
}
public Object getSecondValue() {
return secondValue;
}
public boolean isNoValue() {
return noValue;
}
public boolean isSingleValue() {
return singleValue;
}
public boolean isBetweenValue() {
return betweenValue;
}
public boolean isListValue() {
return listValue;
}
public String getTypeHandler() {
return typeHandler;
}
protected Criterion(String condition) {
super();
this.condition = condition;
this.typeHandler = null;
this.noValue = true;
}
protected Criterion(String condition, Object value, String typeHandler) {
super();
this.condition = condition;
this.value = value;
this.typeHandler = typeHandler;
if (value instanceof List<?>) {
this.listValue = true;
} else {
this.singleValue = true;
}
}
protected Criterion(String condition, Object value) {
this(condition, value, null);
}
protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
super();
this.condition = condition;
this.value = value;
this.secondValue = secondValue;
this.typeHandler = typeHandler;
this.betweenValue = true;
}
protected Criterion(String condition, Object value, Object secondValue) {
this(condition, value, secondValue, null);
}
}
}

326
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientBaseInfo.java

@ -0,0 +1,326 @@
package com.ccsens.system.domain.po;
import java.io.Serializable;
import java.util.Date;
public class DockPatientBaseInfo implements Serializable {
private Long id;
private String name;
private String patientNo;
private String idCard;
private String phone;
private String sex;
private Date birthday;
private String educationalStatus;
private String career;
private String maritalStatus;
private String nation;
private String nativePlace;
private String address;
private String dwellingState;
private String contactName;
private String contactMobile;
private String contactRelation;
private String aboBloodType;
private String rhBloodType;
private String belief;
private String hobby;
private String createBy;
private Date createTime;
private String updateBy;
private Date updateTime;
private Byte delFlag;
private String remark;
private String sync;
private static final long serialVersionUID = 1L;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name == null ? null : name.trim();
}
public String getPatientNo() {
return patientNo;
}
public void setPatientNo(String patientNo) {
this.patientNo = patientNo == null ? null : patientNo.trim();
}
public String getIdCard() {
return idCard;
}
public void setIdCard(String idCard) {
this.idCard = idCard == null ? null : idCard.trim();
}
public String getPhone() {
return phone;
}
public void setPhone(String phone) {
this.phone = phone == null ? null : phone.trim();
}
public String getSex() {
return sex;
}
public void setSex(String sex) {
this.sex = sex == null ? null : sex.trim();
}
public Date getBirthday() {
return birthday;
}
public void setBirthday(Date birthday) {
this.birthday = birthday;
}
public String getEducationalStatus() {
return educationalStatus;
}
public void setEducationalStatus(String educationalStatus) {
this.educationalStatus = educationalStatus == null ? null : educationalStatus.trim();
}
public String getCareer() {
return career;
}
public void setCareer(String career) {
this.career = career == null ? null : career.trim();
}
public String getMaritalStatus() {
return maritalStatus;
}
public void setMaritalStatus(String maritalStatus) {
this.maritalStatus = maritalStatus == null ? null : maritalStatus.trim();
}
public String getNation() {
return nation;
}
public void setNation(String nation) {
this.nation = nation == null ? null : nation.trim();
}
public String getNativePlace() {
return nativePlace;
}
public void setNativePlace(String nativePlace) {
this.nativePlace = nativePlace == null ? null : nativePlace.trim();
}
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address == null ? null : address.trim();
}
public String getDwellingState() {
return dwellingState;
}
public void setDwellingState(String dwellingState) {
this.dwellingState = dwellingState == null ? null : dwellingState.trim();
}
public String getContactName() {
return contactName;
}
public void setContactName(String contactName) {
this.contactName = contactName == null ? null : contactName.trim();
}
public String getContactMobile() {
return contactMobile;
}
public void setContactMobile(String contactMobile) {
this.contactMobile = contactMobile == null ? null : contactMobile.trim();
}
public String getContactRelation() {
return contactRelation;
}
public void setContactRelation(String contactRelation) {
this.contactRelation = contactRelation == null ? null : contactRelation.trim();
}
public String getAboBloodType() {
return aboBloodType;
}
public void setAboBloodType(String aboBloodType) {
this.aboBloodType = aboBloodType == null ? null : aboBloodType.trim();
}
public String getRhBloodType() {
return rhBloodType;
}
public void setRhBloodType(String rhBloodType) {
this.rhBloodType = rhBloodType == null ? null : rhBloodType.trim();
}
public String getBelief() {
return belief;
}
public void setBelief(String belief) {
this.belief = belief == null ? null : belief.trim();
}
public String getHobby() {
return hobby;
}
public void setHobby(String hobby) {
this.hobby = hobby == null ? null : hobby.trim();
}
public String getCreateBy() {
return createBy;
}
public void setCreateBy(String createBy) {
this.createBy = createBy == null ? null : createBy.trim();
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public String getUpdateBy() {
return updateBy;
}
public void setUpdateBy(String updateBy) {
this.updateBy = updateBy == null ? null : updateBy.trim();
}
public Date getUpdateTime() {
return updateTime;
}
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
public Byte getDelFlag() {
return delFlag;
}
public void setDelFlag(Byte delFlag) {
this.delFlag = delFlag;
}
public String getRemark() {
return remark;
}
public void setRemark(String remark) {
this.remark = remark == null ? null : remark.trim();
}
public String getSync() {
return sync;
}
public void setSync(String sync) {
this.sync = sync == null ? null : sync.trim();
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(getClass().getSimpleName());
sb.append(" [");
sb.append("Hash = ").append(hashCode());
sb.append(", id=").append(id);
sb.append(", name=").append(name);
sb.append(", patientNo=").append(patientNo);
sb.append(", idCard=").append(idCard);
sb.append(", phone=").append(phone);
sb.append(", sex=").append(sex);
sb.append(", birthday=").append(birthday);
sb.append(", educationalStatus=").append(educationalStatus);
sb.append(", career=").append(career);
sb.append(", maritalStatus=").append(maritalStatus);
sb.append(", nation=").append(nation);
sb.append(", nativePlace=").append(nativePlace);
sb.append(", address=").append(address);
sb.append(", dwellingState=").append(dwellingState);
sb.append(", contactName=").append(contactName);
sb.append(", contactMobile=").append(contactMobile);
sb.append(", contactRelation=").append(contactRelation);
sb.append(", aboBloodType=").append(aboBloodType);
sb.append(", rhBloodType=").append(rhBloodType);
sb.append(", belief=").append(belief);
sb.append(", hobby=").append(hobby);
sb.append(", createBy=").append(createBy);
sb.append(", createTime=").append(createTime);
sb.append(", updateBy=").append(updateBy);
sb.append(", updateTime=").append(updateTime);
sb.append(", delFlag=").append(delFlag);
sb.append(", remark=").append(remark);
sb.append(", sync=").append(sync);
sb.append("]");
return sb.toString();
}
}

2138
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientBaseInfoExample.java

File diff suppressed because it is too large

172
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientDiagnosis.java

@ -0,0 +1,172 @@
package com.ccsens.system.domain.po;
import java.io.Serializable;
import java.util.Date;
public class DockPatientDiagnosis implements Serializable {
private Long id;
private String visitNo;
private String diagnosisType;
private Byte isMainDiagnosis;
private String diagnosisName;
private String diagnosisCode;
private Date diagnosisDate;
private String createBy;
private Date createTime;
private String updateBy;
private Date updateTime;
private Byte delFlag;
private String remark;
private String sync;
private static final long serialVersionUID = 1L;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getVisitNo() {
return visitNo;
}
public void setVisitNo(String visitNo) {
this.visitNo = visitNo == null ? null : visitNo.trim();
}
public String getDiagnosisType() {
return diagnosisType;
}
public void setDiagnosisType(String diagnosisType) {
this.diagnosisType = diagnosisType == null ? null : diagnosisType.trim();
}
public Byte getIsMainDiagnosis() {
return isMainDiagnosis;
}
public void setIsMainDiagnosis(Byte isMainDiagnosis) {
this.isMainDiagnosis = isMainDiagnosis;
}
public String getDiagnosisName() {
return diagnosisName;
}
public void setDiagnosisName(String diagnosisName) {
this.diagnosisName = diagnosisName == null ? null : diagnosisName.trim();
}
public String getDiagnosisCode() {
return diagnosisCode;
}
public void setDiagnosisCode(String diagnosisCode) {
this.diagnosisCode = diagnosisCode == null ? null : diagnosisCode.trim();
}
public Date getDiagnosisDate() {
return diagnosisDate;
}
public void setDiagnosisDate(Date diagnosisDate) {
this.diagnosisDate = diagnosisDate;
}
public String getCreateBy() {
return createBy;
}
public void setCreateBy(String createBy) {
this.createBy = createBy == null ? null : createBy.trim();
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public String getUpdateBy() {
return updateBy;
}
public void setUpdateBy(String updateBy) {
this.updateBy = updateBy == null ? null : updateBy.trim();
}
public Date getUpdateTime() {
return updateTime;
}
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
public Byte getDelFlag() {
return delFlag;
}
public void setDelFlag(Byte delFlag) {
this.delFlag = delFlag;
}
public String getRemark() {
return remark;
}
public void setRemark(String remark) {
this.remark = remark == null ? null : remark.trim();
}
public String getSync() {
return sync;
}
public void setSync(String sync) {
this.sync = sync == null ? null : sync.trim();
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(getClass().getSimpleName());
sb.append(" [");
sb.append("Hash = ").append(hashCode());
sb.append(", id=").append(id);
sb.append(", visitNo=").append(visitNo);
sb.append(", diagnosisType=").append(diagnosisType);
sb.append(", isMainDiagnosis=").append(isMainDiagnosis);
sb.append(", diagnosisName=").append(diagnosisName);
sb.append(", diagnosisCode=").append(diagnosisCode);
sb.append(", diagnosisDate=").append(diagnosisDate);
sb.append(", createBy=").append(createBy);
sb.append(", createTime=").append(createTime);
sb.append(", updateBy=").append(updateBy);
sb.append(", updateTime=").append(updateTime);
sb.append(", delFlag=").append(delFlag);
sb.append(", remark=").append(remark);
sb.append(", sync=").append(sync);
sb.append("]");
return sb.toString();
}
}

1148
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientDiagnosisExample.java

File diff suppressed because it is too large

162
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientMedicationInfo.java

@ -0,0 +1,162 @@
package com.ccsens.system.domain.po;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
public class DockPatientMedicationInfo implements Serializable {
private Long id;
private String visitNo;
private String drugName;
private BigDecimal dose;
private String unit;
private String frequency;
private String createBy;
private Date createTime;
private String updateBy;
private Date updateTime;
private Byte delFlag;
private String remark;
private String sync;
private static final long serialVersionUID = 1L;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getVisitNo() {
return visitNo;
}
public void setVisitNo(String visitNo) {
this.visitNo = visitNo == null ? null : visitNo.trim();
}
public String getDrugName() {
return drugName;
}
public void setDrugName(String drugName) {
this.drugName = drugName == null ? null : drugName.trim();
}
public BigDecimal getDose() {
return dose;
}
public void setDose(BigDecimal dose) {
this.dose = dose;
}
public String getUnit() {
return unit;
}
public void setUnit(String unit) {
this.unit = unit == null ? null : unit.trim();
}
public String getFrequency() {
return frequency;
}
public void setFrequency(String frequency) {
this.frequency = frequency == null ? null : frequency.trim();
}
public String getCreateBy() {
return createBy;
}
public void setCreateBy(String createBy) {
this.createBy = createBy == null ? null : createBy.trim();
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public String getUpdateBy() {
return updateBy;
}
public void setUpdateBy(String updateBy) {
this.updateBy = updateBy == null ? null : updateBy.trim();
}
public Date getUpdateTime() {
return updateTime;
}
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
public Byte getDelFlag() {
return delFlag;
}
public void setDelFlag(Byte delFlag) {
this.delFlag = delFlag;
}
public String getRemark() {
return remark;
}
public void setRemark(String remark) {
this.remark = remark == null ? null : remark.trim();
}
public String getSync() {
return sync;
}
public void setSync(String sync) {
this.sync = sync == null ? null : sync.trim();
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(getClass().getSimpleName());
sb.append(" [");
sb.append("Hash = ").append(hashCode());
sb.append(", id=").append(id);
sb.append(", visitNo=").append(visitNo);
sb.append(", drugName=").append(drugName);
sb.append(", dose=").append(dose);
sb.append(", unit=").append(unit);
sb.append(", frequency=").append(frequency);
sb.append(", createBy=").append(createBy);
sb.append(", createTime=").append(createTime);
sb.append(", updateBy=").append(updateBy);
sb.append(", updateTime=").append(updateTime);
sb.append(", delFlag=").append(delFlag);
sb.append(", remark=").append(remark);
sb.append(", sync=").append(sync);
sb.append("]");
return sb.toString();
}
}

1062
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientMedicationInfoExample.java

File diff suppressed because it is too large

514
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientVisitInfo.java

@ -0,0 +1,514 @@
package com.ccsens.system.domain.po;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
public class DockPatientVisitInfo implements Serializable {
private Long id;
private String idCard;
private String patientNo;
private String visitType;
private String visitNo;
private Integer age;
private String department;
private String doctor;
private Date admissionDate;
private Integer admissionCount;
private String bedNumber;
private Date dischargeDate;
private String admissionMethod;
private String dischargeMethod;
private BigDecimal height;
private BigDecimal weight;
private BigDecimal tz;
private BigDecimal temperature;
private Integer bloodPressureShrink;
private Integer bloodPressureDiastole;
private Integer pulse;
private BigDecimal creatinine;
private BigDecimal oxygenSaturation;
private BigDecimal albumin;
private BigDecimal totalProtein;
private BigDecimal vitaminD3;
private BigDecimal hematocrit;
private BigDecimal dimer;
private Byte smokingHistory;
private Integer smokingYear;
private Byte smokingQuit;
private Integer smokingQuitYear;
private Byte drinkHistory;
private Integer drinkYear;
private Byte drinkQuit;
private Integer drinkQuitYear;
private Byte hasAllergy;
private String allergyDrug;
private String createBy;
private Date createTime;
private String updateBy;
private Date updateTime;
private Byte delFlag;
private String remark;
private String sync;
private static final long serialVersionUID = 1L;
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
public String getIdCard() {
return idCard;
}
public void setIdCard(String idCard) {
this.idCard = idCard == null ? null : idCard.trim();
}
public String getPatientNo() {
return patientNo;
}
public void setPatientNo(String patientNo) {
this.patientNo = patientNo == null ? null : patientNo.trim();
}
public String getVisitType() {
return visitType;
}
public void setVisitType(String visitType) {
this.visitType = visitType == null ? null : visitType.trim();
}
public String getVisitNo() {
return visitNo;
}
public void setVisitNo(String visitNo) {
this.visitNo = visitNo == null ? null : visitNo.trim();
}
public Integer getAge() {
return age;
}
public void setAge(Integer age) {
this.age = age;
}
public String getDepartment() {
return department;
}
public void setDepartment(String department) {
this.department = department == null ? null : department.trim();
}
public String getDoctor() {
return doctor;
}
public void setDoctor(String doctor) {
this.doctor = doctor == null ? null : doctor.trim();
}
public Date getAdmissionDate() {
return admissionDate;
}
public void setAdmissionDate(Date admissionDate) {
this.admissionDate = admissionDate;
}
public Integer getAdmissionCount() {
return admissionCount;
}
public void setAdmissionCount(Integer admissionCount) {
this.admissionCount = admissionCount;
}
public String getBedNumber() {
return bedNumber;
}
public void setBedNumber(String bedNumber) {
this.bedNumber = bedNumber == null ? null : bedNumber.trim();
}
public Date getDischargeDate() {
return dischargeDate;
}
public void setDischargeDate(Date dischargeDate) {
this.dischargeDate = dischargeDate;
}
public String getAdmissionMethod() {
return admissionMethod;
}
public void setAdmissionMethod(String admissionMethod) {
this.admissionMethod = admissionMethod == null ? null : admissionMethod.trim();
}
public String getDischargeMethod() {
return dischargeMethod;
}
public void setDischargeMethod(String dischargeMethod) {
this.dischargeMethod = dischargeMethod == null ? null : dischargeMethod.trim();
}
public BigDecimal getHeight() {
return height;
}
public void setHeight(BigDecimal height) {
this.height = height;
}
public BigDecimal getWeight() {
return weight;
}
public void setWeight(BigDecimal weight) {
this.weight = weight;
}
public BigDecimal getTz() {
return tz;
}
public void setTz(BigDecimal tz) {
this.tz = tz;
}
public BigDecimal getTemperature() {
return temperature;
}
public void setTemperature(BigDecimal temperature) {
this.temperature = temperature;
}
public Integer getBloodPressureShrink() {
return bloodPressureShrink;
}
public void setBloodPressureShrink(Integer bloodPressureShrink) {
this.bloodPressureShrink = bloodPressureShrink;
}
public Integer getBloodPressureDiastole() {
return bloodPressureDiastole;
}
public void setBloodPressureDiastole(Integer bloodPressureDiastole) {
this.bloodPressureDiastole = bloodPressureDiastole;
}
public Integer getPulse() {
return pulse;
}
public void setPulse(Integer pulse) {
this.pulse = pulse;
}
public BigDecimal getCreatinine() {
return creatinine;
}
public void setCreatinine(BigDecimal creatinine) {
this.creatinine = creatinine;
}
public BigDecimal getOxygenSaturation() {
return oxygenSaturation;
}
public void setOxygenSaturation(BigDecimal oxygenSaturation) {
this.oxygenSaturation = oxygenSaturation;
}
public BigDecimal getAlbumin() {
return albumin;
}
public void setAlbumin(BigDecimal albumin) {
this.albumin = albumin;
}
public BigDecimal getTotalProtein() {
return totalProtein;
}
public void setTotalProtein(BigDecimal totalProtein) {
this.totalProtein = totalProtein;
}
public BigDecimal getVitaminD3() {
return vitaminD3;
}
public void setVitaminD3(BigDecimal vitaminD3) {
this.vitaminD3 = vitaminD3;
}
public BigDecimal getHematocrit() {
return hematocrit;
}
public void setHematocrit(BigDecimal hematocrit) {
this.hematocrit = hematocrit;
}
public BigDecimal getDimer() {
return dimer;
}
public void setDimer(BigDecimal dimer) {
this.dimer = dimer;
}
public Byte getSmokingHistory() {
return smokingHistory;
}
public void setSmokingHistory(Byte smokingHistory) {
this.smokingHistory = smokingHistory;
}
public Integer getSmokingYear() {
return smokingYear;
}
public void setSmokingYear(Integer smokingYear) {
this.smokingYear = smokingYear;
}
public Byte getSmokingQuit() {
return smokingQuit;
}
public void setSmokingQuit(Byte smokingQuit) {
this.smokingQuit = smokingQuit;
}
public Integer getSmokingQuitYear() {
return smokingQuitYear;
}
public void setSmokingQuitYear(Integer smokingQuitYear) {
this.smokingQuitYear = smokingQuitYear;
}
public Byte getDrinkHistory() {
return drinkHistory;
}
public void setDrinkHistory(Byte drinkHistory) {
this.drinkHistory = drinkHistory;
}
public Integer getDrinkYear() {
return drinkYear;
}
public void setDrinkYear(Integer drinkYear) {
this.drinkYear = drinkYear;
}
public Byte getDrinkQuit() {
return drinkQuit;
}
public void setDrinkQuit(Byte drinkQuit) {
this.drinkQuit = drinkQuit;
}
public Integer getDrinkQuitYear() {
return drinkQuitYear;
}
public void setDrinkQuitYear(Integer drinkQuitYear) {
this.drinkQuitYear = drinkQuitYear;
}
public Byte getHasAllergy() {
return hasAllergy;
}
public void setHasAllergy(Byte hasAllergy) {
this.hasAllergy = hasAllergy;
}
public String getAllergyDrug() {
return allergyDrug;
}
public void setAllergyDrug(String allergyDrug) {
this.allergyDrug = allergyDrug == null ? null : allergyDrug.trim();
}
public String getCreateBy() {
return createBy;
}
public void setCreateBy(String createBy) {
this.createBy = createBy == null ? null : createBy.trim();
}
public Date getCreateTime() {
return createTime;
}
public void setCreateTime(Date createTime) {
this.createTime = createTime;
}
public String getUpdateBy() {
return updateBy;
}
public void setUpdateBy(String updateBy) {
this.updateBy = updateBy == null ? null : updateBy.trim();
}
public Date getUpdateTime() {
return updateTime;
}
public void setUpdateTime(Date updateTime) {
this.updateTime = updateTime;
}
public Byte getDelFlag() {
return delFlag;
}
public void setDelFlag(Byte delFlag) {
this.delFlag = delFlag;
}
public String getRemark() {
return remark;
}
public void setRemark(String remark) {
this.remark = remark == null ? null : remark.trim();
}
public String getSync() {
return sync;
}
public void setSync(String sync) {
this.sync = sync == null ? null : sync.trim();
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append(getClass().getSimpleName());
sb.append(" [");
sb.append("Hash = ").append(hashCode());
sb.append(", id=").append(id);
sb.append(", idCard=").append(idCard);
sb.append(", patientNo=").append(patientNo);
sb.append(", visitType=").append(visitType);
sb.append(", visitNo=").append(visitNo);
sb.append(", age=").append(age);
sb.append(", department=").append(department);
sb.append(", doctor=").append(doctor);
sb.append(", admissionDate=").append(admissionDate);
sb.append(", admissionCount=").append(admissionCount);
sb.append(", bedNumber=").append(bedNumber);
sb.append(", dischargeDate=").append(dischargeDate);
sb.append(", admissionMethod=").append(admissionMethod);
sb.append(", dischargeMethod=").append(dischargeMethod);
sb.append(", height=").append(height);
sb.append(", weight=").append(weight);
sb.append(", tz=").append(tz);
sb.append(", temperature=").append(temperature);
sb.append(", bloodPressureShrink=").append(bloodPressureShrink);
sb.append(", bloodPressureDiastole=").append(bloodPressureDiastole);
sb.append(", pulse=").append(pulse);
sb.append(", creatinine=").append(creatinine);
sb.append(", oxygenSaturation=").append(oxygenSaturation);
sb.append(", albumin=").append(albumin);
sb.append(", totalProtein=").append(totalProtein);
sb.append(", vitaminD3=").append(vitaminD3);
sb.append(", hematocrit=").append(hematocrit);
sb.append(", dimer=").append(dimer);
sb.append(", smokingHistory=").append(smokingHistory);
sb.append(", smokingYear=").append(smokingYear);
sb.append(", smokingQuit=").append(smokingQuit);
sb.append(", smokingQuitYear=").append(smokingQuitYear);
sb.append(", drinkHistory=").append(drinkHistory);
sb.append(", drinkYear=").append(drinkYear);
sb.append(", drinkQuit=").append(drinkQuit);
sb.append(", drinkQuitYear=").append(drinkQuitYear);
sb.append(", hasAllergy=").append(hasAllergy);
sb.append(", allergyDrug=").append(allergyDrug);
sb.append(", createBy=").append(createBy);
sb.append(", createTime=").append(createTime);
sb.append(", updateBy=").append(updateBy);
sb.append(", updateTime=").append(updateTime);
sb.append(", delFlag=").append(delFlag);
sb.append(", remark=").append(remark);
sb.append(", sync=").append(sync);
sb.append("]");
return sb.toString();
}
}

3042
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/DockPatientVisitInfoExample.java

File diff suppressed because it is too large

11
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/PmsPatient.java

@ -96,6 +96,8 @@ public class PmsPatient implements Serializable {
private String rhBloodType; private String rhBloodType;
private String patientNo;
private static final long serialVersionUID = 1L; private static final long serialVersionUID = 1L;
public Long getId() { public Long getId() {
@ -466,6 +468,14 @@ public class PmsPatient implements Serializable {
this.rhBloodType = rhBloodType == null ? null : rhBloodType.trim(); this.rhBloodType = rhBloodType == null ? null : rhBloodType.trim();
} }
public String getPatientNo() {
return patientNo;
}
public void setPatientNo(String patientNo) {
this.patientNo = patientNo == null ? null : patientNo.trim();
}
@Override @Override
public String toString() { public String toString() {
StringBuilder sb = new StringBuilder(); StringBuilder sb = new StringBuilder();
@ -518,6 +528,7 @@ public class PmsPatient implements Serializable {
sb.append(", idCardTypeOther=").append(idCardTypeOther); sb.append(", idCardTypeOther=").append(idCardTypeOther);
sb.append(", aboBloodType=").append(aboBloodType); sb.append(", aboBloodType=").append(aboBloodType);
sb.append(", rhBloodType=").append(rhBloodType); sb.append(", rhBloodType=").append(rhBloodType);
sb.append(", patientNo=").append(patientNo);
sb.append("]"); sb.append("]");
return sb.toString(); return sb.toString();
} }

70
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/po/PmsPatientExample.java

@ -3154,6 +3154,76 @@ public class PmsPatientExample {
addCriterion("rh_blood_type not between", value1, value2, "rhBloodType"); addCriterion("rh_blood_type not between", value1, value2, "rhBloodType");
return (Criteria) this; return (Criteria) this;
} }
public Criteria andPatientNoIsNull() {
addCriterion("patient_no is null");
return (Criteria) this;
}
public Criteria andPatientNoIsNotNull() {
addCriterion("patient_no is not null");
return (Criteria) this;
}
public Criteria andPatientNoEqualTo(String value) {
addCriterion("patient_no =", value, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoNotEqualTo(String value) {
addCriterion("patient_no <>", value, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoGreaterThan(String value) {
addCriterion("patient_no >", value, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoGreaterThanOrEqualTo(String value) {
addCriterion("patient_no >=", value, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoLessThan(String value) {
addCriterion("patient_no <", value, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoLessThanOrEqualTo(String value) {
addCriterion("patient_no <=", value, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoLike(String value) {
addCriterion("patient_no like", value, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoNotLike(String value) {
addCriterion("patient_no not like", value, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoIn(List<String> values) {
addCriterion("patient_no in", values, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoNotIn(List<String> values) {
addCriterion("patient_no not in", values, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoBetween(String value1, String value2) {
addCriterion("patient_no between", value1, value2, "patientNo");
return (Criteria) this;
}
public Criteria andPatientNoNotBetween(String value1, String value2) {
addCriterion("patient_no not between", value1, value2, "patientNo");
return (Criteria) this;
}
} }
public static class Criteria extends GeneratedCriteria { public static class Criteria extends GeneratedCriteria {

33
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/domain/vo/RmsVo.java

@ -1275,4 +1275,37 @@ public class RmsVo {
private Byte completeStatus; private Byte completeStatus;
} }
@ApiModel("导出历史报告单(对接)-VO")
@Data
public static class ReportPDF{
@ApiModelProperty("报告单ID")
private Long reportId;
@ApiModelProperty("测评ID")
private Long evaluationId;
@ApiModelProperty("患者名称")
private String patientName;
@ApiModelProperty("性别")
private Byte sex;
@ApiModelProperty("年龄")
private int Age;
@ApiModelProperty("出生日期")
private String birthDate;
@ApiModelProperty("身份证号")
private String idCard;
@ApiModelProperty("就诊类型 0门诊 1住院")
private Byte visitType;
@ApiModelProperty("就诊号")
private String visitNo;
@ApiModelProperty("部门")
private String department;
@ApiModelProperty("评估医生Id")
private String assessorId;
@ApiModelProperty("评估医生")
private String assessor;
@ApiModelProperty("评估时间")
private String assessTime;
@ApiModelProperty("报告单文件路径")
private String url;
}
} }

18
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/dao/DockDao.java

@ -0,0 +1,18 @@
package com.ccsens.system.persist.dao;
import com.ccsens.system.domain.dto.DockDto;
import org.apache.ibatis.annotations.Param;
import java.util.List;
/**
* @Author zzc
* @Package com.ccsens.system.persist.dao
* @Date 2026/2/9 14:59
* @description:
*/
public interface DockDao {
void bathDiagnosis(@Param("diagnosis") List<DockDto.Zhenduan> diagnosis);
void bathMedication(@Param("medication") List<DockDto.Yongyao> medication);
}

30
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DmsRunningLogMapper.java

@ -0,0 +1,30 @@
package com.ccsens.system.persist.mapper;
import com.ccsens.system.domain.po.DmsRunningLog;
import com.ccsens.system.domain.po.DmsRunningLogExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface DmsRunningLogMapper {
long countByExample(DmsRunningLogExample example);
int deleteByExample(DmsRunningLogExample example);
int deleteByPrimaryKey(Long id);
int insert(DmsRunningLog record);
int insertSelective(DmsRunningLog record);
List<DmsRunningLog> selectByExample(DmsRunningLogExample example);
DmsRunningLog selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") DmsRunningLog record, @Param("example") DmsRunningLogExample example);
int updateByExample(@Param("record") DmsRunningLog record, @Param("example") DmsRunningLogExample example);
int updateByPrimaryKeySelective(DmsRunningLog record);
int updateByPrimaryKey(DmsRunningLog record);
}

30
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockDeptMapper.java

@ -0,0 +1,30 @@
package com.ccsens.system.persist.mapper;
import com.ccsens.system.domain.po.DockDept;
import com.ccsens.system.domain.po.DockDeptExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface DockDeptMapper {
long countByExample(DockDeptExample example);
int deleteByExample(DockDeptExample example);
int deleteByPrimaryKey(Long id);
int insert(DockDept record);
int insertSelective(DockDept record);
List<DockDept> selectByExample(DockDeptExample example);
DockDept selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") DockDept record, @Param("example") DockDeptExample example);
int updateByExample(@Param("record") DockDept record, @Param("example") DockDeptExample example);
int updateByPrimaryKeySelective(DockDept record);
int updateByPrimaryKey(DockDept record);
}

30
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockEmplMapper.java

@ -0,0 +1,30 @@
package com.ccsens.system.persist.mapper;
import com.ccsens.system.domain.po.DockEmpl;
import com.ccsens.system.domain.po.DockEmplExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface DockEmplMapper {
long countByExample(DockEmplExample example);
int deleteByExample(DockEmplExample example);
int deleteByPrimaryKey(Long id);
int insert(DockEmpl record);
int insertSelective(DockEmpl record);
List<DockEmpl> selectByExample(DockEmplExample example);
DockEmpl selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") DockEmpl record, @Param("example") DockEmplExample example);
int updateByExample(@Param("record") DockEmpl record, @Param("example") DockEmplExample example);
int updateByPrimaryKeySelective(DockEmpl record);
int updateByPrimaryKey(DockEmpl record);
}

30
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockPatientBaseInfoMapper.java

@ -0,0 +1,30 @@
package com.ccsens.system.persist.mapper;
import com.ccsens.system.domain.po.DockPatientBaseInfo;
import com.ccsens.system.domain.po.DockPatientBaseInfoExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface DockPatientBaseInfoMapper {
long countByExample(DockPatientBaseInfoExample example);
int deleteByExample(DockPatientBaseInfoExample example);
int deleteByPrimaryKey(Long id);
int insert(DockPatientBaseInfo record);
int insertSelective(DockPatientBaseInfo record);
List<DockPatientBaseInfo> selectByExample(DockPatientBaseInfoExample example);
DockPatientBaseInfo selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") DockPatientBaseInfo record, @Param("example") DockPatientBaseInfoExample example);
int updateByExample(@Param("record") DockPatientBaseInfo record, @Param("example") DockPatientBaseInfoExample example);
int updateByPrimaryKeySelective(DockPatientBaseInfo record);
int updateByPrimaryKey(DockPatientBaseInfo record);
}

30
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockPatientDiagnosisMapper.java

@ -0,0 +1,30 @@
package com.ccsens.system.persist.mapper;
import com.ccsens.system.domain.po.DockPatientDiagnosis;
import com.ccsens.system.domain.po.DockPatientDiagnosisExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface DockPatientDiagnosisMapper {
long countByExample(DockPatientDiagnosisExample example);
int deleteByExample(DockPatientDiagnosisExample example);
int deleteByPrimaryKey(Long id);
int insert(DockPatientDiagnosis record);
int insertSelective(DockPatientDiagnosis record);
List<DockPatientDiagnosis> selectByExample(DockPatientDiagnosisExample example);
DockPatientDiagnosis selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") DockPatientDiagnosis record, @Param("example") DockPatientDiagnosisExample example);
int updateByExample(@Param("record") DockPatientDiagnosis record, @Param("example") DockPatientDiagnosisExample example);
int updateByPrimaryKeySelective(DockPatientDiagnosis record);
int updateByPrimaryKey(DockPatientDiagnosis record);
}

30
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockPatientMedicationInfoMapper.java

@ -0,0 +1,30 @@
package com.ccsens.system.persist.mapper;
import com.ccsens.system.domain.po.DockPatientMedicationInfo;
import com.ccsens.system.domain.po.DockPatientMedicationInfoExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface DockPatientMedicationInfoMapper {
long countByExample(DockPatientMedicationInfoExample example);
int deleteByExample(DockPatientMedicationInfoExample example);
int deleteByPrimaryKey(Long id);
int insert(DockPatientMedicationInfo record);
int insertSelective(DockPatientMedicationInfo record);
List<DockPatientMedicationInfo> selectByExample(DockPatientMedicationInfoExample example);
DockPatientMedicationInfo selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") DockPatientMedicationInfo record, @Param("example") DockPatientMedicationInfoExample example);
int updateByExample(@Param("record") DockPatientMedicationInfo record, @Param("example") DockPatientMedicationInfoExample example);
int updateByPrimaryKeySelective(DockPatientMedicationInfo record);
int updateByPrimaryKey(DockPatientMedicationInfo record);
}

30
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/DockPatientVisitInfoMapper.java

@ -0,0 +1,30 @@
package com.ccsens.system.persist.mapper;
import com.ccsens.system.domain.po.DockPatientVisitInfo;
import com.ccsens.system.domain.po.DockPatientVisitInfoExample;
import java.util.List;
import org.apache.ibatis.annotations.Param;
public interface DockPatientVisitInfoMapper {
long countByExample(DockPatientVisitInfoExample example);
int deleteByExample(DockPatientVisitInfoExample example);
int deleteByPrimaryKey(Long id);
int insert(DockPatientVisitInfo record);
int insertSelective(DockPatientVisitInfo record);
List<DockPatientVisitInfo> selectByExample(DockPatientVisitInfoExample example);
DockPatientVisitInfo selectByPrimaryKey(Long id);
int updateByExampleSelective(@Param("record") DockPatientVisitInfo record, @Param("example") DockPatientVisitInfoExample example);
int updateByExample(@Param("record") DockPatientVisitInfo record, @Param("example") DockPatientVisitInfoExample example);
int updateByPrimaryKeySelective(DockPatientVisitInfo record);
int updateByPrimaryKey(DockPatientVisitInfo record);
}

2
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/persist/mapper/SysUserMapper.java

@ -152,4 +152,6 @@ public interface SysUserMapper {
* @return * @return
*/ */
List<SysUser> selectUserByRoleKey(@Param("roleKey") String roleKey); List<SysUser> selectUserByRoleKey(@Param("roleKey") String roleKey);
List<SysUser> getZcpsByHospitalId(@Param("hospitalId")Long hospitalId);
} }

26
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/service/DmsDataValueService.java

@ -0,0 +1,26 @@
package com.ccsens.system.service;
import com.ccsens.system.domain.po.DmsRunningLog;
import java.util.Date;
/**
* @Author zzc
* @Package com.ccsens.system.service
* @Date 2026/2/10 14:39
* @description:
*/
public interface DmsDataValueService {
boolean isProcessing();
DmsRunningLog getDmsRunningLogs();
void insertRunningLog(DmsRunningLog dmsRunningLog);
void updateRunningLog(DmsRunningLog dcsRunningLog);
}

35
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/service/DockService.java

@ -0,0 +1,35 @@
package com.ccsens.system.service;
import com.ccsens.common.core.domain.entity.SysDept;
import com.ccsens.common.core.domain.entity.SysUser;
import com.ccsens.system.domain.dto.DockDto;
import java.util.Date;
import java.util.List;
/**
* @Author zzc
* @Package com.ccsens.system.service
* @Date 2026/2/9 14:53
* @description:
*/
public interface DockService {
Integer addDockPatient(DockDto.AddPatientDto dto);
void addDept(DockDto.DockDeptInfo dto);
void addEmpl(DockDto.DockEmplInfo dto);
/**
* 同步三方数据到业务系统
*/
void pulling(Date startTime, Date endTime);
void syncHospitalData();
List<SysDept> syncUmsDeptSlave();
void syncUmsDeptMaster(List<SysDept> sysDepts);
List<SysUser> syncUmsUserSlave();
void syncUmsUserMaster(List<SysUser> sysUsers);
}

63
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/service/impl/DmsDataValueServiceImpl.java

@ -0,0 +1,63 @@
package com.ccsens.system.service.impl;
import cn.hutool.core.collection.CollectionUtil;
import com.ccsens.common.constant.UserConstants;
import com.ccsens.system.domain.po.DmsRunningLog;
import com.ccsens.system.domain.po.DmsRunningLogExample;
import com.ccsens.system.persist.mapper.DmsRunningLogMapper;
import com.ccsens.system.service.DmsDataValueService;
import com.github.pagehelper.PageHelper;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.Date;
import java.util.List;
/**
* @Author zzc
* @Package com.ccsens.system.service.impl
* @Date 2026/2/10 14:39
* @description:
*/
@Service
public class DmsDataValueServiceImpl implements DmsDataValueService {
@Resource
private DmsRunningLogMapper dmsRunningLogMapper;
@Override
public boolean isProcessing() {
DmsRunningLogExample example = new DmsRunningLogExample();
example.createCriteria().andStatusEqualTo(UserConstants.DcsRunningStatus.Processing.getCode().byteValue());
return dmsRunningLogMapper.countByExample(example) > 0;
}
@Override
public DmsRunningLog getDmsRunningLogs() {
DmsRunningLogExample dmsRunningLogExample = new DmsRunningLogExample();
dmsRunningLogExample.createCriteria().andStatusEqualTo((byte) 1);
dmsRunningLogExample.setOrderByClause("created_at desc");
PageHelper.startPage(1, 1);
List<DmsRunningLog> dmsRunningLogs = dmsRunningLogMapper.selectByExample(dmsRunningLogExample);
if (CollectionUtil.isNotEmpty(dmsRunningLogs)) {
return dmsRunningLogs.get(0);
}
return null;
}
@Transactional(propagation = Propagation.REQUIRES_NEW, rollbackFor = Exception.class)
@Override
public void insertRunningLog(DmsRunningLog dmsRunningLog) {
dmsRunningLogMapper.insertSelective(dmsRunningLog);
}
@Override
@Transactional(propagation = Propagation.REQUIRES_NEW, rollbackFor = Exception.class)
public void updateRunningLog(DmsRunningLog dcsRunningLog) {
dmsRunningLogMapper.updateByPrimaryKeySelective(dcsRunningLog);
}
}

869
ruisi_java/ruisi-system/src/main/java/com/ccsens/system/service/impl/DockServiceImpl.java

@ -0,0 +1,869 @@
package com.ccsens.system.service.impl;
import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.collection.CollUtil;
import cn.hutool.core.date.DateField;
import cn.hutool.core.date.DateUtil;
import cn.hutool.core.util.IdUtil;
import cn.hutool.core.util.ObjectUtil;
import cn.hutool.core.util.StrUtil;
import cn.hutool.extra.pinyin.PinyinUtil;
import com.ccsens.common.annotation.DataSource;
import com.ccsens.common.constant.ErrorConstant;
import com.ccsens.common.core.domain.entity.SysDept;
import com.ccsens.common.core.domain.entity.SysUser;
import com.ccsens.common.enums.DataSourceType;
import com.ccsens.common.exception.base.BaseException;
import com.ccsens.common.utils.DateUtils;
import com.ccsens.common.utils.SecurityUtils;
import com.ccsens.common.utils.StringUtils;
import com.ccsens.system.domain.SysUserRole;
import com.ccsens.system.domain.dto.DockDto;
import com.ccsens.system.domain.po.*;
import com.ccsens.system.persist.dao.DockDao;
import com.ccsens.system.persist.mapper.*;
import com.ccsens.system.service.DmsDataValueService;
import com.ccsens.system.service.DockService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.stream.Collectors;
/**
* @Author zzc
* @Package com.ccsens.system.service.impl
* @Date 2026/2/9 14:55
* @description:
*/
@Slf4j
@Service
public class DockServiceImpl implements DockService {
@Resource
private DockPatientBaseInfoMapper dockPatientBaseInfoMapper;
@Resource
private DockPatientVisitInfoMapper dockPatientVisitInfoMapper;
@Resource
private DockPatientDiagnosisMapper dockPatientDiagnosisMapper;
@Resource
private DockPatientMedicationInfoMapper dockPatientMedicationInfoMapper;
@Resource
private DockDao dockDao;
@Resource
private DockDeptMapper dockDeptMapper;
@Resource
private DockEmplMapper dockEmplMapper;
@Resource
private DmsDataValueService dmsDataValueService;
private static final String DATE_FORMAT = "yyyy-MM-dd";
@Resource
private PmsPatientMapper pmsPatientMapper;
@Resource
private PmsPatientBodyMapper pmsPatientBodyMapper;
@Resource
private PmsPatientDiagnosisMapper pmsPatientDiagnosisMapper;
@Resource
private PmsPatientParentIllnessMapper pmsPatientParentIllnessMapper;
@Resource
private SysDeptMapper sysDeptMapper;
@Resource
private SysUserMapper sysUserMapper;
@Resource
private SysUserRoleMapper userRoleMapper;
@Value("${hospitalId:}")
private Long hospitalId;
@Value("${generalPassword:}")
private String generalPassword;
@Override
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
public Integer addDockPatient(DockDto.AddPatientDto dto) {
DockDto.PatientInfo patientInfo = dto.getBasicInfo();
//1.根据身份证判断用户基本信息是否存在
DockPatientBaseInfoExample dockPatientBaseInfoExample = new DockPatientBaseInfoExample();
dockPatientBaseInfoExample.createCriteria().andIdCardEqualTo(patientInfo.getIdCard());
List<DockPatientBaseInfo> dockPatientBaseInfos = dockPatientBaseInfoMapper.selectByExample(dockPatientBaseInfoExample);
if (CollUtil.isNotEmpty(dockPatientBaseInfos)) {
//存在更新
DockPatientBaseInfo dockPatientBaseInfo = DockDto.PatientInfo.toPatientInfo(patientInfo);
dockPatientBaseInfo.setId(dockPatientBaseInfos.get(0).getId());
dockPatientBaseInfoMapper.updateByPrimaryKeySelective(dockPatientBaseInfo);
//2. 根据就诊流水号查询患者就诊信息是否存在
DockPatientVisitInfoExample dockPatientVisitInfoExample = new DockPatientVisitInfoExample();
dockPatientVisitInfoExample.createCriteria().andVisitNoEqualTo(dto.getVisitInfo().getVisitNo());
List<DockPatientVisitInfo> dockPatientVisitInfos = dockPatientVisitInfoMapper.selectByExample(dockPatientVisitInfoExample);
if (CollUtil.isNotEmpty(dockPatientVisitInfos)) {
//存在删除
DockPatientVisitInfo dockPatientVisitInfo = new DockPatientVisitInfo();
dockPatientVisitInfo.setDelFlag((byte) 1);
dockPatientVisitInfoMapper.updateByExampleSelective(dockPatientVisitInfo, dockPatientVisitInfoExample);
}
//新增
DockPatientVisitInfo dockPatientVisitInfo = DockDto.Jiuzhen.toJiuzhen(dto.getVisitInfo());
dockPatientVisitInfoMapper.insertSelective(dockPatientVisitInfo);
//删除旧的诊断信息和用药信息
DockPatientDiagnosisExample dockPatientDiagnosisExample = new DockPatientDiagnosisExample();
dockPatientDiagnosisExample.createCriteria().andVisitNoEqualTo(dto.getVisitInfo().getVisitNo());
DockPatientDiagnosis dockPatientDiagnosis = new DockPatientDiagnosis();
dockPatientDiagnosis.setDelFlag((byte) 1);
dockPatientDiagnosisMapper.updateByExampleSelective(dockPatientDiagnosis, dockPatientDiagnosisExample);
DockPatientMedicationInfoExample dockPatientMedicationInfoExample = new DockPatientMedicationInfoExample();
dockPatientMedicationInfoExample.createCriteria().andVisitNoEqualTo(dto.getVisitInfo().getVisitNo());
DockPatientMedicationInfo dockPatientMedicationInfo = new DockPatientMedicationInfo();
dockPatientMedicationInfo.setDelFlag((byte) 1);
dockPatientMedicationInfoMapper.updateByExampleSelective(dockPatientMedicationInfo, dockPatientMedicationInfoExample);
//新增诊断信息和用药信息
//新增诊断信息和用药信息
dockDao.bathDiagnosis(dto.getVisitInfo().getDiagnosis());
dockDao.bathMedication(dto.getVisitInfo().getMedications());
} else {
//不存在新增
DockPatientBaseInfo dockPatientBaseInfo = DockDto.PatientInfo.toPatientInfo(patientInfo);
dockPatientBaseInfoMapper.insertSelective(dockPatientBaseInfo);
//新增就诊信息、诊断信息和用药信息
dockDao.bathDiagnosis(dto.getVisitInfo().getDiagnosis());
dockDao.bathMedication(dto.getVisitInfo().getMedications());
}
return 1;
}
@Override
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
public void addDept(DockDto.DockDeptInfo dto) {
DockDept dockDept = BeanUtil.copyProperties(dto, DockDept.class);
dockDeptMapper.insertSelective(dockDept);
}
@Override
public void addEmpl(DockDto.DockEmplInfo dto) {
DockEmpl dockEmpl = BeanUtil.copyProperties(dto, DockEmpl.class);
dockEmplMapper.insertSelective(dockEmpl);
}
@Override
@Transactional(propagation = Propagation.REQUIRED, rollbackFor = Exception.class)
public void pulling(Date startTime, Date endTime) {
//1.判断是否有处于processing状态的操作日志
if (dmsDataValueService.isProcessing()) {
//不允许并发执行
throw new BaseException(ErrorConstant.DCS_RUNNING_ERROR);
}
DmsRunningLog dmsRunningLog = dmsDataValueService.getDmsRunningLogs();
if (dmsRunningLog != null && dmsRunningLog.getLastSyncDate() == null) {
throw new BaseException(ErrorConstant.DcsLogError);
}
Date startDate = null;
Date endDate = null;
Date lastMakeupDate = null;
if (dmsRunningLog != null) {
lastMakeupDate = DateUtil.date(dmsRunningLog.getLastSyncDate());
startDate = dmsRunningLog.getEndTime();
} else {
//从头开始同步
//最后补齐时间为昨天,相当于从今天开始补齐
lastMakeupDate = DateUtil.yesterday();
startDate = DateUtil.yesterday();
}
//最后补齐日期的下一天
// startDate = DateUtil.parse(DateUtil.offset(dmsRunningLog.getEndTime(), DateField.DAY_OF_YEAR, 1).toString(DATE_FORMAT), DATE_FORMAT);
//结束日期总是今天
endDate = DateUtil.parse(DateUtil.date().toString(DATE_FORMAT), DATE_FORMAT);
//5.开始和结束时间修正
if (DateUtil.compare(startDate, DateUtil.date()) > 0) {
startDate = DateUtil.beginOfDay(DateUtil.date());
}
if (DateUtil.compare(endDate, DateUtil.date()) > 0) {
endDate = DateUtil.beginOfDay(DateUtil.date());
}
if (DateUtil.compare(startDate, endDate) > 0) {
throw new BaseException(ErrorConstant.DateRangeError);
}
//业务
makeUp(startTime, endTime);
}
private void makeUp(Date startTime, Date endTime) {
//1.查询上次同步到现在的三方患者信息
DockPatientBaseInfoExample dockPatientBaseInfoExample = new DockPatientBaseInfoExample();
dockPatientBaseInfoExample.createCriteria().andUpdateTimeBetween(startTime, endTime).andDelFlagEqualTo((byte) 0);
List<DockPatientBaseInfo> dockPatientBaseInfos = dockPatientBaseInfoMapper.selectByExample(dockPatientBaseInfoExample);
if (CollUtil.isEmpty(dockPatientBaseInfos)) {
return;
}
for (DockPatientBaseInfo dockPatientBaseInfo : dockPatientBaseInfos) {
//1.根据身份证判断业务系统用户基本信息是否存在
PmsPatientExample pmsPatientExample = new PmsPatientExample();
pmsPatientExample.createCriteria().andIdcardEqualTo(dockPatientBaseInfo.getIdCard()).andDelFlagEqualTo((byte) 0);
List<PmsPatient> pmsPatients = pmsPatientMapper.selectByExample(pmsPatientExample);
if (CollUtil.isNotEmpty(pmsPatients)) {
//查询就诊信息
DockPatientVisitInfoExample dockPatientVisitInfoExample = new DockPatientVisitInfoExample();
dockPatientVisitInfoExample.createCriteria().andIdCardEqualTo(dockPatientBaseInfo.getIdCard());
List<DockPatientVisitInfo> dockPatientVisitInfos = dockPatientVisitInfoMapper.selectByExample(dockPatientVisitInfoExample);
if (CollUtil.isNotEmpty(dockPatientVisitInfos)) {
for (DockPatientVisitInfo dockPatientVisitInfo : dockPatientVisitInfos) {
//2. 查询就诊信息根据就诊流水号查询业务系统患者就诊信息是否存在
PmsPatientBodyExample pmsPatientBodyExample = new PmsPatientBodyExample();
pmsPatientBodyExample.createCriteria().andOutpatientNoEqualTo(dockPatientVisitInfo.getVisitNo()).andDelFlagEqualTo((byte) 0);
List<PmsPatientBody> pmsPatientBodies = pmsPatientBodyMapper.selectByExample(pmsPatientBodyExample);
if (CollUtil.isEmpty(pmsPatientBodies)) {
//不存在新增
PmsPatientBody pmsPatientBody = BeanUtil.copyProperties(dockPatientVisitInfo, PmsPatientBody.class);
pmsPatientBody.setId(IdUtil.getSnowflake().nextId());
pmsPatientBodyMapper.insertSelective(pmsPatientBody);
}
//删除旧的诊断信息和用药信息
PmsPatientDiagnosisExample pmsPatientDiagnosisExample = new PmsPatientDiagnosisExample();
pmsPatientDiagnosisExample.createCriteria().andVisitNoEqualTo(dockPatientVisitInfo.getVisitNo());
PmsPatientDiagnosis pmsPatientDiagnosis = new PmsPatientDiagnosis();
pmsPatientDiagnosis.setDelFlag((byte) 1);
pmsPatientDiagnosisMapper.updateByExampleSelective(pmsPatientDiagnosis, pmsPatientDiagnosisExample);
PmsPatientParentIllnessExample pmsPatientParentIllnessExample = new PmsPatientParentIllnessExample();
pmsPatientParentIllnessExample.createCriteria().andVisitNoEqualTo(dockPatientVisitInfo.getVisitNo());
PmsPatientParentIllness pmsPatientParentIllness = new PmsPatientParentIllness();
pmsPatientParentIllness.setDelFlag((byte) 1);
pmsPatientParentIllnessMapper.updateByExampleSelective(pmsPatientParentIllness, pmsPatientParentIllnessExample);
//新增诊断信息和用药信息
//查询诊断信息
DockPatientDiagnosisExample dockPatientDiagnosisExample = new DockPatientDiagnosisExample();
dockPatientDiagnosisExample.createCriteria().andVisitNoEqualTo(dockPatientVisitInfo.getVisitNo());
List<DockPatientDiagnosis> dockPatientDiagnoses = dockPatientDiagnosisMapper.selectByExample(dockPatientDiagnosisExample);
if (CollUtil.isNotEmpty(dockPatientDiagnoses)) {
List<PmsPatientDiagnosis> pmsPatientDiagnoses = BeanUtil.copyToList(dockPatientDiagnoses, PmsPatientDiagnosis.class);
for (PmsPatientDiagnosis pmsPatientDiagnosis1 : pmsPatientDiagnoses) {
pmsPatientDiagnosis1.setId(IdUtil.getSnowflake().nextId());
pmsPatientDiagnosis1.setPatientId(pmsPatients.get(0).getId());
pmsPatientDiagnosisMapper.insertSelective(pmsPatientDiagnosis1);
}
}
DockPatientMedicationInfoExample dockPatientMedicationInfoExample = new DockPatientMedicationInfoExample();
dockPatientMedicationInfoExample.createCriteria().andVisitNoEqualTo(dockPatientVisitInfo.getVisitNo());
List<DockPatientMedicationInfo> dockPatientMedicationInfos = dockPatientMedicationInfoMapper.selectByExample(dockPatientMedicationInfoExample);
if (CollUtil.isNotEmpty(dockPatientMedicationInfos)) {
List<PmsPatientParentIllness> pmsPatientParentIllnesses = BeanUtil.copyToList(dockPatientMedicationInfos, PmsPatientParentIllness.class);
for (PmsPatientParentIllness pmsPatientParentIllness1 : pmsPatientParentIllnesses) {
pmsPatientParentIllness1.setId(IdUtil.getSnowflake().nextId());
pmsPatientParentIllness1.setPatientId(pmsPatients.get(0).getId());
pmsPatientParentIllnessMapper.insertSelective(pmsPatientParentIllness1);
}
}
}
}
} else {
//不存在新增
PmsPatient pmsPatient = BeanUtil.copyProperties(dockPatientBaseInfo, PmsPatient.class);
pmsPatient.setId(IdUtil.getSnowflake().nextId());
pmsPatientMapper.insertSelective(pmsPatient);
}
}
}
public void syncHospitalData() {
//患者信息
try {
syncPmsPatient();
} catch (Exception e) {
log.error("患者信息同步失败", e);
}
//就诊信息
try {
syncPmsPatientVisitInfo();
} catch (Exception e) {
log.error("就诊信息同步失败", e);
}
//诊断信息
try {
syncPmsPatientDiagnosis();
} catch (Exception e) {
log.error("诊断信息同步失败", e);
}
//用药信息
try {
syncPmsPatientParentIllness();
} catch (Exception e) {
log.error("用药信息同步失败", e);
}
}
@DataSource(value = DataSourceType.MASTER)
@Transactional(propagation = Propagation.REQUIRES_NEW, rollbackFor = Exception.class)
public void syncUmsUserMaster(List<SysUser> sysUsers) {
if (CollUtil.isNotEmpty(sysUsers)) {
for (SysUser sysUser : sysUsers) {
//根据code查找用户
SysUser user = new SysUser();
user.setEmplCode(sysUser.getEmplCode());
List<SysUser> users = sysUserMapper.selectUserList(user);
if (CollUtil.isEmpty(users)) {
sysUser.setDeptId(hospitalId);
sysUserMapper.insertUser(sysUser);
}
}
}
}
// @DataSource(value = DataSourceType.SLAVE)
// @Transactional(propagation = Propagation.REQUIRES_NEW, rollbackFor = Exception.class)
public List<SysUser> syncUmsUserSlave() {
List<SysUser> returnUsers = new ArrayList<>();
DockEmplExample dockEmplExample = new DockEmplExample();
dockEmplExample.createCriteria().andSyncEqualTo("0").andDelFlagEqualTo("0");
List<DockEmpl> dockEmpls = dockEmplMapper.selectByExample(dockEmplExample);
if (CollUtil.isEmpty(dockEmpls)) {
return returnUsers;
}
for (DockEmpl dockEmpl : dockEmpls) {
//根据code查找部门信息
SysDept sysDept = new SysDept();
sysDept.setDeptCode(dockEmpl.getDeptCode());
List<SysDept> sysDepts = sysDeptMapper.selectDeptList(sysDept);
if (CollUtil.isEmpty(sysDepts)) {
continue;
} else {
sysDept = sysDepts.get(0);
}
SysUser sysUser = new SysUser();
sysUser.setEmplCode(dockEmpl.getEmplCode());
List<SysUser> sysUsers = sysUserMapper.selectUserList(sysUser);
if (CollUtil.isEmpty(sysUsers)) {
sysUser.setDeptId(sysDept.getDeptId());
sysUser.setUserName("u_" + dockEmpl.getEmplCode());
sysUser.setNickName(dockEmpl.getEmplName());
sysUser.setEmplCode(dockEmpl.getEmplCode());
sysUser.setPassword(SecurityUtils.encryptPassword(generalPassword));
//获取一年后的日期
sysUser.setValidDate(DateUtil.offset(new Date(), DateField.YEAR, 1));
sysUserMapper.insertUser(sysUser);
// 新增用户与角色管理
SysUserRole ur = new SysUserRole();
ur.setUserId(sysUser.getUserId());
ur.setRoleId(104L);
userRoleMapper.batchUserRole(CollUtil.newArrayList(ur));
returnUsers.add(sysUser);
dockEmpl.setSync("1");
dockEmplMapper.updateByPrimaryKeySelective(dockEmpl);
}
}
return returnUsers;
}
// @DataSource(value = DataSourceType.SLAVE)
// @Transactional(propagation = Propagation.REQUIRES_NEW, rollbackFor = Exception.class)
public List<SysDept> syncUmsDeptSlave() {
List<SysDept> returnDepts = new ArrayList<>();
//查找同步表中的部门信息
DockDeptExample dockDeptExample = new DockDeptExample();
dockDeptExample.createCriteria().andSyncEqualTo("0").andDelFlagEqualTo("0");
List<DockDept> dockDepts = dockDeptMapper.selectByExample(dockDeptExample);
if (CollUtil.isEmpty(dockDepts)) {
return returnDepts;
}
for (DockDept dockDept : dockDepts) {
//根据code查找系统的部门信息
SysDept sysDept = new SysDept();
sysDept.setDeptCode(dockDept.getDeptCode());
List<SysDept> sysDepts = sysDeptMapper.selectDeptList(sysDept);
if (CollUtil.isEmpty(sysDepts)) {
sysDept.setParentId(hospitalId);
sysDept.setAncestors("0," + hospitalId);
sysDept.setDeptName(dockDept.getDeptName());
sysDept.setDeptCode(dockDept.getDeptCode());
sysDeptMapper.insertDept(sysDept);
returnDepts.add(sysDept);
} else {
sysDept = sysDepts.get(0);
sysDept.setParentId(hospitalId);
sysDept.setAncestors("0," + hospitalId);
sysDept.setDeptName(dockDept.getDeptName());
sysDept.setDeptCode(dockDept.getDeptCode());
sysDeptMapper.updateDept(sysDept);
returnDepts.add(sysDept);
}
dockDept.setSync("1");
dockDeptMapper.updateByPrimaryKeySelective(dockDept);
}
return returnDepts;
}
@DataSource(value = DataSourceType.MASTER)
@Transactional(propagation = Propagation.REQUIRES_NEW, rollbackFor = Exception.class)
public void syncUmsDeptMaster(List<SysDept> sysDepts) {
if (CollUtil.isNotEmpty(sysDepts)) {
sysDepts.forEach(sysDept -> {
//根据code查找系统的部门信息
SysDept dept = new SysDept();
dept.setDeptCode(sysDept.getDeptCode());
List<SysDept> depts = sysDeptMapper.selectDeptList(dept);
if (CollUtil.isEmpty(depts)) {
sysDeptMapper.insertDept(sysDept);
} else {
SysDept sysDept1 = depts.get(0);
sysDept.setDeptId(sysDept1.getDeptId());
sysDeptMapper.updateDept(sysDept);
}
});
}
}
private void syncPmsPatient() {
//查找医院下第一个总测评师
List<SysUser> sysUserList = sysUserMapper.getZcpsByHospitalId(hospitalId);
DockPatientBaseInfoExample dockPatientBaseInfoExample = new DockPatientBaseInfoExample();
dockPatientBaseInfoExample.createCriteria().andSyncEqualTo("0").andDelFlagEqualTo((byte) 0);
List<DockPatientBaseInfo> dockPatientBaseInfos = dockPatientBaseInfoMapper.selectByExample(dockPatientBaseInfoExample);
if (CollUtil.isEmpty(dockPatientBaseInfos)) {
return;
}
for (DockPatientBaseInfo dockPatientBaseInfo : dockPatientBaseInfos) {
if (ObjectUtil.isNull(dockPatientBaseInfo.getPatientNo())) {
continue;
}
//根据患者患者唯一编号查询业务表内患者信息
PmsPatient pmsPatient;
PmsPatientExample pmsPatientExample = new PmsPatientExample();
pmsPatientExample.createCriteria().andPatientNoEqualTo(dockPatientBaseInfo.getPatientNo()).andDelFlagEqualTo((byte) 0);
List<PmsPatient> pmsPatients = pmsPatientMapper.selectByExample(pmsPatientExample);
if (CollUtil.isNotEmpty(pmsPatients)) {
//存在就更新
pmsPatient = pmsPatients.get(0);
disposePmsPatient(dockPatientBaseInfo, pmsPatient);
pmsPatient.setHospitalId(hospitalId);
pmsPatient.setUserId(CollUtil.isEmpty(sysUserList) ? null : sysUserList.get(0).getUserId());
pmsPatientMapper.updateByPrimaryKeySelective(pmsPatient);
} else {
//不存在则插入
pmsPatient = new PmsPatient();
pmsPatient.setId(IdUtil.getSnowflake().nextId());
disposePmsPatient(dockPatientBaseInfo, pmsPatient);
pmsPatient.setHospitalId(hospitalId);
pmsPatient.setUserId(CollUtil.isEmpty(sysUserList) ? null : sysUserList.get(0).getUserId());
pmsPatientMapper.insertSelective(pmsPatient);
}
//修改同步表数据的状态
dockPatientBaseInfo.setSync("1");
dockPatientBaseInfoMapper.updateByPrimaryKeySelective(dockPatientBaseInfo);
}
}
private void syncPmsPatientVisitInfo() {
//查询同步表内的就诊信息表
DockPatientVisitInfoExample dockPatientVisitInfoExample = new DockPatientVisitInfoExample();
dockPatientVisitInfoExample.createCriteria().andSyncEqualTo("0");
List<DockPatientVisitInfo> dockPatientVisitInfos = dockPatientVisitInfoMapper.selectByExample(dockPatientVisitInfoExample);
if (CollUtil.isEmpty(dockPatientVisitInfos)) {
return;
}
for (DockPatientVisitInfo dockPatientVisitInfo : dockPatientVisitInfos) {
savePatientBady(dockPatientVisitInfo);
//修改同步表数据的状态
dockPatientVisitInfo.setSync("1");
dockPatientVisitInfoMapper.updateByPrimaryKeySelective(dockPatientVisitInfo);
}
}
private PmsPatientBody savePatientBady(DockPatientVisitInfo dockPatientVisitInfo) {
//根据医生和部门信息查找业务表内对应的医生账号和部门id
String doctorName = "";
Long deptId = null;
//医生用户名
String doctor = dockPatientVisitInfo.getDoctor();
if (StrUtil.isNotEmpty(doctor)) {
String[] split = doctor.split("/");
if (split.length > 1) {
SysUser sysUser = new SysUser();
sysUser.setEmplCode(split[1]);
List<SysUser> sysUsers = sysUserMapper.selectUserList(sysUser);
if (CollUtil.isNotEmpty(sysUsers)) {
doctorName = sysUsers.get(0).getUserName();
}
}
}
//部门id
if (StrUtil.isNotEmpty(dockPatientVisitInfo.getDepartment())) {
SysDept sysDept = new SysDept();
sysDept.setDeptName(dockPatientVisitInfo.getDepartment());
List<SysDept> sysDepts = sysDeptMapper.selectDeptList(sysDept);
if (CollUtil.isNotEmpty(sysDepts)) {
deptId = sysDepts.get(0).getDeptId();
}
}
//根据患者唯一编号查找业务表内患者信息
PmsPatient pmsPatient;
PmsPatientExample pmsPatientExample = new PmsPatientExample();
pmsPatientExample.createCriteria().andPatientNoEqualTo(dockPatientVisitInfo.getPatientNo()).andDelFlagEqualTo((byte) 0);
List<PmsPatient> pmsPatients = pmsPatientMapper.selectByExample(pmsPatientExample);
if (CollUtil.isEmpty(pmsPatients)) {
//根据患者唯一编号查找同步表的患者信息
DockPatientBaseInfoExample dockPatientBaseInfoExample = new DockPatientBaseInfoExample();
dockPatientBaseInfoExample.createCriteria().andPatientNoEqualTo(dockPatientVisitInfo.getPatientNo()).andDelFlagEqualTo((byte) 0);
List<DockPatientBaseInfo> dockPatientBaseInfos = dockPatientBaseInfoMapper.selectByExample(dockPatientBaseInfoExample);
if (CollUtil.isNotEmpty(dockPatientBaseInfos)) {
//存在则更新
pmsPatient = new PmsPatient();
pmsPatient.setId(IdUtil.getSnowflake().nextId());
disposePmsPatient(dockPatientBaseInfos.get(0), pmsPatient);
//更新患者所属的部门和创建者信息,暂不考虑其他,每次都更新
pmsPatient.setHospitalId(ObjectUtil.isNull(deptId) ? hospitalId : deptId);
if (StrUtil.isNotEmpty(doctorName)) {
pmsPatient.setCreateBy(doctorName);
}
pmsPatientMapper.insertSelective(pmsPatient);
} else {
//不存在表示患者确实不存在,直接跳过这个就诊信息
return null;
}
} else {
pmsPatient = pmsPatients.get(0);
//更新患者所属的部门和创建者信息,暂不考虑其他,每次都更新
pmsPatient.setHospitalId(ObjectUtil.isNull(deptId) ? hospitalId : deptId);
if (StrUtil.isNotEmpty(doctorName)) {
pmsPatient.setCreateBy(doctorName);
}
pmsPatientMapper.updateByPrimaryKeySelective(pmsPatient);
}
//根据就诊流水号查询业务表内患者就诊信息
PmsPatientBody pmsPatientBody;
PmsPatientBodyExample pmsPatientBodyExample = new PmsPatientBodyExample();
pmsPatientBodyExample.createCriteria().andOutpatientNoEqualTo(dockPatientVisitInfo.getVisitNo()).andDelFlagEqualTo((byte) 0);
List<PmsPatientBody> pmsPatientBodies = pmsPatientBodyMapper.selectByExample(pmsPatientBodyExample);
if (CollUtil.isNotEmpty(pmsPatientBodies)) {
pmsPatientBody = pmsPatientBodies.get(0);
pmsPatientBody.setPatientId(pmsPatient.getId());
disposePmsPatientBody(dockPatientVisitInfo, pmsPatientBody);
pmsPatientBodyMapper.updateByPrimaryKeySelective(pmsPatientBody);
} else {
pmsPatientBody = new PmsPatientBody();
pmsPatientBody.setId(IdUtil.getSnowflake().nextId());
pmsPatientBody.setPatientId(pmsPatient.getId());
disposePmsPatientBody(dockPatientVisitInfo, pmsPatientBody);
pmsPatientBodyMapper.insertSelective(pmsPatientBody);
}
return pmsPatientBody;
}
private void syncPmsPatientDiagnosis() {
//查找同步表的诊断信息
DockPatientDiagnosisExample dockPatientDiagnosisExample = new DockPatientDiagnosisExample();
dockPatientDiagnosisExample.createCriteria().andSyncEqualTo("0");
List<DockPatientDiagnosis> dockPatientDiagnosiss = dockPatientDiagnosisMapper.selectByExample(dockPatientDiagnosisExample);
if (CollUtil.isEmpty(dockPatientDiagnosiss)) {
return;
}
//将诊断数据根据就诊流水号进行分组
Map<String, List<DockPatientDiagnosis>> dockPatientDiagnosisMap = dockPatientDiagnosiss.stream().collect(Collectors.groupingBy(DockPatientDiagnosis::getVisitNo));
for (String key : dockPatientDiagnosisMap.keySet()) {
//根据就诊流水号查找业务表内患者就诊信息
PmsPatientBody pmsPatientBody;
PmsPatientBodyExample pmsPatientBodyExample = new PmsPatientBodyExample();
pmsPatientBodyExample.createCriteria().andOutpatientNoEqualTo(key).andDelFlagEqualTo((byte) 0);
List<PmsPatientBody> pmsPatientBodies = pmsPatientBodyMapper.selectByExample(pmsPatientBodyExample);
if (CollUtil.isNotEmpty(pmsPatientBodies)) {
pmsPatientBody = pmsPatientBodies.get(0);
} else {
//不存在则查找同步表的就诊信息
DockPatientVisitInfoExample dockPatientVisitInfoExample = new DockPatientVisitInfoExample();
dockPatientVisitInfoExample.createCriteria().andVisitNoEqualTo(key).andDelFlagEqualTo((byte) 0);
List<DockPatientVisitInfo> dockPatientVisitInfos = dockPatientVisitInfoMapper.selectByExample(dockPatientVisitInfoExample);
if (CollUtil.isNotEmpty(dockPatientVisitInfos)) {
pmsPatientBody = savePatientBady(dockPatientVisitInfos.get(0));
if (pmsPatientBody == null) {
continue;
}
} else {
//不存在则跳过
continue;
}
}
//根据流水号删除业务表内的旧数据
PmsPatientDiagnosisExample pmsPatientDiagnosisExample = new PmsPatientDiagnosisExample();
pmsPatientDiagnosisExample.createCriteria().andVisitNoEqualTo(key);
pmsPatientDiagnosisMapper.deleteByExample(pmsPatientDiagnosisExample);
for (DockPatientDiagnosis dockPatientDiagnosis : dockPatientDiagnosisMap.get(key)) {
//添加业务表
PmsPatientDiagnosis pmsPatientDiagnosis = new PmsPatientDiagnosis();
pmsPatientDiagnosis.setId(IdUtil.getSnowflake().nextId());
pmsPatientDiagnosis.setPatientId(pmsPatientBody.getPatientId());
pmsPatientDiagnosis.setVisitNo(dockPatientDiagnosis.getVisitNo());
pmsPatientDiagnosis.setDiagnosisType(dockPatientDiagnosis.getDiagnosisType());
pmsPatientDiagnosis.setIsMainDiagnosis(ObjectUtil.isNull(dockPatientDiagnosis.getIsMainDiagnosis()) ? "0" : dockPatientDiagnosis.getIsMainDiagnosis().toString());
pmsPatientDiagnosis.setDiagnosisCode(dockPatientDiagnosis.getDiagnosisCode());
pmsPatientDiagnosis.setDiagnosisName(dockPatientDiagnosis.getDiagnosisName());
pmsPatientDiagnosis.setDiagnosisDate(DateUtil.format(dockPatientDiagnosis.getDiagnosisDate(), "yyyy-MM-dd HH:mm:ss"));
pmsPatientDiagnosisMapper.insertSelective(pmsPatientDiagnosis);
dockPatientDiagnosis.setSync("1");
dockPatientDiagnosisMapper.updateByPrimaryKeySelective(dockPatientDiagnosis);
}
}
}
private void syncPmsPatientParentIllness() {
//查找同步表的疾病信息
DockPatientMedicationInfoExample dockPatientMedicationInfoExample = new DockPatientMedicationInfoExample();
dockPatientMedicationInfoExample.createCriteria().andSyncEqualTo("0");
List<DockPatientMedicationInfo> dockPatientMedicationInfos = dockPatientMedicationInfoMapper.selectByExample(dockPatientMedicationInfoExample);
if (CollUtil.isEmpty(dockPatientMedicationInfos)) {
return;
}
//将疾病信息根据就诊流水号进行分组
Map<String, List<DockPatientMedicationInfo>> dockPatientMedicationInfoMap = dockPatientMedicationInfos.stream().collect(Collectors.groupingBy(DockPatientMedicationInfo::getVisitNo));
for (String key : dockPatientMedicationInfoMap.keySet()) {
//根据就诊流水号查找业务表内患者就诊信息
PmsPatientBody pmsPatientBody;
PmsPatientBodyExample pmsPatientBodyExample = new PmsPatientBodyExample();
pmsPatientBodyExample.createCriteria().andOutpatientNoEqualTo(key).andDelFlagEqualTo((byte) 0);
List<PmsPatientBody> pmsPatientBodies = pmsPatientBodyMapper.selectByExample(pmsPatientBodyExample);
if (CollUtil.isNotEmpty(pmsPatientBodies)) {
pmsPatientBody = pmsPatientBodies.get(0);
} else {
//不存在则查找同步表的就诊信息
DockPatientVisitInfoExample dockPatientVisitInfoExample = new DockPatientVisitInfoExample();
dockPatientVisitInfoExample.createCriteria().andVisitNoEqualTo(key).andDelFlagEqualTo((byte) 0);
List<DockPatientVisitInfo> dockPatientVisitInfos = dockPatientVisitInfoMapper.selectByExample(dockPatientVisitInfoExample);
if (CollUtil.isNotEmpty(dockPatientVisitInfos)) {
pmsPatientBody = savePatientBady(dockPatientVisitInfos.get(0));
if (pmsPatientBody == null) {
continue;
}
} else {
//不存在则跳过
continue;
}
}
//根据流水号删除业务表内的旧数据
PmsPatientParentIllnessExample pmsPatientParentIllnessExample = new PmsPatientParentIllnessExample();
pmsPatientParentIllnessExample.createCriteria().andVisitNoEqualTo(key);
pmsPatientParentIllnessMapper.deleteByExample(pmsPatientParentIllnessExample);
for (DockPatientMedicationInfo dockPatientMedicationInfo : dockPatientMedicationInfoMap.get(key)) {
PmsPatientParentIllness pmsPatientParentIllness = new PmsPatientParentIllness();
pmsPatientParentIllness.setId(IdUtil.getSnowflake().nextId());
pmsPatientParentIllness.setPatientId(pmsPatientBody.getPatientId());
pmsPatientParentIllness.setVisitNo(dockPatientMedicationInfo.getVisitNo());
pmsPatientParentIllness.setDrugName(dockPatientMedicationInfo.getDrugName());
pmsPatientParentIllness.setDose(ObjectUtil.isNull(dockPatientMedicationInfo.getDose()) ? "" : dockPatientMedicationInfo.getDose().toString());
pmsPatientParentIllness.setUnit(dockPatientMedicationInfo.getUnit());
pmsPatientParentIllness.setFrequency(dockPatientMedicationInfo.getFrequency());
pmsPatientParentIllnessMapper.insertSelective(pmsPatientParentIllness);
//修改同步表数据的状态
dockPatientMedicationInfo.setSync("1");
dockPatientMedicationInfoMapper.updateByPrimaryKeySelective(dockPatientMedicationInfo);
}
}
}
private void disposePmsPatientBody(DockPatientVisitInfo dockPatientVisitInfo, PmsPatientBody pmsPatientBody) {
pmsPatientBody.setVisitType(dockPatientVisitInfo.getVisitType());
pmsPatientBody.setOutpatientNo(dockPatientVisitInfo.getVisitNo());
pmsPatientBody.setAge(dockPatientVisitInfo.getAge() != null ? String.valueOf(dockPatientVisitInfo.getAge()) : null);
pmsPatientBody.setDepartment(dockPatientVisitInfo.getDepartment());
pmsPatientBody.setDoctor(dockPatientVisitInfo.getDoctor());
// 入院信息
pmsPatientBody.setAdmissionDate(dockPatientVisitInfo.getAdmissionDate() != null ? dockPatientVisitInfo.getAdmissionDate().toString() : null);
pmsPatientBody.setAdmissionCount(dockPatientVisitInfo.getAdmissionCount() != null ? String.valueOf(dockPatientVisitInfo.getAdmissionCount()) : null);
pmsPatientBody.setAdmissionMethod(dockPatientVisitInfo.getAdmissionMethod());
pmsPatientBody.setBedNumber(dockPatientVisitInfo.getBedNumber());
pmsPatientBody.setDischargeDate(dockPatientVisitInfo.getDischargeDate() != null ? dockPatientVisitInfo.getDischargeDate().toString() : null);
pmsPatientBody.setDischargeMethod(dockPatientVisitInfo.getDischargeMethod());
// 身体指标
pmsPatientBody.setHeight(dockPatientVisitInfo.getHeight() != null ? String.valueOf(dockPatientVisitInfo.getHeight()) : null);
pmsPatientBody.setWeight(dockPatientVisitInfo.getWeight() != null ? String.valueOf(dockPatientVisitInfo.getWeight()) : null);
pmsPatientBody.setTz(dockPatientVisitInfo.getTz() != null ? String.valueOf(dockPatientVisitInfo.getTz()) : null);
pmsPatientBody.setTemperature(dockPatientVisitInfo.getTemperature() != null ? String.valueOf(dockPatientVisitInfo.getTemperature()) : null);
pmsPatientBody.setBloodPressureShrink(dockPatientVisitInfo.getBloodPressureShrink() != null ? String.valueOf(dockPatientVisitInfo.getBloodPressureShrink()) : null);
pmsPatientBody.setBloodPressureDiastole(dockPatientVisitInfo.getBloodPressureDiastole() != null ? String.valueOf(dockPatientVisitInfo.getBloodPressureDiastole()) : null);
pmsPatientBody.setPulse(dockPatientVisitInfo.getPulse() != null ? String.valueOf(dockPatientVisitInfo.getPulse()) : null);
// 化验指标
pmsPatientBody.setCreatinine(dockPatientVisitInfo.getCreatinine() != null ? String.valueOf(dockPatientVisitInfo.getCreatinine()) : null);
pmsPatientBody.setOxygenSaturation(dockPatientVisitInfo.getOxygenSaturation() != null ? String.valueOf(dockPatientVisitInfo.getOxygenSaturation()) : null);
pmsPatientBody.setAlbumin(dockPatientVisitInfo.getAlbumin() != null ? String.valueOf(dockPatientVisitInfo.getAlbumin()) : null);
pmsPatientBody.setTotalProtein(dockPatientVisitInfo.getTotalProtein() != null ? String.valueOf(dockPatientVisitInfo.getTotalProtein()) : null);
pmsPatientBody.setVitaminD3(dockPatientVisitInfo.getVitaminD3() != null ? String.valueOf(dockPatientVisitInfo.getVitaminD3()) : null);
pmsPatientBody.setHematocrit(dockPatientVisitInfo.getHematocrit() != null ? String.valueOf(dockPatientVisitInfo.getHematocrit()) : null);
pmsPatientBody.setDimer(dockPatientVisitInfo.getDimer() != null ? String.valueOf(dockPatientVisitInfo.getDimer()) : null);
}
private void disposePmsPatient(DockPatientBaseInfo dockPatientBaseInfo, PmsPatient pmsPatient) {
pmsPatient.setPatientNo(dockPatientBaseInfo.getPatientNo());
// 姓名相关
pmsPatient.setName(dockPatientBaseInfo.getName());
pmsPatient.setNameFull(PinyinUtil.getPinyin(pmsPatient.getName(), ""));
pmsPatient.setNameInitial(PinyinUtil.getFirstLetter(pmsPatient.getName(), ""));
// 证件信息
pmsPatient.setIdcard(dockPatientBaseInfo.getIdCard());
pmsPatient.setPhone(dockPatientBaseInfo.getPhone());
pmsPatient.setMobile(dockPatientBaseInfo.getPhone());
// 性别转换:将"男"/"女"转换为 0/1
String sex = dockPatientBaseInfo.getSex();
if ("男".equals(sex)) {
pmsPatient.setSex((byte) 0);
} else if ("女".equals(sex)) {
pmsPatient.setSex((byte) 1);
} else {
// 如果已经有数字代码,直接转换
try {
pmsPatient.setSex(Byte.parseByte(sex));
} catch (NumberFormatException e) {
pmsPatient.setSex((byte) 0); // 默认值
}
}
// 出生日期
pmsPatient.setBirthday(DateUtil.format(dockPatientBaseInfo.getBirthday(), "yyyy-MM-dd"));
// 教育程度转换
String educationalStatus = dockPatientBaseInfo.getEducationalStatus();
if ("文盲".equals(educationalStatus)) {
pmsPatient.setEducationalStatus((byte) 1);
} else if ("小学".equals(educationalStatus)) {
pmsPatient.setEducationalStatus((byte) 2);
} else if ("初中".equals(educationalStatus)) {
pmsPatient.setEducationalStatus((byte) 3);
} else if ("高中".equals(educationalStatus)) {
pmsPatient.setEducationalStatus((byte) 4);
} else if ("大学".equals(educationalStatus)) {
pmsPatient.setEducationalStatus((byte) 5);
} else if ("大学以上".equals(educationalStatus)) {
pmsPatient.setEducationalStatus((byte) 6);
} else if ("其他".equals(educationalStatus)) {
pmsPatient.setEducationalStatus((byte) 7);
} else {
try {
pmsPatient.setEducationalStatus(Byte.parseByte(educationalStatus));
} catch (NumberFormatException e) {
pmsPatient.setEducationalStatus((byte) 7); // 默认其他
}
}
// 职业转换
String career = dockPatientBaseInfo.getCareer();
if ("农林牧渔水利生产人员".equals(career)) {
pmsPatient.setCareer((byte) 1);
} else if ("教师".equals(career)) {
pmsPatient.setCareer((byte) 2);
} else if ("医务工作者".equals(career)) {
pmsPatient.setCareer((byte) 3);
} else if ("专业技术人员".equals(career)) {
pmsPatient.setCareer((byte) 4);
} else if ("生产、运输设备操作人员及有关人员".equals(career)) {
pmsPatient.setCareer((byte) 5);
} else if ("商业、服务业人员".equals(career)) {
pmsPatient.setCareer((byte) 6);
} else if ("国家机关、事业单位、企业负责人".equals(career)) {
pmsPatient.setCareer((byte) 7);
} else if ("国家机关、事业单位、企业办事人员和有关人员".equals(career)) {
pmsPatient.setCareer((byte) 8);
} else if ("军人".equals(career)) {
pmsPatient.setCareer((byte) 9);
} else if ("媒体、文体类工作人员".equals(career)) {
pmsPatient.setCareer((byte) 10);
} else if ("在校学生".equals(career)) {
pmsPatient.setCareer((byte) 11);
} else if ("未就业".equals(career)) {
pmsPatient.setCareer((byte) 12);
} else if ("家务".equals(career)) {
pmsPatient.setCareer((byte) 13);
} else if ("其他".equals(career)) {
pmsPatient.setCareer((byte) 14);
} else {
try {
pmsPatient.setCareer(Byte.parseByte(career));
} catch (NumberFormatException e) {
pmsPatient.setCareer(null);
}
}
// 婚姻状况转换
String maritalStatus = dockPatientBaseInfo.getMaritalStatus();
if ("未婚".equals(maritalStatus)) {
pmsPatient.setMaritalStatus((byte) 1);
} else if ("已婚".equals(maritalStatus)) {
pmsPatient.setMaritalStatus((byte) 2);
} else if ("离异".equals(maritalStatus)) {
pmsPatient.setMaritalStatus((byte) 3);
} else if ("分居".equals(maritalStatus)) {
pmsPatient.setMaritalStatus((byte) 4);
} else if ("丧偶".equals(maritalStatus)) {
pmsPatient.setMaritalStatus((byte) 5);
} else if ("同居".equals(maritalStatus)) {
pmsPatient.setMaritalStatus((byte) 6);
} else if ("其他".equals(maritalStatus)) {
pmsPatient.setMaritalStatus((byte) 7);
} else {
try {
pmsPatient.setMaritalStatus(Byte.parseByte(maritalStatus));
} catch (NumberFormatException e) {
pmsPatient.setMaritalStatus(null);
}
}
// 其他字段直接设置
pmsPatient.setNation(dockPatientBaseInfo.getNation());
pmsPatient.setNativePlace(dockPatientBaseInfo.getNativePlace());
pmsPatient.setAddress(dockPatientBaseInfo.getAddress());
// 居住状态转换
String dwellingState = dockPatientBaseInfo.getDwellingState();
if ("独居".equals(dwellingState)) {
pmsPatient.setDwellingState((byte) 1);
} else if ("与配偶或对象或子女".equals(dwellingState)) {
pmsPatient.setDwellingState((byte) 2);
} else if ("与亲戚或朋友居住".equals(dwellingState)) {
pmsPatient.setDwellingState((byte) 3);
} else {
try {
pmsPatient.setDwellingState(Byte.parseByte(dwellingState));
} catch (NumberFormatException e) {
pmsPatient.setDwellingState(null);
}
}
// 联系人信息
pmsPatient.setContactName(dockPatientBaseInfo.getContactName());
pmsPatient.setContactMobile(dockPatientBaseInfo.getContactMobile());
pmsPatient.setContactRelation(dockPatientBaseInfo.getContactRelation());
// 血型信息
pmsPatient.setAboBloodType(dockPatientBaseInfo.getAboBloodType());
pmsPatient.setRhBloodType(dockPatientBaseInfo.getRhBloodType());
// 其他信息
pmsPatient.setBelief(dockPatientBaseInfo.getBelief());
pmsPatient.setHobby(dockPatientBaseInfo.getHobby());
}
}

30
ruisi_java/ruisi-system/src/main/resources/mapper/dao/DockDao.xml

@ -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.ccsens.system.persist.dao.DockDao">
<insert id="bathDiagnosis">
insert into dock_patient_diagnosis (id, visit_no, diagnosis_type,
is_main_diagnosis, diagnosis_name, diagnosis_code,
diagnosis_date)
values
<foreach collection="diagnosis" item="item" open="" separator="," close="">
(#{item.id,jdbcType=BIGINT}, #{item.visitNo,jdbcType=VARCHAR}, #{item.diagnosisType,jdbcType=VARCHAR},
#{item.isMainDiagnosis,jdbcType=TINYINT}, #{item.diagnosisName,jdbcType=VARCHAR},
#{item.diagnosisCode,jdbcType=VARCHAR},
#{item.diagnosisDate,jdbcType=DATE}
)
</foreach>
</insert>
<insert id="bathMedication">
insert into dock_patient_medication_info (id, visit_no, drug_name,
dose, unit, frequency
)
values
<foreach collection="medication" item="item" open="" separator="," close="">
(#{item.id,jdbcType=BIGINT}, #{item.visitNo,jdbcType=VARCHAR}, #{item.drugName,jdbcType=VARCHAR},
#{item.dose,jdbcType=DECIMAL}, #{item.unit,jdbcType=VARCHAR}, #{item.frequency,jdbcType=VARCHAR}
)
</foreach>
</insert>
</mapper>

338
ruisi_java/ruisi-system/src/main/resources/mapper/system/DmsRunningLogMapper.xml

@ -0,0 +1,338 @@
<?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.ccsens.system.persist.mapper.DmsRunningLogMapper">
<resultMap id="BaseResultMap" type="com.ccsens.system.domain.po.DmsRunningLog">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="start_time" jdbcType="TIMESTAMP" property="startTime" />
<result column="end_time" jdbcType="TIMESTAMP" property="endTime" />
<result column="sync_records" jdbcType="BIGINT" property="syncRecords" />
<result column="sync_seconds" jdbcType="BIGINT" property="syncSeconds" />
<result column="last_sync_date" jdbcType="TIMESTAMP" property="lastSyncDate" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="status" jdbcType="TINYINT" property="status" />
<result column="created_at" jdbcType="TIMESTAMP" property="createdAt" />
<result column="updated_at" jdbcType="TIMESTAMP" property="updatedAt" />
<result column="created_by" jdbcType="VARCHAR" property="createdBy" />
<result column="updated_by" jdbcType="VARCHAR" property="updatedBy" />
<result column="del_status" jdbcType="TINYINT" property="delStatus" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
id, start_time, end_time, sync_records, sync_seconds, last_sync_date, remark, status,
created_at, updated_at, created_by, updated_by, del_status
</sql>
<select id="selectByExample" parameterType="com.ccsens.system.domain.po.DmsRunningLogExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from dms_running_log
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from dms_running_log
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from dms_running_log
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.ccsens.system.domain.po.DmsRunningLogExample">
delete from dms_running_log
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.ccsens.system.domain.po.DmsRunningLog">
insert into dms_running_log (id, start_time, end_time,
sync_records, sync_seconds, last_sync_date,
remark, status, created_at,
updated_at, created_by, updated_by,
del_status)
values (#{id,jdbcType=BIGINT}, #{startTime,jdbcType=TIMESTAMP}, #{endTime,jdbcType=TIMESTAMP},
#{syncRecords,jdbcType=BIGINT}, #{syncSeconds,jdbcType=BIGINT}, #{lastSyncDate,jdbcType=TIMESTAMP},
#{remark,jdbcType=VARCHAR}, #{status,jdbcType=TINYINT}, #{createdAt,jdbcType=TIMESTAMP},
#{updatedAt,jdbcType=TIMESTAMP}, #{createdBy,jdbcType=VARCHAR}, #{updatedBy,jdbcType=VARCHAR},
#{delStatus,jdbcType=TINYINT})
</insert>
<insert id="insertSelective" parameterType="com.ccsens.system.domain.po.DmsRunningLog">
insert into dms_running_log
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="startTime != null">
start_time,
</if>
<if test="endTime != null">
end_time,
</if>
<if test="syncRecords != null">
sync_records,
</if>
<if test="syncSeconds != null">
sync_seconds,
</if>
<if test="lastSyncDate != null">
last_sync_date,
</if>
<if test="remark != null">
remark,
</if>
<if test="status != null">
status,
</if>
<if test="createdAt != null">
created_at,
</if>
<if test="updatedAt != null">
updated_at,
</if>
<if test="createdBy != null">
created_by,
</if>
<if test="updatedBy != null">
updated_by,
</if>
<if test="delStatus != null">
del_status,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="startTime != null">
#{startTime,jdbcType=TIMESTAMP},
</if>
<if test="endTime != null">
#{endTime,jdbcType=TIMESTAMP},
</if>
<if test="syncRecords != null">
#{syncRecords,jdbcType=BIGINT},
</if>
<if test="syncSeconds != null">
#{syncSeconds,jdbcType=BIGINT},
</if>
<if test="lastSyncDate != null">
#{lastSyncDate,jdbcType=TIMESTAMP},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=TINYINT},
</if>
<if test="createdAt != null">
#{createdAt,jdbcType=TIMESTAMP},
</if>
<if test="updatedAt != null">
#{updatedAt,jdbcType=TIMESTAMP},
</if>
<if test="createdBy != null">
#{createdBy,jdbcType=VARCHAR},
</if>
<if test="updatedBy != null">
#{updatedBy,jdbcType=VARCHAR},
</if>
<if test="delStatus != null">
#{delStatus,jdbcType=TINYINT},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.ccsens.system.domain.po.DmsRunningLogExample" resultType="java.lang.Long">
select count(*) from dms_running_log
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update dms_running_log
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.startTime != null">
start_time = #{record.startTime,jdbcType=TIMESTAMP},
</if>
<if test="record.endTime != null">
end_time = #{record.endTime,jdbcType=TIMESTAMP},
</if>
<if test="record.syncRecords != null">
sync_records = #{record.syncRecords,jdbcType=BIGINT},
</if>
<if test="record.syncSeconds != null">
sync_seconds = #{record.syncSeconds,jdbcType=BIGINT},
</if>
<if test="record.lastSyncDate != null">
last_sync_date = #{record.lastSyncDate,jdbcType=TIMESTAMP},
</if>
<if test="record.remark != null">
remark = #{record.remark,jdbcType=VARCHAR},
</if>
<if test="record.status != null">
status = #{record.status,jdbcType=TINYINT},
</if>
<if test="record.createdAt != null">
created_at = #{record.createdAt,jdbcType=TIMESTAMP},
</if>
<if test="record.updatedAt != null">
updated_at = #{record.updatedAt,jdbcType=TIMESTAMP},
</if>
<if test="record.createdBy != null">
created_by = #{record.createdBy,jdbcType=VARCHAR},
</if>
<if test="record.updatedBy != null">
updated_by = #{record.updatedBy,jdbcType=VARCHAR},
</if>
<if test="record.delStatus != null">
del_status = #{record.delStatus,jdbcType=TINYINT},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update dms_running_log
set id = #{record.id,jdbcType=BIGINT},
start_time = #{record.startTime,jdbcType=TIMESTAMP},
end_time = #{record.endTime,jdbcType=TIMESTAMP},
sync_records = #{record.syncRecords,jdbcType=BIGINT},
sync_seconds = #{record.syncSeconds,jdbcType=BIGINT},
last_sync_date = #{record.lastSyncDate,jdbcType=TIMESTAMP},
remark = #{record.remark,jdbcType=VARCHAR},
status = #{record.status,jdbcType=TINYINT},
created_at = #{record.createdAt,jdbcType=TIMESTAMP},
updated_at = #{record.updatedAt,jdbcType=TIMESTAMP},
created_by = #{record.createdBy,jdbcType=VARCHAR},
updated_by = #{record.updatedBy,jdbcType=VARCHAR},
del_status = #{record.delStatus,jdbcType=TINYINT}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.system.domain.po.DmsRunningLog">
update dms_running_log
<set>
<if test="startTime != null">
start_time = #{startTime,jdbcType=TIMESTAMP},
</if>
<if test="endTime != null">
end_time = #{endTime,jdbcType=TIMESTAMP},
</if>
<if test="syncRecords != null">
sync_records = #{syncRecords,jdbcType=BIGINT},
</if>
<if test="syncSeconds != null">
sync_seconds = #{syncSeconds,jdbcType=BIGINT},
</if>
<if test="lastSyncDate != null">
last_sync_date = #{lastSyncDate,jdbcType=TIMESTAMP},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=TINYINT},
</if>
<if test="createdAt != null">
created_at = #{createdAt,jdbcType=TIMESTAMP},
</if>
<if test="updatedAt != null">
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
</if>
<if test="createdBy != null">
created_by = #{createdBy,jdbcType=VARCHAR},
</if>
<if test="updatedBy != null">
updated_by = #{updatedBy,jdbcType=VARCHAR},
</if>
<if test="delStatus != null">
del_status = #{delStatus,jdbcType=TINYINT},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.ccsens.system.domain.po.DmsRunningLog">
update dms_running_log
set start_time = #{startTime,jdbcType=TIMESTAMP},
end_time = #{endTime,jdbcType=TIMESTAMP},
sync_records = #{syncRecords,jdbcType=BIGINT},
sync_seconds = #{syncSeconds,jdbcType=BIGINT},
last_sync_date = #{lastSyncDate,jdbcType=TIMESTAMP},
remark = #{remark,jdbcType=VARCHAR},
status = #{status,jdbcType=TINYINT},
created_at = #{createdAt,jdbcType=TIMESTAMP},
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
created_by = #{createdBy,jdbcType=VARCHAR},
updated_by = #{updatedBy,jdbcType=VARCHAR},
del_status = #{delStatus,jdbcType=TINYINT}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>

276
ruisi_java/ruisi-system/src/main/resources/mapper/system/DockDeptMapper.xml

@ -0,0 +1,276 @@
<?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.ccsens.system.persist.mapper.DockDeptMapper">
<resultMap id="BaseResultMap" type="com.ccsens.system.domain.po.DockDept">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="dept_name" jdbcType="VARCHAR" property="deptName" />
<result column="dept_code" jdbcType="VARCHAR" property="deptCode" />
<result column="del_flag" jdbcType="CHAR" property="delFlag" />
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="sync" jdbcType="VARCHAR" property="sync" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
id, dept_name, dept_code, del_flag, create_by, create_time, update_by, update_time,
sync
</sql>
<select id="selectByExample" parameterType="com.ccsens.system.domain.po.DockDeptExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from dock_dept
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from dock_dept
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from dock_dept
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.ccsens.system.domain.po.DockDeptExample">
delete from dock_dept
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.ccsens.system.domain.po.DockDept">
insert into dock_dept (id, dept_name, dept_code,
del_flag, create_by, create_time,
update_by, update_time, sync
)
values (#{id,jdbcType=BIGINT}, #{deptName,jdbcType=VARCHAR}, #{deptCode,jdbcType=VARCHAR},
#{delFlag,jdbcType=CHAR}, #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
#{updateBy,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{sync,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.ccsens.system.domain.po.DockDept">
insert into dock_dept
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="deptName != null">
dept_name,
</if>
<if test="deptCode != null">
dept_code,
</if>
<if test="delFlag != null">
del_flag,
</if>
<if test="createBy != null">
create_by,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateBy != null">
update_by,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="sync != null">
sync,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="deptName != null">
#{deptName,jdbcType=VARCHAR},
</if>
<if test="deptCode != null">
#{deptCode,jdbcType=VARCHAR},
</if>
<if test="delFlag != null">
#{delFlag,jdbcType=CHAR},
</if>
<if test="createBy != null">
#{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
#{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="sync != null">
#{sync,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.ccsens.system.domain.po.DockDeptExample" resultType="java.lang.Long">
select count(*) from dock_dept
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update dock_dept
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.deptName != null">
dept_name = #{record.deptName,jdbcType=VARCHAR},
</if>
<if test="record.deptCode != null">
dept_code = #{record.deptCode,jdbcType=VARCHAR},
</if>
<if test="record.delFlag != null">
del_flag = #{record.delFlag,jdbcType=CHAR},
</if>
<if test="record.createBy != null">
create_by = #{record.createBy,jdbcType=VARCHAR},
</if>
<if test="record.createTime != null">
create_time = #{record.createTime,jdbcType=TIMESTAMP},
</if>
<if test="record.updateBy != null">
update_by = #{record.updateBy,jdbcType=VARCHAR},
</if>
<if test="record.updateTime != null">
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
</if>
<if test="record.sync != null">
sync = #{record.sync,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update dock_dept
set id = #{record.id,jdbcType=BIGINT},
dept_name = #{record.deptName,jdbcType=VARCHAR},
dept_code = #{record.deptCode,jdbcType=VARCHAR},
del_flag = #{record.delFlag,jdbcType=CHAR},
create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_by = #{record.updateBy,jdbcType=VARCHAR},
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
sync = #{record.sync,jdbcType=VARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.system.domain.po.DockDept">
update dock_dept
<set>
<if test="deptName != null">
dept_name = #{deptName,jdbcType=VARCHAR},
</if>
<if test="deptCode != null">
dept_code = #{deptCode,jdbcType=VARCHAR},
</if>
<if test="delFlag != null">
del_flag = #{delFlag,jdbcType=CHAR},
</if>
<if test="createBy != null">
create_by = #{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
update_by = #{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="sync != null">
sync = #{sync,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.ccsens.system.domain.po.DockDept">
update dock_dept
set dept_name = #{deptName,jdbcType=VARCHAR},
dept_code = #{deptCode,jdbcType=VARCHAR},
del_flag = #{delFlag,jdbcType=CHAR},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
sync = #{sync,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>

306
ruisi_java/ruisi-system/src/main/resources/mapper/system/DockEmplMapper.xml

@ -0,0 +1,306 @@
<?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.ccsens.system.persist.mapper.DockEmplMapper">
<resultMap id="BaseResultMap" type="com.ccsens.system.domain.po.DockEmpl">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="empl_name" jdbcType="VARCHAR" property="emplName" />
<result column="empl_code" jdbcType="VARCHAR" property="emplCode" />
<result column="empl_type" jdbcType="VARCHAR" property="emplType" />
<result column="dept_code" jdbcType="VARCHAR" property="deptCode" />
<result column="del_flag" jdbcType="CHAR" property="delFlag" />
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="sync" jdbcType="VARCHAR" property="sync" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
id, empl_name, empl_code, empl_type, dept_code, del_flag, create_by, create_time,
update_by, update_time, sync
</sql>
<select id="selectByExample" parameterType="com.ccsens.system.domain.po.DockEmplExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from dock_empl
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from dock_empl
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from dock_empl
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.ccsens.system.domain.po.DockEmplExample">
delete from dock_empl
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.ccsens.system.domain.po.DockEmpl">
insert into dock_empl (id, empl_name, empl_code,
empl_type, dept_code, del_flag,
create_by, create_time, update_by,
update_time, sync)
values (#{id,jdbcType=BIGINT}, #{emplName,jdbcType=VARCHAR}, #{emplCode,jdbcType=VARCHAR},
#{emplType,jdbcType=VARCHAR}, #{deptCode,jdbcType=VARCHAR}, #{delFlag,jdbcType=CHAR},
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR},
#{updateTime,jdbcType=TIMESTAMP}, #{sync,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.ccsens.system.domain.po.DockEmpl">
insert into dock_empl
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="emplName != null">
empl_name,
</if>
<if test="emplCode != null">
empl_code,
</if>
<if test="emplType != null">
empl_type,
</if>
<if test="deptCode != null">
dept_code,
</if>
<if test="delFlag != null">
del_flag,
</if>
<if test="createBy != null">
create_by,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateBy != null">
update_by,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="sync != null">
sync,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="emplName != null">
#{emplName,jdbcType=VARCHAR},
</if>
<if test="emplCode != null">
#{emplCode,jdbcType=VARCHAR},
</if>
<if test="emplType != null">
#{emplType,jdbcType=VARCHAR},
</if>
<if test="deptCode != null">
#{deptCode,jdbcType=VARCHAR},
</if>
<if test="delFlag != null">
#{delFlag,jdbcType=CHAR},
</if>
<if test="createBy != null">
#{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
#{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="sync != null">
#{sync,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.ccsens.system.domain.po.DockEmplExample" resultType="java.lang.Long">
select count(*) from dock_empl
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update dock_empl
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.emplName != null">
empl_name = #{record.emplName,jdbcType=VARCHAR},
</if>
<if test="record.emplCode != null">
empl_code = #{record.emplCode,jdbcType=VARCHAR},
</if>
<if test="record.emplType != null">
empl_type = #{record.emplType,jdbcType=VARCHAR},
</if>
<if test="record.deptCode != null">
dept_code = #{record.deptCode,jdbcType=VARCHAR},
</if>
<if test="record.delFlag != null">
del_flag = #{record.delFlag,jdbcType=CHAR},
</if>
<if test="record.createBy != null">
create_by = #{record.createBy,jdbcType=VARCHAR},
</if>
<if test="record.createTime != null">
create_time = #{record.createTime,jdbcType=TIMESTAMP},
</if>
<if test="record.updateBy != null">
update_by = #{record.updateBy,jdbcType=VARCHAR},
</if>
<if test="record.updateTime != null">
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
</if>
<if test="record.sync != null">
sync = #{record.sync,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update dock_empl
set id = #{record.id,jdbcType=BIGINT},
empl_name = #{record.emplName,jdbcType=VARCHAR},
empl_code = #{record.emplCode,jdbcType=VARCHAR},
empl_type = #{record.emplType,jdbcType=VARCHAR},
dept_code = #{record.deptCode,jdbcType=VARCHAR},
del_flag = #{record.delFlag,jdbcType=CHAR},
create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_by = #{record.updateBy,jdbcType=VARCHAR},
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
sync = #{record.sync,jdbcType=VARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.system.domain.po.DockEmpl">
update dock_empl
<set>
<if test="emplName != null">
empl_name = #{emplName,jdbcType=VARCHAR},
</if>
<if test="emplCode != null">
empl_code = #{emplCode,jdbcType=VARCHAR},
</if>
<if test="emplType != null">
empl_type = #{emplType,jdbcType=VARCHAR},
</if>
<if test="deptCode != null">
dept_code = #{deptCode,jdbcType=VARCHAR},
</if>
<if test="delFlag != null">
del_flag = #{delFlag,jdbcType=CHAR},
</if>
<if test="createBy != null">
create_by = #{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
update_by = #{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="sync != null">
sync = #{sync,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.ccsens.system.domain.po.DockEmpl">
update dock_empl
set empl_name = #{emplName,jdbcType=VARCHAR},
empl_code = #{emplCode,jdbcType=VARCHAR},
empl_type = #{emplType,jdbcType=VARCHAR},
dept_code = #{deptCode,jdbcType=VARCHAR},
del_flag = #{delFlag,jdbcType=CHAR},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
sync = #{sync,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>

575
ruisi_java/ruisi-system/src/main/resources/mapper/system/DockPatientBaseInfoMapper.xml

@ -0,0 +1,575 @@
<?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.ccsens.system.persist.mapper.DockPatientBaseInfoMapper">
<resultMap id="BaseResultMap" type="com.ccsens.system.domain.po.DockPatientBaseInfo">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="patient_no" jdbcType="VARCHAR" property="patientNo" />
<result column="id_card" jdbcType="VARCHAR" property="idCard" />
<result column="phone" jdbcType="VARCHAR" property="phone" />
<result column="sex" jdbcType="VARCHAR" property="sex" />
<result column="birthday" jdbcType="DATE" property="birthday" />
<result column="educational_status" jdbcType="VARCHAR" property="educationalStatus" />
<result column="career" jdbcType="VARCHAR" property="career" />
<result column="marital_status" jdbcType="VARCHAR" property="maritalStatus" />
<result column="nation" jdbcType="VARCHAR" property="nation" />
<result column="native_place" jdbcType="VARCHAR" property="nativePlace" />
<result column="address" jdbcType="VARCHAR" property="address" />
<result column="dwelling_state" jdbcType="VARCHAR" property="dwellingState" />
<result column="contact_name" jdbcType="VARCHAR" property="contactName" />
<result column="contact_mobile" jdbcType="VARCHAR" property="contactMobile" />
<result column="contact_relation" jdbcType="VARCHAR" property="contactRelation" />
<result column="abo_blood_type" jdbcType="VARCHAR" property="aboBloodType" />
<result column="rh_blood_type" jdbcType="VARCHAR" property="rhBloodType" />
<result column="belief" jdbcType="VARCHAR" property="belief" />
<result column="hobby" jdbcType="VARCHAR" property="hobby" />
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="del_flag" jdbcType="TINYINT" property="delFlag" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="sync" jdbcType="VARCHAR" property="sync" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
id, name, patient_no, id_card, phone, sex, birthday, educational_status, career,
marital_status, nation, native_place, address, dwelling_state, contact_name, contact_mobile,
contact_relation, abo_blood_type, rh_blood_type, belief, hobby, create_by, create_time,
update_by, update_time, del_flag, remark, sync
</sql>
<select id="selectByExample" parameterType="com.ccsens.system.domain.po.DockPatientBaseInfoExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from dock_patient_base_info
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from dock_patient_base_info
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from dock_patient_base_info
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.ccsens.system.domain.po.DockPatientBaseInfoExample">
delete from dock_patient_base_info
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.ccsens.system.domain.po.DockPatientBaseInfo">
insert into dock_patient_base_info (id, name, patient_no,
id_card, phone, sex,
birthday, educational_status, career,
marital_status, nation, native_place,
address, dwelling_state, contact_name,
contact_mobile, contact_relation, abo_blood_type,
rh_blood_type, belief, hobby,
create_by, create_time, update_by,
update_time, del_flag, remark,
sync)
values (#{id,jdbcType=BIGINT}, #{name,jdbcType=VARCHAR}, #{patientNo,jdbcType=VARCHAR},
#{idCard,jdbcType=VARCHAR}, #{phone,jdbcType=VARCHAR}, #{sex,jdbcType=VARCHAR},
#{birthday,jdbcType=DATE}, #{educationalStatus,jdbcType=VARCHAR}, #{career,jdbcType=VARCHAR},
#{maritalStatus,jdbcType=VARCHAR}, #{nation,jdbcType=VARCHAR}, #{nativePlace,jdbcType=VARCHAR},
#{address,jdbcType=VARCHAR}, #{dwellingState,jdbcType=VARCHAR}, #{contactName,jdbcType=VARCHAR},
#{contactMobile,jdbcType=VARCHAR}, #{contactRelation,jdbcType=VARCHAR}, #{aboBloodType,jdbcType=VARCHAR},
#{rhBloodType,jdbcType=VARCHAR}, #{belief,jdbcType=VARCHAR}, #{hobby,jdbcType=VARCHAR},
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR},
#{updateTime,jdbcType=TIMESTAMP}, #{delFlag,jdbcType=TINYINT}, #{remark,jdbcType=VARCHAR},
#{sync,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.ccsens.system.domain.po.DockPatientBaseInfo">
insert into dock_patient_base_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="name != null">
name,
</if>
<if test="patientNo != null">
patient_no,
</if>
<if test="idCard != null">
id_card,
</if>
<if test="phone != null">
phone,
</if>
<if test="sex != null">
sex,
</if>
<if test="birthday != null">
birthday,
</if>
<if test="educationalStatus != null">
educational_status,
</if>
<if test="career != null">
career,
</if>
<if test="maritalStatus != null">
marital_status,
</if>
<if test="nation != null">
nation,
</if>
<if test="nativePlace != null">
native_place,
</if>
<if test="address != null">
address,
</if>
<if test="dwellingState != null">
dwelling_state,
</if>
<if test="contactName != null">
contact_name,
</if>
<if test="contactMobile != null">
contact_mobile,
</if>
<if test="contactRelation != null">
contact_relation,
</if>
<if test="aboBloodType != null">
abo_blood_type,
</if>
<if test="rhBloodType != null">
rh_blood_type,
</if>
<if test="belief != null">
belief,
</if>
<if test="hobby != null">
hobby,
</if>
<if test="createBy != null">
create_by,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateBy != null">
update_by,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="delFlag != null">
del_flag,
</if>
<if test="remark != null">
remark,
</if>
<if test="sync != null">
sync,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="name != null">
#{name,jdbcType=VARCHAR},
</if>
<if test="patientNo != null">
#{patientNo,jdbcType=VARCHAR},
</if>
<if test="idCard != null">
#{idCard,jdbcType=VARCHAR},
</if>
<if test="phone != null">
#{phone,jdbcType=VARCHAR},
</if>
<if test="sex != null">
#{sex,jdbcType=VARCHAR},
</if>
<if test="birthday != null">
#{birthday,jdbcType=DATE},
</if>
<if test="educationalStatus != null">
#{educationalStatus,jdbcType=VARCHAR},
</if>
<if test="career != null">
#{career,jdbcType=VARCHAR},
</if>
<if test="maritalStatus != null">
#{maritalStatus,jdbcType=VARCHAR},
</if>
<if test="nation != null">
#{nation,jdbcType=VARCHAR},
</if>
<if test="nativePlace != null">
#{nativePlace,jdbcType=VARCHAR},
</if>
<if test="address != null">
#{address,jdbcType=VARCHAR},
</if>
<if test="dwellingState != null">
#{dwellingState,jdbcType=VARCHAR},
</if>
<if test="contactName != null">
#{contactName,jdbcType=VARCHAR},
</if>
<if test="contactMobile != null">
#{contactMobile,jdbcType=VARCHAR},
</if>
<if test="contactRelation != null">
#{contactRelation,jdbcType=VARCHAR},
</if>
<if test="aboBloodType != null">
#{aboBloodType,jdbcType=VARCHAR},
</if>
<if test="rhBloodType != null">
#{rhBloodType,jdbcType=VARCHAR},
</if>
<if test="belief != null">
#{belief,jdbcType=VARCHAR},
</if>
<if test="hobby != null">
#{hobby,jdbcType=VARCHAR},
</if>
<if test="createBy != null">
#{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
#{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="delFlag != null">
#{delFlag,jdbcType=TINYINT},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="sync != null">
#{sync,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.ccsens.system.domain.po.DockPatientBaseInfoExample" resultType="java.lang.Long">
select count(*) from dock_patient_base_info
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update dock_patient_base_info
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.name != null">
name = #{record.name,jdbcType=VARCHAR},
</if>
<if test="record.patientNo != null">
patient_no = #{record.patientNo,jdbcType=VARCHAR},
</if>
<if test="record.idCard != null">
id_card = #{record.idCard,jdbcType=VARCHAR},
</if>
<if test="record.phone != null">
phone = #{record.phone,jdbcType=VARCHAR},
</if>
<if test="record.sex != null">
sex = #{record.sex,jdbcType=VARCHAR},
</if>
<if test="record.birthday != null">
birthday = #{record.birthday,jdbcType=DATE},
</if>
<if test="record.educationalStatus != null">
educational_status = #{record.educationalStatus,jdbcType=VARCHAR},
</if>
<if test="record.career != null">
career = #{record.career,jdbcType=VARCHAR},
</if>
<if test="record.maritalStatus != null">
marital_status = #{record.maritalStatus,jdbcType=VARCHAR},
</if>
<if test="record.nation != null">
nation = #{record.nation,jdbcType=VARCHAR},
</if>
<if test="record.nativePlace != null">
native_place = #{record.nativePlace,jdbcType=VARCHAR},
</if>
<if test="record.address != null">
address = #{record.address,jdbcType=VARCHAR},
</if>
<if test="record.dwellingState != null">
dwelling_state = #{record.dwellingState,jdbcType=VARCHAR},
</if>
<if test="record.contactName != null">
contact_name = #{record.contactName,jdbcType=VARCHAR},
</if>
<if test="record.contactMobile != null">
contact_mobile = #{record.contactMobile,jdbcType=VARCHAR},
</if>
<if test="record.contactRelation != null">
contact_relation = #{record.contactRelation,jdbcType=VARCHAR},
</if>
<if test="record.aboBloodType != null">
abo_blood_type = #{record.aboBloodType,jdbcType=VARCHAR},
</if>
<if test="record.rhBloodType != null">
rh_blood_type = #{record.rhBloodType,jdbcType=VARCHAR},
</if>
<if test="record.belief != null">
belief = #{record.belief,jdbcType=VARCHAR},
</if>
<if test="record.hobby != null">
hobby = #{record.hobby,jdbcType=VARCHAR},
</if>
<if test="record.createBy != null">
create_by = #{record.createBy,jdbcType=VARCHAR},
</if>
<if test="record.createTime != null">
create_time = #{record.createTime,jdbcType=TIMESTAMP},
</if>
<if test="record.updateBy != null">
update_by = #{record.updateBy,jdbcType=VARCHAR},
</if>
<if test="record.updateTime != null">
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
</if>
<if test="record.delFlag != null">
del_flag = #{record.delFlag,jdbcType=TINYINT},
</if>
<if test="record.remark != null">
remark = #{record.remark,jdbcType=VARCHAR},
</if>
<if test="record.sync != null">
sync = #{record.sync,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update dock_patient_base_info
set id = #{record.id,jdbcType=BIGINT},
name = #{record.name,jdbcType=VARCHAR},
patient_no = #{record.patientNo,jdbcType=VARCHAR},
id_card = #{record.idCard,jdbcType=VARCHAR},
phone = #{record.phone,jdbcType=VARCHAR},
sex = #{record.sex,jdbcType=VARCHAR},
birthday = #{record.birthday,jdbcType=DATE},
educational_status = #{record.educationalStatus,jdbcType=VARCHAR},
career = #{record.career,jdbcType=VARCHAR},
marital_status = #{record.maritalStatus,jdbcType=VARCHAR},
nation = #{record.nation,jdbcType=VARCHAR},
native_place = #{record.nativePlace,jdbcType=VARCHAR},
address = #{record.address,jdbcType=VARCHAR},
dwelling_state = #{record.dwellingState,jdbcType=VARCHAR},
contact_name = #{record.contactName,jdbcType=VARCHAR},
contact_mobile = #{record.contactMobile,jdbcType=VARCHAR},
contact_relation = #{record.contactRelation,jdbcType=VARCHAR},
abo_blood_type = #{record.aboBloodType,jdbcType=VARCHAR},
rh_blood_type = #{record.rhBloodType,jdbcType=VARCHAR},
belief = #{record.belief,jdbcType=VARCHAR},
hobby = #{record.hobby,jdbcType=VARCHAR},
create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_by = #{record.updateBy,jdbcType=VARCHAR},
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
del_flag = #{record.delFlag,jdbcType=TINYINT},
remark = #{record.remark,jdbcType=VARCHAR},
sync = #{record.sync,jdbcType=VARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.system.domain.po.DockPatientBaseInfo">
update dock_patient_base_info
<set>
<if test="name != null">
name = #{name,jdbcType=VARCHAR},
</if>
<if test="patientNo != null">
patient_no = #{patientNo,jdbcType=VARCHAR},
</if>
<if test="idCard != null">
id_card = #{idCard,jdbcType=VARCHAR},
</if>
<if test="phone != null">
phone = #{phone,jdbcType=VARCHAR},
</if>
<if test="sex != null">
sex = #{sex,jdbcType=VARCHAR},
</if>
<if test="birthday != null">
birthday = #{birthday,jdbcType=DATE},
</if>
<if test="educationalStatus != null">
educational_status = #{educationalStatus,jdbcType=VARCHAR},
</if>
<if test="career != null">
career = #{career,jdbcType=VARCHAR},
</if>
<if test="maritalStatus != null">
marital_status = #{maritalStatus,jdbcType=VARCHAR},
</if>
<if test="nation != null">
nation = #{nation,jdbcType=VARCHAR},
</if>
<if test="nativePlace != null">
native_place = #{nativePlace,jdbcType=VARCHAR},
</if>
<if test="address != null">
address = #{address,jdbcType=VARCHAR},
</if>
<if test="dwellingState != null">
dwelling_state = #{dwellingState,jdbcType=VARCHAR},
</if>
<if test="contactName != null">
contact_name = #{contactName,jdbcType=VARCHAR},
</if>
<if test="contactMobile != null">
contact_mobile = #{contactMobile,jdbcType=VARCHAR},
</if>
<if test="contactRelation != null">
contact_relation = #{contactRelation,jdbcType=VARCHAR},
</if>
<if test="aboBloodType != null">
abo_blood_type = #{aboBloodType,jdbcType=VARCHAR},
</if>
<if test="rhBloodType != null">
rh_blood_type = #{rhBloodType,jdbcType=VARCHAR},
</if>
<if test="belief != null">
belief = #{belief,jdbcType=VARCHAR},
</if>
<if test="hobby != null">
hobby = #{hobby,jdbcType=VARCHAR},
</if>
<if test="createBy != null">
create_by = #{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
update_by = #{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="delFlag != null">
del_flag = #{delFlag,jdbcType=TINYINT},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="sync != null">
sync = #{sync,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.ccsens.system.domain.po.DockPatientBaseInfo">
update dock_patient_base_info
set name = #{name,jdbcType=VARCHAR},
patient_no = #{patientNo,jdbcType=VARCHAR},
id_card = #{idCard,jdbcType=VARCHAR},
phone = #{phone,jdbcType=VARCHAR},
sex = #{sex,jdbcType=VARCHAR},
birthday = #{birthday,jdbcType=DATE},
educational_status = #{educationalStatus,jdbcType=VARCHAR},
career = #{career,jdbcType=VARCHAR},
marital_status = #{maritalStatus,jdbcType=VARCHAR},
nation = #{nation,jdbcType=VARCHAR},
native_place = #{nativePlace,jdbcType=VARCHAR},
address = #{address,jdbcType=VARCHAR},
dwelling_state = #{dwellingState,jdbcType=VARCHAR},
contact_name = #{contactName,jdbcType=VARCHAR},
contact_mobile = #{contactMobile,jdbcType=VARCHAR},
contact_relation = #{contactRelation,jdbcType=VARCHAR},
abo_blood_type = #{aboBloodType,jdbcType=VARCHAR},
rh_blood_type = #{rhBloodType,jdbcType=VARCHAR},
belief = #{belief,jdbcType=VARCHAR},
hobby = #{hobby,jdbcType=VARCHAR},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
del_flag = #{delFlag,jdbcType=TINYINT},
remark = #{remark,jdbcType=VARCHAR},
sync = #{sync,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>

354
ruisi_java/ruisi-system/src/main/resources/mapper/system/DockPatientDiagnosisMapper.xml

@ -0,0 +1,354 @@
<?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.ccsens.system.persist.mapper.DockPatientDiagnosisMapper">
<resultMap id="BaseResultMap" type="com.ccsens.system.domain.po.DockPatientDiagnosis">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="visit_no" jdbcType="VARCHAR" property="visitNo" />
<result column="diagnosis_type" jdbcType="VARCHAR" property="diagnosisType" />
<result column="is_main_diagnosis" jdbcType="TINYINT" property="isMainDiagnosis" />
<result column="diagnosis_name" jdbcType="VARCHAR" property="diagnosisName" />
<result column="diagnosis_code" jdbcType="VARCHAR" property="diagnosisCode" />
<result column="diagnosis_date" jdbcType="DATE" property="diagnosisDate" />
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="del_flag" jdbcType="TINYINT" property="delFlag" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="sync" jdbcType="VARCHAR" property="sync" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
id, visit_no, diagnosis_type, is_main_diagnosis, diagnosis_name, diagnosis_code,
diagnosis_date, create_by, create_time, update_by, update_time, del_flag, remark,
sync
</sql>
<select id="selectByExample" parameterType="com.ccsens.system.domain.po.DockPatientDiagnosisExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from dock_patient_diagnosis
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from dock_patient_diagnosis
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from dock_patient_diagnosis
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.ccsens.system.domain.po.DockPatientDiagnosisExample">
delete from dock_patient_diagnosis
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.ccsens.system.domain.po.DockPatientDiagnosis">
insert into dock_patient_diagnosis (id, visit_no, diagnosis_type,
is_main_diagnosis, diagnosis_name, diagnosis_code,
diagnosis_date, create_by, create_time,
update_by, update_time, del_flag,
remark, sync)
values (#{id,jdbcType=BIGINT}, #{visitNo,jdbcType=VARCHAR}, #{diagnosisType,jdbcType=VARCHAR},
#{isMainDiagnosis,jdbcType=TINYINT}, #{diagnosisName,jdbcType=VARCHAR}, #{diagnosisCode,jdbcType=VARCHAR},
#{diagnosisDate,jdbcType=DATE}, #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
#{updateBy,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{delFlag,jdbcType=TINYINT},
#{remark,jdbcType=VARCHAR}, #{sync,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.ccsens.system.domain.po.DockPatientDiagnosis">
insert into dock_patient_diagnosis
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="visitNo != null">
visit_no,
</if>
<if test="diagnosisType != null">
diagnosis_type,
</if>
<if test="isMainDiagnosis != null">
is_main_diagnosis,
</if>
<if test="diagnosisName != null">
diagnosis_name,
</if>
<if test="diagnosisCode != null">
diagnosis_code,
</if>
<if test="diagnosisDate != null">
diagnosis_date,
</if>
<if test="createBy != null">
create_by,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateBy != null">
update_by,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="delFlag != null">
del_flag,
</if>
<if test="remark != null">
remark,
</if>
<if test="sync != null">
sync,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="visitNo != null">
#{visitNo,jdbcType=VARCHAR},
</if>
<if test="diagnosisType != null">
#{diagnosisType,jdbcType=VARCHAR},
</if>
<if test="isMainDiagnosis != null">
#{isMainDiagnosis,jdbcType=TINYINT},
</if>
<if test="diagnosisName != null">
#{diagnosisName,jdbcType=VARCHAR},
</if>
<if test="diagnosisCode != null">
#{diagnosisCode,jdbcType=VARCHAR},
</if>
<if test="diagnosisDate != null">
#{diagnosisDate,jdbcType=DATE},
</if>
<if test="createBy != null">
#{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
#{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="delFlag != null">
#{delFlag,jdbcType=TINYINT},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="sync != null">
#{sync,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.ccsens.system.domain.po.DockPatientDiagnosisExample" resultType="java.lang.Long">
select count(*) from dock_patient_diagnosis
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update dock_patient_diagnosis
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.visitNo != null">
visit_no = #{record.visitNo,jdbcType=VARCHAR},
</if>
<if test="record.diagnosisType != null">
diagnosis_type = #{record.diagnosisType,jdbcType=VARCHAR},
</if>
<if test="record.isMainDiagnosis != null">
is_main_diagnosis = #{record.isMainDiagnosis,jdbcType=TINYINT},
</if>
<if test="record.diagnosisName != null">
diagnosis_name = #{record.diagnosisName,jdbcType=VARCHAR},
</if>
<if test="record.diagnosisCode != null">
diagnosis_code = #{record.diagnosisCode,jdbcType=VARCHAR},
</if>
<if test="record.diagnosisDate != null">
diagnosis_date = #{record.diagnosisDate,jdbcType=DATE},
</if>
<if test="record.createBy != null">
create_by = #{record.createBy,jdbcType=VARCHAR},
</if>
<if test="record.createTime != null">
create_time = #{record.createTime,jdbcType=TIMESTAMP},
</if>
<if test="record.updateBy != null">
update_by = #{record.updateBy,jdbcType=VARCHAR},
</if>
<if test="record.updateTime != null">
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
</if>
<if test="record.delFlag != null">
del_flag = #{record.delFlag,jdbcType=TINYINT},
</if>
<if test="record.remark != null">
remark = #{record.remark,jdbcType=VARCHAR},
</if>
<if test="record.sync != null">
sync = #{record.sync,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update dock_patient_diagnosis
set id = #{record.id,jdbcType=BIGINT},
visit_no = #{record.visitNo,jdbcType=VARCHAR},
diagnosis_type = #{record.diagnosisType,jdbcType=VARCHAR},
is_main_diagnosis = #{record.isMainDiagnosis,jdbcType=TINYINT},
diagnosis_name = #{record.diagnosisName,jdbcType=VARCHAR},
diagnosis_code = #{record.diagnosisCode,jdbcType=VARCHAR},
diagnosis_date = #{record.diagnosisDate,jdbcType=DATE},
create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_by = #{record.updateBy,jdbcType=VARCHAR},
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
del_flag = #{record.delFlag,jdbcType=TINYINT},
remark = #{record.remark,jdbcType=VARCHAR},
sync = #{record.sync,jdbcType=VARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.system.domain.po.DockPatientDiagnosis">
update dock_patient_diagnosis
<set>
<if test="visitNo != null">
visit_no = #{visitNo,jdbcType=VARCHAR},
</if>
<if test="diagnosisType != null">
diagnosis_type = #{diagnosisType,jdbcType=VARCHAR},
</if>
<if test="isMainDiagnosis != null">
is_main_diagnosis = #{isMainDiagnosis,jdbcType=TINYINT},
</if>
<if test="diagnosisName != null">
diagnosis_name = #{diagnosisName,jdbcType=VARCHAR},
</if>
<if test="diagnosisCode != null">
diagnosis_code = #{diagnosisCode,jdbcType=VARCHAR},
</if>
<if test="diagnosisDate != null">
diagnosis_date = #{diagnosisDate,jdbcType=DATE},
</if>
<if test="createBy != null">
create_by = #{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
update_by = #{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="delFlag != null">
del_flag = #{delFlag,jdbcType=TINYINT},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="sync != null">
sync = #{sync,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.ccsens.system.domain.po.DockPatientDiagnosis">
update dock_patient_diagnosis
set visit_no = #{visitNo,jdbcType=VARCHAR},
diagnosis_type = #{diagnosisType,jdbcType=VARCHAR},
is_main_diagnosis = #{isMainDiagnosis,jdbcType=TINYINT},
diagnosis_name = #{diagnosisName,jdbcType=VARCHAR},
diagnosis_code = #{diagnosisCode,jdbcType=VARCHAR},
diagnosis_date = #{diagnosisDate,jdbcType=DATE},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
del_flag = #{delFlag,jdbcType=TINYINT},
remark = #{remark,jdbcType=VARCHAR},
sync = #{sync,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>

338
ruisi_java/ruisi-system/src/main/resources/mapper/system/DockPatientMedicationInfoMapper.xml

@ -0,0 +1,338 @@
<?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.ccsens.system.persist.mapper.DockPatientMedicationInfoMapper">
<resultMap id="BaseResultMap" type="com.ccsens.system.domain.po.DockPatientMedicationInfo">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="visit_no" jdbcType="VARCHAR" property="visitNo" />
<result column="drug_name" jdbcType="VARCHAR" property="drugName" />
<result column="dose" jdbcType="DECIMAL" property="dose" />
<result column="unit" jdbcType="VARCHAR" property="unit" />
<result column="frequency" jdbcType="VARCHAR" property="frequency" />
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="del_flag" jdbcType="TINYINT" property="delFlag" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="sync" jdbcType="VARCHAR" property="sync" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
id, visit_no, drug_name, dose, unit, frequency, create_by, create_time, update_by,
update_time, del_flag, remark, sync
</sql>
<select id="selectByExample" parameterType="com.ccsens.system.domain.po.DockPatientMedicationInfoExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from dock_patient_medication_info
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from dock_patient_medication_info
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from dock_patient_medication_info
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.ccsens.system.domain.po.DockPatientMedicationInfoExample">
delete from dock_patient_medication_info
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.ccsens.system.domain.po.DockPatientMedicationInfo">
insert into dock_patient_medication_info (id, visit_no, drug_name,
dose, unit, frequency,
create_by, create_time, update_by,
update_time, del_flag, remark,
sync)
values (#{id,jdbcType=BIGINT}, #{visitNo,jdbcType=VARCHAR}, #{drugName,jdbcType=VARCHAR},
#{dose,jdbcType=DECIMAL}, #{unit,jdbcType=VARCHAR}, #{frequency,jdbcType=VARCHAR},
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR},
#{updateTime,jdbcType=TIMESTAMP}, #{delFlag,jdbcType=TINYINT}, #{remark,jdbcType=VARCHAR},
#{sync,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.ccsens.system.domain.po.DockPatientMedicationInfo">
insert into dock_patient_medication_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="visitNo != null">
visit_no,
</if>
<if test="drugName != null">
drug_name,
</if>
<if test="dose != null">
dose,
</if>
<if test="unit != null">
unit,
</if>
<if test="frequency != null">
frequency,
</if>
<if test="createBy != null">
create_by,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateBy != null">
update_by,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="delFlag != null">
del_flag,
</if>
<if test="remark != null">
remark,
</if>
<if test="sync != null">
sync,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="visitNo != null">
#{visitNo,jdbcType=VARCHAR},
</if>
<if test="drugName != null">
#{drugName,jdbcType=VARCHAR},
</if>
<if test="dose != null">
#{dose,jdbcType=DECIMAL},
</if>
<if test="unit != null">
#{unit,jdbcType=VARCHAR},
</if>
<if test="frequency != null">
#{frequency,jdbcType=VARCHAR},
</if>
<if test="createBy != null">
#{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
#{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="delFlag != null">
#{delFlag,jdbcType=TINYINT},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="sync != null">
#{sync,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.ccsens.system.domain.po.DockPatientMedicationInfoExample" resultType="java.lang.Long">
select count(*) from dock_patient_medication_info
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update dock_patient_medication_info
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.visitNo != null">
visit_no = #{record.visitNo,jdbcType=VARCHAR},
</if>
<if test="record.drugName != null">
drug_name = #{record.drugName,jdbcType=VARCHAR},
</if>
<if test="record.dose != null">
dose = #{record.dose,jdbcType=DECIMAL},
</if>
<if test="record.unit != null">
unit = #{record.unit,jdbcType=VARCHAR},
</if>
<if test="record.frequency != null">
frequency = #{record.frequency,jdbcType=VARCHAR},
</if>
<if test="record.createBy != null">
create_by = #{record.createBy,jdbcType=VARCHAR},
</if>
<if test="record.createTime != null">
create_time = #{record.createTime,jdbcType=TIMESTAMP},
</if>
<if test="record.updateBy != null">
update_by = #{record.updateBy,jdbcType=VARCHAR},
</if>
<if test="record.updateTime != null">
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
</if>
<if test="record.delFlag != null">
del_flag = #{record.delFlag,jdbcType=TINYINT},
</if>
<if test="record.remark != null">
remark = #{record.remark,jdbcType=VARCHAR},
</if>
<if test="record.sync != null">
sync = #{record.sync,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update dock_patient_medication_info
set id = #{record.id,jdbcType=BIGINT},
visit_no = #{record.visitNo,jdbcType=VARCHAR},
drug_name = #{record.drugName,jdbcType=VARCHAR},
dose = #{record.dose,jdbcType=DECIMAL},
unit = #{record.unit,jdbcType=VARCHAR},
frequency = #{record.frequency,jdbcType=VARCHAR},
create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_by = #{record.updateBy,jdbcType=VARCHAR},
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
del_flag = #{record.delFlag,jdbcType=TINYINT},
remark = #{record.remark,jdbcType=VARCHAR},
sync = #{record.sync,jdbcType=VARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.system.domain.po.DockPatientMedicationInfo">
update dock_patient_medication_info
<set>
<if test="visitNo != null">
visit_no = #{visitNo,jdbcType=VARCHAR},
</if>
<if test="drugName != null">
drug_name = #{drugName,jdbcType=VARCHAR},
</if>
<if test="dose != null">
dose = #{dose,jdbcType=DECIMAL},
</if>
<if test="unit != null">
unit = #{unit,jdbcType=VARCHAR},
</if>
<if test="frequency != null">
frequency = #{frequency,jdbcType=VARCHAR},
</if>
<if test="createBy != null">
create_by = #{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
update_by = #{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="delFlag != null">
del_flag = #{delFlag,jdbcType=TINYINT},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="sync != null">
sync = #{sync,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.ccsens.system.domain.po.DockPatientMedicationInfo">
update dock_patient_medication_info
set visit_no = #{visitNo,jdbcType=VARCHAR},
drug_name = #{drugName,jdbcType=VARCHAR},
dose = #{dose,jdbcType=DECIMAL},
unit = #{unit,jdbcType=VARCHAR},
frequency = #{frequency,jdbcType=VARCHAR},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
del_flag = #{delFlag,jdbcType=TINYINT},
remark = #{remark,jdbcType=VARCHAR},
sync = #{sync,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>

845
ruisi_java/ruisi-system/src/main/resources/mapper/system/DockPatientVisitInfoMapper.xml

@ -0,0 +1,845 @@
<?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.ccsens.system.persist.mapper.DockPatientVisitInfoMapper">
<resultMap id="BaseResultMap" type="com.ccsens.system.domain.po.DockPatientVisitInfo">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="id_card" jdbcType="VARCHAR" property="idCard" />
<result column="patient_no" jdbcType="VARCHAR" property="patientNo" />
<result column="visit_type" jdbcType="VARCHAR" property="visitType" />
<result column="visit_no" jdbcType="VARCHAR" property="visitNo" />
<result column="age" jdbcType="INTEGER" property="age" />
<result column="department" jdbcType="VARCHAR" property="department" />
<result column="doctor" jdbcType="VARCHAR" property="doctor" />
<result column="admission_date" jdbcType="TIMESTAMP" property="admissionDate" />
<result column="admission_count" jdbcType="INTEGER" property="admissionCount" />
<result column="bed_number" jdbcType="VARCHAR" property="bedNumber" />
<result column="discharge_date" jdbcType="TIMESTAMP" property="dischargeDate" />
<result column="admission_method" jdbcType="VARCHAR" property="admissionMethod" />
<result column="discharge_method" jdbcType="VARCHAR" property="dischargeMethod" />
<result column="height" jdbcType="DECIMAL" property="height" />
<result column="weight" jdbcType="DECIMAL" property="weight" />
<result column="tz" jdbcType="DECIMAL" property="tz" />
<result column="temperature" jdbcType="DECIMAL" property="temperature" />
<result column="blood_pressure_shrink" jdbcType="INTEGER" property="bloodPressureShrink" />
<result column="blood_pressure_diastole" jdbcType="INTEGER" property="bloodPressureDiastole" />
<result column="pulse" jdbcType="INTEGER" property="pulse" />
<result column="creatinine" jdbcType="DECIMAL" property="creatinine" />
<result column="oxygen_saturation" jdbcType="DECIMAL" property="oxygenSaturation" />
<result column="albumin" jdbcType="DECIMAL" property="albumin" />
<result column="total_protein" jdbcType="DECIMAL" property="totalProtein" />
<result column="vitamin_d3" jdbcType="DECIMAL" property="vitaminD3" />
<result column="hematocrit" jdbcType="DECIMAL" property="hematocrit" />
<result column="dimer" jdbcType="DECIMAL" property="dimer" />
<result column="smoking_history" jdbcType="TINYINT" property="smokingHistory" />
<result column="smoking_year" jdbcType="INTEGER" property="smokingYear" />
<result column="smoking_quit" jdbcType="TINYINT" property="smokingQuit" />
<result column="smoking_quit_year" jdbcType="INTEGER" property="smokingQuitYear" />
<result column="drink_history" jdbcType="TINYINT" property="drinkHistory" />
<result column="drink_year" jdbcType="INTEGER" property="drinkYear" />
<result column="drink_quit" jdbcType="TINYINT" property="drinkQuit" />
<result column="drink_quit_year" jdbcType="INTEGER" property="drinkQuitYear" />
<result column="has_allergy" jdbcType="TINYINT" property="hasAllergy" />
<result column="allergy_drug" jdbcType="VARCHAR" property="allergyDrug" />
<result column="create_by" jdbcType="VARCHAR" property="createBy" />
<result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
<result column="update_by" jdbcType="VARCHAR" property="updateBy" />
<result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
<result column="del_flag" jdbcType="TINYINT" property="delFlag" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="sync" jdbcType="VARCHAR" property="sync" />
</resultMap>
<sql id="Example_Where_Clause">
<where>
<foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Update_By_Example_Where_Clause">
<where>
<foreach collection="example.oredCriteria" item="criteria" separator="or">
<if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion">
<choose>
<when test="criterion.noValue">
and ${criterion.condition}
</when>
<when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value}
</when>
<when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when>
<when test="criterion.listValue">
and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
#{listItem}
</foreach>
</when>
</choose>
</foreach>
</trim>
</if>
</foreach>
</where>
</sql>
<sql id="Base_Column_List">
id, id_card, patient_no, visit_type, visit_no, age, department, doctor, admission_date,
admission_count, bed_number, discharge_date, admission_method, discharge_method,
height, weight, tz, temperature, blood_pressure_shrink, blood_pressure_diastole,
pulse, creatinine, oxygen_saturation, albumin, total_protein, vitamin_d3, hematocrit,
dimer, smoking_history, smoking_year, smoking_quit, smoking_quit_year, drink_history,
drink_year, drink_quit, drink_quit_year, has_allergy, allergy_drug, create_by, create_time,
update_by, update_time, del_flag, remark, sync
</sql>
<select id="selectByExample" parameterType="com.ccsens.system.domain.po.DockPatientVisitInfoExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from dock_patient_visit_info
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
<if test="orderByClause != null">
order by ${orderByClause}
</if>
</select>
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from dock_patient_visit_info
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from dock_patient_visit_info
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.ccsens.system.domain.po.DockPatientVisitInfoExample">
delete from dock_patient_visit_info
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.ccsens.system.domain.po.DockPatientVisitInfo">
insert into dock_patient_visit_info (id, id_card, patient_no,
visit_type, visit_no, age,
department, doctor, admission_date,
admission_count, bed_number, discharge_date,
admission_method, discharge_method, height,
weight, tz, temperature,
blood_pressure_shrink, blood_pressure_diastole,
pulse, creatinine, oxygen_saturation,
albumin, total_protein, vitamin_d3,
hematocrit, dimer, smoking_history,
smoking_year, smoking_quit, smoking_quit_year,
drink_history, drink_year, drink_quit,
drink_quit_year, has_allergy, allergy_drug,
create_by, create_time, update_by,
update_time, del_flag, remark,
sync)
values (#{id,jdbcType=BIGINT}, #{idCard,jdbcType=VARCHAR}, #{patientNo,jdbcType=VARCHAR},
#{visitType,jdbcType=VARCHAR}, #{visitNo,jdbcType=VARCHAR}, #{age,jdbcType=INTEGER},
#{department,jdbcType=VARCHAR}, #{doctor,jdbcType=VARCHAR}, #{admissionDate,jdbcType=TIMESTAMP},
#{admissionCount,jdbcType=INTEGER}, #{bedNumber,jdbcType=VARCHAR}, #{dischargeDate,jdbcType=TIMESTAMP},
#{admissionMethod,jdbcType=VARCHAR}, #{dischargeMethod,jdbcType=VARCHAR}, #{height,jdbcType=DECIMAL},
#{weight,jdbcType=DECIMAL}, #{tz,jdbcType=DECIMAL}, #{temperature,jdbcType=DECIMAL},
#{bloodPressureShrink,jdbcType=INTEGER}, #{bloodPressureDiastole,jdbcType=INTEGER},
#{pulse,jdbcType=INTEGER}, #{creatinine,jdbcType=DECIMAL}, #{oxygenSaturation,jdbcType=DECIMAL},
#{albumin,jdbcType=DECIMAL}, #{totalProtein,jdbcType=DECIMAL}, #{vitaminD3,jdbcType=DECIMAL},
#{hematocrit,jdbcType=DECIMAL}, #{dimer,jdbcType=DECIMAL}, #{smokingHistory,jdbcType=TINYINT},
#{smokingYear,jdbcType=INTEGER}, #{smokingQuit,jdbcType=TINYINT}, #{smokingQuitYear,jdbcType=INTEGER},
#{drinkHistory,jdbcType=TINYINT}, #{drinkYear,jdbcType=INTEGER}, #{drinkQuit,jdbcType=TINYINT},
#{drinkQuitYear,jdbcType=INTEGER}, #{hasAllergy,jdbcType=TINYINT}, #{allergyDrug,jdbcType=VARCHAR},
#{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR},
#{updateTime,jdbcType=TIMESTAMP}, #{delFlag,jdbcType=TINYINT}, #{remark,jdbcType=VARCHAR},
#{sync,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.ccsens.system.domain.po.DockPatientVisitInfo">
insert into dock_patient_visit_info
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="idCard != null">
id_card,
</if>
<if test="patientNo != null">
patient_no,
</if>
<if test="visitType != null">
visit_type,
</if>
<if test="visitNo != null">
visit_no,
</if>
<if test="age != null">
age,
</if>
<if test="department != null">
department,
</if>
<if test="doctor != null">
doctor,
</if>
<if test="admissionDate != null">
admission_date,
</if>
<if test="admissionCount != null">
admission_count,
</if>
<if test="bedNumber != null">
bed_number,
</if>
<if test="dischargeDate != null">
discharge_date,
</if>
<if test="admissionMethod != null">
admission_method,
</if>
<if test="dischargeMethod != null">
discharge_method,
</if>
<if test="height != null">
height,
</if>
<if test="weight != null">
weight,
</if>
<if test="tz != null">
tz,
</if>
<if test="temperature != null">
temperature,
</if>
<if test="bloodPressureShrink != null">
blood_pressure_shrink,
</if>
<if test="bloodPressureDiastole != null">
blood_pressure_diastole,
</if>
<if test="pulse != null">
pulse,
</if>
<if test="creatinine != null">
creatinine,
</if>
<if test="oxygenSaturation != null">
oxygen_saturation,
</if>
<if test="albumin != null">
albumin,
</if>
<if test="totalProtein != null">
total_protein,
</if>
<if test="vitaminD3 != null">
vitamin_d3,
</if>
<if test="hematocrit != null">
hematocrit,
</if>
<if test="dimer != null">
dimer,
</if>
<if test="smokingHistory != null">
smoking_history,
</if>
<if test="smokingYear != null">
smoking_year,
</if>
<if test="smokingQuit != null">
smoking_quit,
</if>
<if test="smokingQuitYear != null">
smoking_quit_year,
</if>
<if test="drinkHistory != null">
drink_history,
</if>
<if test="drinkYear != null">
drink_year,
</if>
<if test="drinkQuit != null">
drink_quit,
</if>
<if test="drinkQuitYear != null">
drink_quit_year,
</if>
<if test="hasAllergy != null">
has_allergy,
</if>
<if test="allergyDrug != null">
allergy_drug,
</if>
<if test="createBy != null">
create_by,
</if>
<if test="createTime != null">
create_time,
</if>
<if test="updateBy != null">
update_by,
</if>
<if test="updateTime != null">
update_time,
</if>
<if test="delFlag != null">
del_flag,
</if>
<if test="remark != null">
remark,
</if>
<if test="sync != null">
sync,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="idCard != null">
#{idCard,jdbcType=VARCHAR},
</if>
<if test="patientNo != null">
#{patientNo,jdbcType=VARCHAR},
</if>
<if test="visitType != null">
#{visitType,jdbcType=VARCHAR},
</if>
<if test="visitNo != null">
#{visitNo,jdbcType=VARCHAR},
</if>
<if test="age != null">
#{age,jdbcType=INTEGER},
</if>
<if test="department != null">
#{department,jdbcType=VARCHAR},
</if>
<if test="doctor != null">
#{doctor,jdbcType=VARCHAR},
</if>
<if test="admissionDate != null">
#{admissionDate,jdbcType=TIMESTAMP},
</if>
<if test="admissionCount != null">
#{admissionCount,jdbcType=INTEGER},
</if>
<if test="bedNumber != null">
#{bedNumber,jdbcType=VARCHAR},
</if>
<if test="dischargeDate != null">
#{dischargeDate,jdbcType=TIMESTAMP},
</if>
<if test="admissionMethod != null">
#{admissionMethod,jdbcType=VARCHAR},
</if>
<if test="dischargeMethod != null">
#{dischargeMethod,jdbcType=VARCHAR},
</if>
<if test="height != null">
#{height,jdbcType=DECIMAL},
</if>
<if test="weight != null">
#{weight,jdbcType=DECIMAL},
</if>
<if test="tz != null">
#{tz,jdbcType=DECIMAL},
</if>
<if test="temperature != null">
#{temperature,jdbcType=DECIMAL},
</if>
<if test="bloodPressureShrink != null">
#{bloodPressureShrink,jdbcType=INTEGER},
</if>
<if test="bloodPressureDiastole != null">
#{bloodPressureDiastole,jdbcType=INTEGER},
</if>
<if test="pulse != null">
#{pulse,jdbcType=INTEGER},
</if>
<if test="creatinine != null">
#{creatinine,jdbcType=DECIMAL},
</if>
<if test="oxygenSaturation != null">
#{oxygenSaturation,jdbcType=DECIMAL},
</if>
<if test="albumin != null">
#{albumin,jdbcType=DECIMAL},
</if>
<if test="totalProtein != null">
#{totalProtein,jdbcType=DECIMAL},
</if>
<if test="vitaminD3 != null">
#{vitaminD3,jdbcType=DECIMAL},
</if>
<if test="hematocrit != null">
#{hematocrit,jdbcType=DECIMAL},
</if>
<if test="dimer != null">
#{dimer,jdbcType=DECIMAL},
</if>
<if test="smokingHistory != null">
#{smokingHistory,jdbcType=TINYINT},
</if>
<if test="smokingYear != null">
#{smokingYear,jdbcType=INTEGER},
</if>
<if test="smokingQuit != null">
#{smokingQuit,jdbcType=TINYINT},
</if>
<if test="smokingQuitYear != null">
#{smokingQuitYear,jdbcType=INTEGER},
</if>
<if test="drinkHistory != null">
#{drinkHistory,jdbcType=TINYINT},
</if>
<if test="drinkYear != null">
#{drinkYear,jdbcType=INTEGER},
</if>
<if test="drinkQuit != null">
#{drinkQuit,jdbcType=TINYINT},
</if>
<if test="drinkQuitYear != null">
#{drinkQuitYear,jdbcType=INTEGER},
</if>
<if test="hasAllergy != null">
#{hasAllergy,jdbcType=TINYINT},
</if>
<if test="allergyDrug != null">
#{allergyDrug,jdbcType=VARCHAR},
</if>
<if test="createBy != null">
#{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
#{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
#{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
#{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="delFlag != null">
#{delFlag,jdbcType=TINYINT},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="sync != null">
#{sync,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.ccsens.system.domain.po.DockPatientVisitInfoExample" resultType="java.lang.Long">
select count(*) from dock_patient_visit_info
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update dock_patient_visit_info
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.idCard != null">
id_card = #{record.idCard,jdbcType=VARCHAR},
</if>
<if test="record.patientNo != null">
patient_no = #{record.patientNo,jdbcType=VARCHAR},
</if>
<if test="record.visitType != null">
visit_type = #{record.visitType,jdbcType=VARCHAR},
</if>
<if test="record.visitNo != null">
visit_no = #{record.visitNo,jdbcType=VARCHAR},
</if>
<if test="record.age != null">
age = #{record.age,jdbcType=INTEGER},
</if>
<if test="record.department != null">
department = #{record.department,jdbcType=VARCHAR},
</if>
<if test="record.doctor != null">
doctor = #{record.doctor,jdbcType=VARCHAR},
</if>
<if test="record.admissionDate != null">
admission_date = #{record.admissionDate,jdbcType=TIMESTAMP},
</if>
<if test="record.admissionCount != null">
admission_count = #{record.admissionCount,jdbcType=INTEGER},
</if>
<if test="record.bedNumber != null">
bed_number = #{record.bedNumber,jdbcType=VARCHAR},
</if>
<if test="record.dischargeDate != null">
discharge_date = #{record.dischargeDate,jdbcType=TIMESTAMP},
</if>
<if test="record.admissionMethod != null">
admission_method = #{record.admissionMethod,jdbcType=VARCHAR},
</if>
<if test="record.dischargeMethod != null">
discharge_method = #{record.dischargeMethod,jdbcType=VARCHAR},
</if>
<if test="record.height != null">
height = #{record.height,jdbcType=DECIMAL},
</if>
<if test="record.weight != null">
weight = #{record.weight,jdbcType=DECIMAL},
</if>
<if test="record.tz != null">
tz = #{record.tz,jdbcType=DECIMAL},
</if>
<if test="record.temperature != null">
temperature = #{record.temperature,jdbcType=DECIMAL},
</if>
<if test="record.bloodPressureShrink != null">
blood_pressure_shrink = #{record.bloodPressureShrink,jdbcType=INTEGER},
</if>
<if test="record.bloodPressureDiastole != null">
blood_pressure_diastole = #{record.bloodPressureDiastole,jdbcType=INTEGER},
</if>
<if test="record.pulse != null">
pulse = #{record.pulse,jdbcType=INTEGER},
</if>
<if test="record.creatinine != null">
creatinine = #{record.creatinine,jdbcType=DECIMAL},
</if>
<if test="record.oxygenSaturation != null">
oxygen_saturation = #{record.oxygenSaturation,jdbcType=DECIMAL},
</if>
<if test="record.albumin != null">
albumin = #{record.albumin,jdbcType=DECIMAL},
</if>
<if test="record.totalProtein != null">
total_protein = #{record.totalProtein,jdbcType=DECIMAL},
</if>
<if test="record.vitaminD3 != null">
vitamin_d3 = #{record.vitaminD3,jdbcType=DECIMAL},
</if>
<if test="record.hematocrit != null">
hematocrit = #{record.hematocrit,jdbcType=DECIMAL},
</if>
<if test="record.dimer != null">
dimer = #{record.dimer,jdbcType=DECIMAL},
</if>
<if test="record.smokingHistory != null">
smoking_history = #{record.smokingHistory,jdbcType=TINYINT},
</if>
<if test="record.smokingYear != null">
smoking_year = #{record.smokingYear,jdbcType=INTEGER},
</if>
<if test="record.smokingQuit != null">
smoking_quit = #{record.smokingQuit,jdbcType=TINYINT},
</if>
<if test="record.smokingQuitYear != null">
smoking_quit_year = #{record.smokingQuitYear,jdbcType=INTEGER},
</if>
<if test="record.drinkHistory != null">
drink_history = #{record.drinkHistory,jdbcType=TINYINT},
</if>
<if test="record.drinkYear != null">
drink_year = #{record.drinkYear,jdbcType=INTEGER},
</if>
<if test="record.drinkQuit != null">
drink_quit = #{record.drinkQuit,jdbcType=TINYINT},
</if>
<if test="record.drinkQuitYear != null">
drink_quit_year = #{record.drinkQuitYear,jdbcType=INTEGER},
</if>
<if test="record.hasAllergy != null">
has_allergy = #{record.hasAllergy,jdbcType=TINYINT},
</if>
<if test="record.allergyDrug != null">
allergy_drug = #{record.allergyDrug,jdbcType=VARCHAR},
</if>
<if test="record.createBy != null">
create_by = #{record.createBy,jdbcType=VARCHAR},
</if>
<if test="record.createTime != null">
create_time = #{record.createTime,jdbcType=TIMESTAMP},
</if>
<if test="record.updateBy != null">
update_by = #{record.updateBy,jdbcType=VARCHAR},
</if>
<if test="record.updateTime != null">
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
</if>
<if test="record.delFlag != null">
del_flag = #{record.delFlag,jdbcType=TINYINT},
</if>
<if test="record.remark != null">
remark = #{record.remark,jdbcType=VARCHAR},
</if>
<if test="record.sync != null">
sync = #{record.sync,jdbcType=VARCHAR},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update dock_patient_visit_info
set id = #{record.id,jdbcType=BIGINT},
id_card = #{record.idCard,jdbcType=VARCHAR},
patient_no = #{record.patientNo,jdbcType=VARCHAR},
visit_type = #{record.visitType,jdbcType=VARCHAR},
visit_no = #{record.visitNo,jdbcType=VARCHAR},
age = #{record.age,jdbcType=INTEGER},
department = #{record.department,jdbcType=VARCHAR},
doctor = #{record.doctor,jdbcType=VARCHAR},
admission_date = #{record.admissionDate,jdbcType=TIMESTAMP},
admission_count = #{record.admissionCount,jdbcType=INTEGER},
bed_number = #{record.bedNumber,jdbcType=VARCHAR},
discharge_date = #{record.dischargeDate,jdbcType=TIMESTAMP},
admission_method = #{record.admissionMethod,jdbcType=VARCHAR},
discharge_method = #{record.dischargeMethod,jdbcType=VARCHAR},
height = #{record.height,jdbcType=DECIMAL},
weight = #{record.weight,jdbcType=DECIMAL},
tz = #{record.tz,jdbcType=DECIMAL},
temperature = #{record.temperature,jdbcType=DECIMAL},
blood_pressure_shrink = #{record.bloodPressureShrink,jdbcType=INTEGER},
blood_pressure_diastole = #{record.bloodPressureDiastole,jdbcType=INTEGER},
pulse = #{record.pulse,jdbcType=INTEGER},
creatinine = #{record.creatinine,jdbcType=DECIMAL},
oxygen_saturation = #{record.oxygenSaturation,jdbcType=DECIMAL},
albumin = #{record.albumin,jdbcType=DECIMAL},
total_protein = #{record.totalProtein,jdbcType=DECIMAL},
vitamin_d3 = #{record.vitaminD3,jdbcType=DECIMAL},
hematocrit = #{record.hematocrit,jdbcType=DECIMAL},
dimer = #{record.dimer,jdbcType=DECIMAL},
smoking_history = #{record.smokingHistory,jdbcType=TINYINT},
smoking_year = #{record.smokingYear,jdbcType=INTEGER},
smoking_quit = #{record.smokingQuit,jdbcType=TINYINT},
smoking_quit_year = #{record.smokingQuitYear,jdbcType=INTEGER},
drink_history = #{record.drinkHistory,jdbcType=TINYINT},
drink_year = #{record.drinkYear,jdbcType=INTEGER},
drink_quit = #{record.drinkQuit,jdbcType=TINYINT},
drink_quit_year = #{record.drinkQuitYear,jdbcType=INTEGER},
has_allergy = #{record.hasAllergy,jdbcType=TINYINT},
allergy_drug = #{record.allergyDrug,jdbcType=VARCHAR},
create_by = #{record.createBy,jdbcType=VARCHAR},
create_time = #{record.createTime,jdbcType=TIMESTAMP},
update_by = #{record.updateBy,jdbcType=VARCHAR},
update_time = #{record.updateTime,jdbcType=TIMESTAMP},
del_flag = #{record.delFlag,jdbcType=TINYINT},
remark = #{record.remark,jdbcType=VARCHAR},
sync = #{record.sync,jdbcType=VARCHAR}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.system.domain.po.DockPatientVisitInfo">
update dock_patient_visit_info
<set>
<if test="idCard != null">
id_card = #{idCard,jdbcType=VARCHAR},
</if>
<if test="patientNo != null">
patient_no = #{patientNo,jdbcType=VARCHAR},
</if>
<if test="visitType != null">
visit_type = #{visitType,jdbcType=VARCHAR},
</if>
<if test="visitNo != null">
visit_no = #{visitNo,jdbcType=VARCHAR},
</if>
<if test="age != null">
age = #{age,jdbcType=INTEGER},
</if>
<if test="department != null">
department = #{department,jdbcType=VARCHAR},
</if>
<if test="doctor != null">
doctor = #{doctor,jdbcType=VARCHAR},
</if>
<if test="admissionDate != null">
admission_date = #{admissionDate,jdbcType=TIMESTAMP},
</if>
<if test="admissionCount != null">
admission_count = #{admissionCount,jdbcType=INTEGER},
</if>
<if test="bedNumber != null">
bed_number = #{bedNumber,jdbcType=VARCHAR},
</if>
<if test="dischargeDate != null">
discharge_date = #{dischargeDate,jdbcType=TIMESTAMP},
</if>
<if test="admissionMethod != null">
admission_method = #{admissionMethod,jdbcType=VARCHAR},
</if>
<if test="dischargeMethod != null">
discharge_method = #{dischargeMethod,jdbcType=VARCHAR},
</if>
<if test="height != null">
height = #{height,jdbcType=DECIMAL},
</if>
<if test="weight != null">
weight = #{weight,jdbcType=DECIMAL},
</if>
<if test="tz != null">
tz = #{tz,jdbcType=DECIMAL},
</if>
<if test="temperature != null">
temperature = #{temperature,jdbcType=DECIMAL},
</if>
<if test="bloodPressureShrink != null">
blood_pressure_shrink = #{bloodPressureShrink,jdbcType=INTEGER},
</if>
<if test="bloodPressureDiastole != null">
blood_pressure_diastole = #{bloodPressureDiastole,jdbcType=INTEGER},
</if>
<if test="pulse != null">
pulse = #{pulse,jdbcType=INTEGER},
</if>
<if test="creatinine != null">
creatinine = #{creatinine,jdbcType=DECIMAL},
</if>
<if test="oxygenSaturation != null">
oxygen_saturation = #{oxygenSaturation,jdbcType=DECIMAL},
</if>
<if test="albumin != null">
albumin = #{albumin,jdbcType=DECIMAL},
</if>
<if test="totalProtein != null">
total_protein = #{totalProtein,jdbcType=DECIMAL},
</if>
<if test="vitaminD3 != null">
vitamin_d3 = #{vitaminD3,jdbcType=DECIMAL},
</if>
<if test="hematocrit != null">
hematocrit = #{hematocrit,jdbcType=DECIMAL},
</if>
<if test="dimer != null">
dimer = #{dimer,jdbcType=DECIMAL},
</if>
<if test="smokingHistory != null">
smoking_history = #{smokingHistory,jdbcType=TINYINT},
</if>
<if test="smokingYear != null">
smoking_year = #{smokingYear,jdbcType=INTEGER},
</if>
<if test="smokingQuit != null">
smoking_quit = #{smokingQuit,jdbcType=TINYINT},
</if>
<if test="smokingQuitYear != null">
smoking_quit_year = #{smokingQuitYear,jdbcType=INTEGER},
</if>
<if test="drinkHistory != null">
drink_history = #{drinkHistory,jdbcType=TINYINT},
</if>
<if test="drinkYear != null">
drink_year = #{drinkYear,jdbcType=INTEGER},
</if>
<if test="drinkQuit != null">
drink_quit = #{drinkQuit,jdbcType=TINYINT},
</if>
<if test="drinkQuitYear != null">
drink_quit_year = #{drinkQuitYear,jdbcType=INTEGER},
</if>
<if test="hasAllergy != null">
has_allergy = #{hasAllergy,jdbcType=TINYINT},
</if>
<if test="allergyDrug != null">
allergy_drug = #{allergyDrug,jdbcType=VARCHAR},
</if>
<if test="createBy != null">
create_by = #{createBy,jdbcType=VARCHAR},
</if>
<if test="createTime != null">
create_time = #{createTime,jdbcType=TIMESTAMP},
</if>
<if test="updateBy != null">
update_by = #{updateBy,jdbcType=VARCHAR},
</if>
<if test="updateTime != null">
update_time = #{updateTime,jdbcType=TIMESTAMP},
</if>
<if test="delFlag != null">
del_flag = #{delFlag,jdbcType=TINYINT},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="sync != null">
sync = #{sync,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.ccsens.system.domain.po.DockPatientVisitInfo">
update dock_patient_visit_info
set id_card = #{idCard,jdbcType=VARCHAR},
patient_no = #{patientNo,jdbcType=VARCHAR},
visit_type = #{visitType,jdbcType=VARCHAR},
visit_no = #{visitNo,jdbcType=VARCHAR},
age = #{age,jdbcType=INTEGER},
department = #{department,jdbcType=VARCHAR},
doctor = #{doctor,jdbcType=VARCHAR},
admission_date = #{admissionDate,jdbcType=TIMESTAMP},
admission_count = #{admissionCount,jdbcType=INTEGER},
bed_number = #{bedNumber,jdbcType=VARCHAR},
discharge_date = #{dischargeDate,jdbcType=TIMESTAMP},
admission_method = #{admissionMethod,jdbcType=VARCHAR},
discharge_method = #{dischargeMethod,jdbcType=VARCHAR},
height = #{height,jdbcType=DECIMAL},
weight = #{weight,jdbcType=DECIMAL},
tz = #{tz,jdbcType=DECIMAL},
temperature = #{temperature,jdbcType=DECIMAL},
blood_pressure_shrink = #{bloodPressureShrink,jdbcType=INTEGER},
blood_pressure_diastole = #{bloodPressureDiastole,jdbcType=INTEGER},
pulse = #{pulse,jdbcType=INTEGER},
creatinine = #{creatinine,jdbcType=DECIMAL},
oxygen_saturation = #{oxygenSaturation,jdbcType=DECIMAL},
albumin = #{albumin,jdbcType=DECIMAL},
total_protein = #{totalProtein,jdbcType=DECIMAL},
vitamin_d3 = #{vitaminD3,jdbcType=DECIMAL},
hematocrit = #{hematocrit,jdbcType=DECIMAL},
dimer = #{dimer,jdbcType=DECIMAL},
smoking_history = #{smokingHistory,jdbcType=TINYINT},
smoking_year = #{smokingYear,jdbcType=INTEGER},
smoking_quit = #{smokingQuit,jdbcType=TINYINT},
smoking_quit_year = #{smokingQuitYear,jdbcType=INTEGER},
drink_history = #{drinkHistory,jdbcType=TINYINT},
drink_year = #{drinkYear,jdbcType=INTEGER},
drink_quit = #{drinkQuit,jdbcType=TINYINT},
drink_quit_year = #{drinkQuitYear,jdbcType=INTEGER},
has_allergy = #{hasAllergy,jdbcType=TINYINT},
allergy_drug = #{allergyDrug,jdbcType=VARCHAR},
create_by = #{createBy,jdbcType=VARCHAR},
create_time = #{createTime,jdbcType=TIMESTAMP},
update_by = #{updateBy,jdbcType=VARCHAR},
update_time = #{updateTime,jdbcType=TIMESTAMP},
del_flag = #{delFlag,jdbcType=TINYINT},
remark = #{remark,jdbcType=VARCHAR},
sync = #{sync,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>

25
ruisi_java/ruisi-system/src/main/resources/mapper/system/PmsPatientMapper.xml

@ -48,6 +48,7 @@
<result column="id_card_type_other" jdbcType="VARCHAR" property="idCardTypeOther" /> <result column="id_card_type_other" jdbcType="VARCHAR" property="idCardTypeOther" />
<result column="abo_blood_type" jdbcType="VARCHAR" property="aboBloodType" /> <result column="abo_blood_type" jdbcType="VARCHAR" property="aboBloodType" />
<result column="rh_blood_type" jdbcType="VARCHAR" property="rhBloodType" /> <result column="rh_blood_type" jdbcType="VARCHAR" property="rhBloodType" />
<result column="patient_no" jdbcType="VARCHAR" property="patientNo" />
</resultMap> </resultMap>
<sql id="Example_Where_Clause"> <sql id="Example_Where_Clause">
<where> <where>
@ -114,7 +115,7 @@
city, address, domicile, independent_living_skills, dwelling_state, recorder, remark, city, address, domicile, independent_living_skills, dwelling_state, recorder, remark,
create_by, create_time, update_by, update_time, del_flag, birth_year, birthday, belief, create_by, create_time, update_by, update_time, del_flag, birth_year, birthday, belief,
hobby, contact_name, contact_relation, contact_mobile, contact_other, id_card_type, hobby, contact_name, contact_relation, contact_mobile, contact_other, id_card_type,
id_card_type_other, abo_blood_type, rh_blood_type id_card_type_other, abo_blood_type, rh_blood_type, patient_no
</sql> </sql>
<select id="selectByExample" parameterType="com.ccsens.system.domain.po.PmsPatientExample" resultMap="BaseResultMap"> <select id="selectByExample" parameterType="com.ccsens.system.domain.po.PmsPatientExample" resultMap="BaseResultMap">
select select
@ -162,7 +163,7 @@
belief, hobby, contact_name, belief, hobby, contact_name,
contact_relation, contact_mobile, contact_other, contact_relation, contact_mobile, contact_other,
id_card_type, id_card_type_other, abo_blood_type, id_card_type, id_card_type_other, abo_blood_type,
rh_blood_type) rh_blood_type, patient_no)
values (#{id,jdbcType=BIGINT}, #{userId,jdbcType=BIGINT}, #{hospitalId,jdbcType=BIGINT}, values (#{id,jdbcType=BIGINT}, #{userId,jdbcType=BIGINT}, #{hospitalId,jdbcType=BIGINT},
#{name,jdbcType=VARCHAR}, #{nameInitial,jdbcType=VARCHAR}, #{nameFull,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{nameInitial,jdbcType=VARCHAR}, #{nameFull,jdbcType=VARCHAR},
#{patientNumber,jdbcType=VARCHAR}, #{hospitalNumber,jdbcType=VARCHAR}, #{idcard,jdbcType=VARCHAR}, #{patientNumber,jdbcType=VARCHAR}, #{hospitalNumber,jdbcType=VARCHAR}, #{idcard,jdbcType=VARCHAR},
@ -178,7 +179,7 @@
#{belief,jdbcType=VARCHAR}, #{hobby,jdbcType=VARCHAR}, #{contactName,jdbcType=VARCHAR}, #{belief,jdbcType=VARCHAR}, #{hobby,jdbcType=VARCHAR}, #{contactName,jdbcType=VARCHAR},
#{contactRelation,jdbcType=VARCHAR}, #{contactMobile,jdbcType=VARCHAR}, #{contactOther,jdbcType=VARCHAR}, #{contactRelation,jdbcType=VARCHAR}, #{contactMobile,jdbcType=VARCHAR}, #{contactOther,jdbcType=VARCHAR},
#{idCardType,jdbcType=VARCHAR}, #{idCardTypeOther,jdbcType=VARCHAR}, #{aboBloodType,jdbcType=VARCHAR}, #{idCardType,jdbcType=VARCHAR}, #{idCardTypeOther,jdbcType=VARCHAR}, #{aboBloodType,jdbcType=VARCHAR},
#{rhBloodType,jdbcType=VARCHAR}) #{rhBloodType,jdbcType=VARCHAR}, #{patientNo,jdbcType=VARCHAR})
</insert> </insert>
<insert id="insertSelective" parameterType="com.ccsens.system.domain.po.PmsPatient"> <insert id="insertSelective" parameterType="com.ccsens.system.domain.po.PmsPatient">
insert into pms_patient insert into pms_patient
@ -321,6 +322,9 @@
<if test="rhBloodType != null"> <if test="rhBloodType != null">
rh_blood_type, rh_blood_type,
</if> </if>
<if test="patientNo != null">
patient_no,
</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null"> <if test="id != null">
@ -461,6 +465,9 @@
<if test="rhBloodType != null"> <if test="rhBloodType != null">
#{rhBloodType,jdbcType=VARCHAR}, #{rhBloodType,jdbcType=VARCHAR},
</if> </if>
<if test="patientNo != null">
#{patientNo,jdbcType=VARCHAR},
</if>
</trim> </trim>
</insert> </insert>
<select id="countByExample" parameterType="com.ccsens.system.domain.po.PmsPatientExample" resultType="java.lang.Long"> <select id="countByExample" parameterType="com.ccsens.system.domain.po.PmsPatientExample" resultType="java.lang.Long">
@ -610,6 +617,9 @@
<if test="record.rhBloodType != null"> <if test="record.rhBloodType != null">
rh_blood_type = #{record.rhBloodType,jdbcType=VARCHAR}, rh_blood_type = #{record.rhBloodType,jdbcType=VARCHAR},
</if> </if>
<if test="record.patientNo != null">
patient_no = #{record.patientNo,jdbcType=VARCHAR},
</if>
</set> </set>
<if test="_parameter != null"> <if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" /> <include refid="Update_By_Example_Where_Clause" />
@ -662,7 +672,8 @@
id_card_type = #{record.idCardType,jdbcType=VARCHAR}, id_card_type = #{record.idCardType,jdbcType=VARCHAR},
id_card_type_other = #{record.idCardTypeOther,jdbcType=VARCHAR}, id_card_type_other = #{record.idCardTypeOther,jdbcType=VARCHAR},
abo_blood_type = #{record.aboBloodType,jdbcType=VARCHAR}, abo_blood_type = #{record.aboBloodType,jdbcType=VARCHAR},
rh_blood_type = #{record.rhBloodType,jdbcType=VARCHAR} rh_blood_type = #{record.rhBloodType,jdbcType=VARCHAR},
patient_no = #{record.patientNo,jdbcType=VARCHAR}
<if test="_parameter != null"> <if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" /> <include refid="Update_By_Example_Where_Clause" />
</if> </if>
@ -805,6 +816,9 @@
<if test="rhBloodType != null"> <if test="rhBloodType != null">
rh_blood_type = #{rhBloodType,jdbcType=VARCHAR}, rh_blood_type = #{rhBloodType,jdbcType=VARCHAR},
</if> </if>
<if test="patientNo != null">
patient_no = #{patientNo,jdbcType=VARCHAR},
</if>
</set> </set>
where id = #{id,jdbcType=BIGINT} where id = #{id,jdbcType=BIGINT}
</update> </update>
@ -854,7 +868,8 @@
id_card_type = #{idCardType,jdbcType=VARCHAR}, id_card_type = #{idCardType,jdbcType=VARCHAR},
id_card_type_other = #{idCardTypeOther,jdbcType=VARCHAR}, id_card_type_other = #{idCardTypeOther,jdbcType=VARCHAR},
abo_blood_type = #{aboBloodType,jdbcType=VARCHAR}, abo_blood_type = #{aboBloodType,jdbcType=VARCHAR},
rh_blood_type = #{rhBloodType,jdbcType=VARCHAR} rh_blood_type = #{rhBloodType,jdbcType=VARCHAR},
patient_no = #{patientNo,jdbcType=VARCHAR}
where id = #{id,jdbcType=BIGINT} where id = #{id,jdbcType=BIGINT}
</update> </update>
</mapper> </mapper>

8
ruisi_java/ruisi-system/src/main/resources/mapper/system/SysDeptMapper.xml

@ -42,6 +42,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="status != null and status != ''"> <if test="status != null and status != ''">
AND status = #{status} AND status = #{status}
</if> </if>
<if test="deptCode != null and deptCode != ''">
AND dept_code = #{deptCode}
</if>
<!-- 数据范围过滤 --> <!-- 数据范围过滤 -->
${params.dataScope} ${params.dataScope}
order by d.parent_id, d.order_num order by d.parent_id, d.order_num
@ -87,11 +90,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where dept_name=#{deptName} and parent_id = #{parentId} and del_flag = '0' limit 1 where dept_name=#{deptName} and parent_id = #{parentId} and del_flag = '0' limit 1
</select> </select>
<insert id="insertDept" parameterType="SysDept"> <insert id="insertDept" parameterType="SysDept" useGeneratedKeys="true" keyProperty="deptId">
insert into ums_dept( insert into ums_dept(
<if test="deptId != null and deptId != 0">dept_id,</if> <if test="deptId != null and deptId != 0">dept_id,</if>
<if test="parentId != null and parentId != 0">parent_id,</if> <if test="parentId != null and parentId != 0">parent_id,</if>
<if test="deptName != null and deptName != ''">dept_name,</if> <if test="deptName != null and deptName != ''">dept_name,</if>
<if test="deptCode != null and deptCode != ''">dept_code,</if>
<if test="ancestors != null and ancestors != ''">ancestors,</if> <if test="ancestors != null and ancestors != ''">ancestors,</if>
<if test="orderNum != null">order_num,</if> <if test="orderNum != null">order_num,</if>
<if test="leader != null and leader != ''">leader,</if> <if test="leader != null and leader != ''">leader,</if>
@ -104,6 +108,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="deptId != null and deptId != 0">#{deptId},</if> <if test="deptId != null and deptId != 0">#{deptId},</if>
<if test="parentId != null and parentId != 0">#{parentId},</if> <if test="parentId != null and parentId != 0">#{parentId},</if>
<if test="deptName != null and deptName != ''">#{deptName},</if> <if test="deptName != null and deptName != ''">#{deptName},</if>
<if test="deptCode != null and deptCode != ''">#{deptCode},</if>
<if test="ancestors != null and ancestors != ''">#{ancestors},</if> <if test="ancestors != null and ancestors != ''">#{ancestors},</if>
<if test="orderNum != null">#{orderNum},</if> <if test="orderNum != null">#{orderNum},</if>
<if test="leader != null and leader != ''">#{leader},</if> <if test="leader != null and leader != ''">#{leader},</if>
@ -120,6 +125,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<set> <set>
<if test="parentId != null and parentId != 0">parent_id = #{parentId},</if> <if test="parentId != null and parentId != 0">parent_id = #{parentId},</if>
<if test="deptName != null and deptName != ''">dept_name = #{deptName},</if> <if test="deptName != null and deptName != ''">dept_name = #{deptName},</if>
<if test="deptCode != null and deptCode != ''">dept_code = #{deptCode},</if>
<if test="ancestors != null and ancestors != ''">ancestors = #{ancestors},</if> <if test="ancestors != null and ancestors != ''">ancestors = #{ancestors},</if>
<if test="orderNum != null">order_num = #{orderNum},</if> <if test="orderNum != null">order_num = #{orderNum},</if>
<if test="leader != null">leader = #{leader},</if> <if test="leader != null">leader = #{leader},</if>

25
ruisi_java/ruisi-system/src/main/resources/mapper/system/SysUserMapper.xml

@ -104,6 +104,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="userName != null and userName != ''"> <if test="userName != null and userName != ''">
AND u.user_name like concat('%', #{userName}, '%') AND u.user_name like concat('%', #{userName}, '%')
</if> </if>
<if test="emplCode != null and emplCode != ''">
AND u.empl_code = #{emplCode}
</if>
<if test="status != null and status != ''"> <if test="status != null and status != ''">
AND u.status = #{status} AND u.status = #{status}
</if> </if>
@ -160,8 +163,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="selectUserByUserName" parameterType="String" resultMap="SysUserResult"> <select id="selectUserByUserName" parameterType="String" resultMap="SysUserResult">
<include refid="selectUserVo"/> <include refid="selectUserVo"/>
where u.user_name = #{userName} and u.del_flag = '0' where (u.user_name = #{userName} or u.empl_code = #{userName}) and u.del_flag = '0'
group by u.user_id group by u.user_id limit 1
</select> </select>
<select id="selectUserById" parameterType="Long" resultMap="SysUserResult"> <select id="selectUserById" parameterType="Long" resultMap="SysUserResult">
@ -226,14 +229,29 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
and u.del_flag = 0 and u.del_flag = 0
and r.del_flag = 0 and r.del_flag = 0
</select> </select>
<select id="getZcpsByHospitalId" resultType="com.ccsens.common.core.domain.entity.SysUser">
SELECT
distinct u.user_id, u.dept_id, u.user_name, u.nick_name, u.email, u.phonenumber, u.sex, u.avatar, u.status, u.del_flag, u.login_ip, u.login_date, u.create_by, u.create_time, u.update_by, u.update_time, u.remark
,r.role_id,r.role_key
FROM
ums_user u
JOIN ums_user_role ur ON u.user_id = ur.user_id
join ums_role r on ur.role_id = r.role_id
WHERE
r.role_key = 'yy_zcps'
and u.del_flag = 0
and r.del_flag = 0
and u.dept_id = #{hospitalId}
</select>
<insert id="insertUser" parameterType="SysUser" useGeneratedKeys="true" keyProperty="userId"> <insert id="insertUser" parameterType="SysUser" useGeneratedKeys="true" keyProperty="userId">
insert into ums_user( insert into ums_user(
<if test="userId != null and userId != 0">user_id,</if> <if test="userId != null and userId != 0">user_id,</if>
<if test="deptId != null and deptId != 0">dept_id,</if> <if test="deptId != null and deptId != 0">dept_id,</if>
<if test="postId != null and postId != 0">post_id,</if> <if test="postId != null and postId != 0">post_id,</if>
<if test="titleId != null and titleId != 0">title_id,</if> <if test="titleId != null and titleId != 0">title_id,</if>
<if test="userName != null and userName != ''">user_name,</if> <if test="userName != null and userName != ''">user_name,</if>
<if test="emplCode != null and emplCode != ''">empl_code,</if>
<if test="nickName != null and nickName != ''">nick_name,</if> <if test="nickName != null and nickName != ''">nick_name,</if>
<if test="email != null and email != ''">email,</if> <if test="email != null and email != ''">email,</if>
<if test="avatar != null and avatar != ''">avatar,</if> <if test="avatar != null and avatar != ''">avatar,</if>
@ -252,6 +270,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="postId != null and postId != ''">#{postId},</if> <if test="postId != null and postId != ''">#{postId},</if>
<if test="titleId != null and titleId != ''">#{titleId},</if> <if test="titleId != null and titleId != ''">#{titleId},</if>
<if test="userName != null and userName != ''">#{userName},</if> <if test="userName != null and userName != ''">#{userName},</if>
<if test="emplCode != null and emplCode != ''">#{emplCode},</if>
<if test="nickName != null and nickName != ''">#{nickName},</if> <if test="nickName != null and nickName != ''">#{nickName},</if>
<if test="email != null and email != ''">#{email},</if> <if test="email != null and email != ''">#{email},</if>
<if test="avatar != null and avatar != ''">#{avatar},</if> <if test="avatar != null and avatar != ''">#{avatar},</if>

21
ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/controller/ReportPdfController.java

@ -2,13 +2,17 @@ package com.ccsens.admin.controller;
import com.ccsens.admin.service.IRmsService; import com.ccsens.admin.service.IRmsService;
import com.ccsens.common.annotation.Anonymous; import com.ccsens.common.annotation.Anonymous;
import com.ccsens.common.core.domain.BaseDto;
import com.ccsens.common.core.domain.JsonResponse; import com.ccsens.common.core.domain.JsonResponse;
import com.ccsens.system.domain.dto.PmsPatientDto;
import com.ccsens.system.domain.dto.RmsDto; import com.ccsens.system.domain.dto.RmsDto;
import com.ccsens.system.domain.vo.RmsVo; import com.ccsens.system.domain.vo.RmsVo;
import com.github.pagehelper.PageInfo;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam; import io.swagger.annotations.ApiParam;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
@ -16,6 +20,9 @@ import org.springframework.web.bind.annotation.RestController;
import javax.annotation.Resource; import javax.annotation.Resource;
import javax.validation.Valid; import javax.validation.Valid;
import java.util.List;
import static com.github.pagehelper.page.PageMethod.startPage;
/** /**
* @author zy * @author zy
@ -32,9 +39,19 @@ public class ReportPdfController {
@Anonymous @Anonymous
@ApiOperation(value = "通过就诊号查询患者的评估报告单",notes = "") @ApiOperation(value = "通过就诊号查询患者的评估报告单",notes = "")
@PostMapping(value="/reportPDF") @PostMapping(value="/reportPDF")
public JsonResponse<String> generate(@RequestBody @ApiParam @Valid RmsDto.ReportPDF dto){ public JsonResponse<PageInfo<RmsVo.ReportPDF>> reportPDF(@RequestBody @Validated BaseDto<RmsDto.ReportPDF> dto){
log.info("通过就诊号查询患者的评估报告单:{}", dto);
startPage(dto);
List<RmsVo.ReportPDF> list = rmsService.viewReportPDF(dto.getParam());
return JsonResponse.ok(new PageInfo<>(list));
}
@Anonymous
@ApiOperation(value = "通过就诊号查询患者的评估报告单",notes = "")
@PostMapping(value="/queryPdfUrl")
public JsonResponse<String> queryPdfUrl(@RequestBody @Validated BaseDto<RmsDto.queryPdfUrl> dto){
log.info("通过就诊号查询患者的评估报告单:{}", dto); log.info("通过就诊号查询患者的评估报告单:{}", dto);
String url = rmsService.viewReportPDF(dto); String url = rmsService.queryPdfUrl(dto.getParam());
return JsonResponse.ok(url); return JsonResponse.ok(url);
} }
} }

4
ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/persist/dao/RmsDao.java

@ -138,4 +138,8 @@ public interface RmsDao {
List<RmsVo.ReportScore> queryEmsScaleScore(@Param("evaId") Long evaId, List<RmsVo.ReportScore> queryEmsScaleScore(@Param("evaId") Long evaId,
@Param("scaleCodeList") List<String> scaleCodeList); @Param("scaleCodeList") List<String> scaleCodeList);
List<RmsVo.ReportPDF> viewReportPdfByVisitNo(@Param("visitNo")String visitNo);
List<RmsVo.ReportPDF> viewReportPdfByPatientNo(@Param("patientNo")String patientNo);
} }

4
ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/service/IRmsService.java

@ -39,9 +39,11 @@ public interface IRmsService {
Workbook exportAnalyse(List<Long> ids); Workbook exportAnalyse(List<Long> ids);
String viewReportPDF(RmsDto.ReportPDF dto); List<RmsVo.ReportPDF> viewReportPDF(RmsDto.ReportPDF dto);
List<RmsVo.Report> queryReportList(RmsDto.ReportQuery param, Long userId); List<RmsVo.Report> queryReportList(RmsDto.ReportQuery param, Long userId);
String queryPdfUrl(RmsDto.queryPdfUrl param);
void exportEvaluation(RmsDto.ReportQuery param, HttpServletResponse response) throws IOException; void exportEvaluation(RmsDto.ReportQuery param, HttpServletResponse response) throws IOException;
} }

50
ruisi_java/ruisi-web-admin/src/main/java/com/ccsens/admin/service/impl/RmsServiceImpl.java

@ -18,21 +18,20 @@ import com.ccsens.common.config.AppConfig;
import com.ccsens.common.constant.CultureEnum; import com.ccsens.common.constant.CultureEnum;
import com.ccsens.common.constant.ErrorConstant; import com.ccsens.common.constant.ErrorConstant;
import com.ccsens.common.constant.GenConstants; import com.ccsens.common.constant.GenConstants;
import com.ccsens.common.constant.JobEnum;
import com.ccsens.common.core.redis.RedisCache; import com.ccsens.common.core.redis.RedisCache;
import com.ccsens.common.enums.BaseEnum;
import com.ccsens.common.exception.ServiceException;
import com.ccsens.common.exception.base.BaseException; import com.ccsens.common.exception.base.BaseException;
import com.ccsens.common.utils.*; import com.ccsens.common.utils.*;
import com.ccsens.system.domain.dto.AmsDto; import com.ccsens.system.domain.dto.AmsDto;
import com.ccsens.system.domain.dto.RmsDto; import com.ccsens.system.domain.dto.RmsDto;
import com.ccsens.system.domain.dto.message.MessageDto; import com.ccsens.system.domain.dto.message.MessageDto;
import com.ccsens.system.domain.po.*; import com.ccsens.system.domain.po.*;
import com.ccsens.system.domain.vo.AmsReportVo;
import com.ccsens.system.domain.vo.AmsVo;
import com.ccsens.system.domain.vo.HmsVo;
import com.ccsens.system.domain.vo.RmsVo;
import com.ccsens.system.domain.vo.*; import com.ccsens.system.domain.vo.*;
import com.ccsens.admin.domain.vo.LdPatientExportVo; import com.ccsens.admin.domain.vo.LdPatientExportVo;
import com.ccsens.system.persist.mapper.*; import com.ccsens.system.persist.mapper.*;
import com.deepoove.poi.XWPFTemplate;
import com.deepoove.poi.data.*;
import com.github.pagehelper.util.StringUtil; import com.github.pagehelper.util.StringUtil;
import com.itextpdf.text.BadElementException; import com.itextpdf.text.BadElementException;
import com.itextpdf.text.Image; import com.itextpdf.text.Image;
@ -1687,22 +1686,35 @@ public class RmsServiceImpl implements IRmsService {
} }
@Override @Override
public String viewReportPDF(RmsDto.ReportPDF dto) { public List<RmsVo.ReportPDF> viewReportPDF(RmsDto.ReportPDF dto) {
if(StrUtil.isBlank(dto.getPatientNo())){ if(StrUtil.isNotBlank(dto.getVisitNo())){
throw new ServiceException("患者就诊号不能为空"); return rmsDao.viewReportPdfByVisitNo(dto.getVisitNo());
}else{
return rmsDao.viewReportPdfByPatientNo(dto.getPatientNo());
} }
//根据就诊流水号查询患者的 }
RmsReport report;
RmsReportExample example = new RmsReportExample(); @Override
example.createCriteria().andVisitNoEqualTo(dto.getPatientNo()).andDelFlagEqualTo((byte) 0); public String queryPdfUrl(RmsDto.queryPdfUrl dto) {
List<RmsReport> reports = rmsReportMapper.selectByExample(example); RmsReport report = rmsReportMapper.selectByPrimaryKey(dto.getReportId());
if (CollectionUtil.isNotEmpty(reports)) { if (ObjectUtil.isNotNull(report) && StrUtil.isNotBlank(report.getUrl())) {
report = reports.get(0); return report.getUrl();
if(ObjectUtil.isNotNull(report)){ }
return report.getUrl(); String url = "";
} //根据医生id查找医生的签名id
if(ObjectUtil.isNotNull(dto.getAssessorId())){
// List<HmsVo.QuerySign> querySigns = hmsDoctorDao.querySign(dto.getAssessorId());
// if(CollUtil.isNotEmpty(querySigns)){
// //生成文件
// RmsDto.ExportReport1Dto exportReport1Dto = new RmsDto.ExportReport1Dto();
// exportReport1Dto.setReportId(dto.getReportId());
// exportReport1Dto.setEvaluationId(dto.getEvaluationId());
// exportReport1Dto.setSignId(querySigns.get(0).getSignId());
// AmsReportVo.Result result = amsReportService.exportYs(exportReport1Dto);
// url = result.getPath();
// }
} }
return null; return url;
} }
@Override @Override

2
ruisi_java/ruisi-web-admin/src/main/resources/application-stage.yml

@ -88,7 +88,7 @@ app:
# 资源访问路径前缀 示例(/profile) # 资源访问路径前缀 示例(/profile)
profileUrl: /profile profileUrl: /profile
# 资源存储路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath) # 资源存储路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath)
profilePath: /home/ruisiCga/server/profile profilePath: D:/Projects/ruisi_cga/server/profile/
# 分布式ID-WorkID # 分布式ID-WorkID
workerId: 1 workerId: 1
# 分布式ID-DataCenterID # 分布式ID-DataCenterID

67
ruisi_java/ruisi-web-admin/src/main/resources/mapper/dao/RmsDao.xml

@ -1540,4 +1540,71 @@ d.dept_name as hospitalName
LEFT JOIN qms_scale q on rt.scale_code = q.code LEFT JOIN qms_scale q on rt.scale_code = q.code
ORDER BY evaluation_id, level, sort ORDER BY evaluation_id, level, sort
</select> </select>
<select id="viewReportPdfByVisitNo" resultType="com.ccsens.system.domain.vo.RmsVo$ReportPDF">
SELECT
r.id as reportId,
r.evaluation_id as evaluationId,
p.name as patientName,
p.sex,
r.patient_age as age,
p.birthday as birthDate,
p.idcard as idCard,
b.visit_type as visitType,
r.visit_no as visitNo,
b.department,
u.user_id as assessorId,
u.nick_name as assessor,
FROM_UNIXTIME(r.report_time /1000, '%Y-%m-%d %H:%i:%s') as assessTime,
r.url
FROM
rms_report r
LEFT JOIN pms_patient_body b on b.outpatient_no = r.visit_no
LEFT JOIN pms_patient p on b.patient_id = p.id
LEFT JOIN ems_evaluation e on r.evaluation_id = e.id and e.del_flag = 0
LEFT JOIN ums_user u on e.tester_id = u.user_id
WHERE
r.del_flag = 0
and p.del_flag = 0
and e.complete_status = 1
and r.visit_no = #{visitNo}
GROUP BY r.id
ORDER BY r.report_time desc
</select>
<select id="viewReportPdfByPatientNo" resultType="com.ccsens.system.domain.vo.RmsVo$ReportPDF">
SELECT
r.id as reportId,
r.evaluation_id as evaluationId,
p.name as patientName,
p.sex,
r.patient_age as age,
p.birthday as birthDate,
p.idcard as idCard,
b.visit_type as visitType,
r.visit_no as visitNo,
b.department,
u.user_id as assessorId,
u.nick_name as assessor,
FROM_UNIXTIME(r.report_time /1000, '%Y-%m-%d %H:%i:%s') as assessTime,
r.url
FROM
rms_report r
LEFT JOIN pms_patient_body b on b.outpatient_no = r.visit_no
LEFT JOIN pms_patient p on b.patient_id = p.id
LEFT JOIN ems_evaluation e on r.evaluation_id = e.id and e.del_flag = 0
LEFT JOIN ums_user u on e.tester_id = u.user_id
WHERE
r.del_flag = 0
and p.del_flag = 0
and e.complete_status = 1
and p.patient_no = #{patientNo}
GROUP BY r.id
ORDER BY r.report_time desc
</select>
</mapper> </mapper>

57
ruisi_java/ruisi-web-client/src/main/java/com/ccsens/client/controller/DockController.java

@ -0,0 +1,57 @@
package com.ccsens.client.controller;
import com.ccsens.common.annotation.Anonymous;
import com.ccsens.common.core.domain.JsonResponse;
import com.ccsens.system.domain.dto.DockDto;
import com.ccsens.system.service.DockService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import javax.annotation.Resource;
/**
* @Author zzc
* @Package com.ccsens.client.controller
* @Date 2026/2/9 10:12
* @description: 三方对接
* 1. 三方查询接口
* 2. 查询三方视图
* 3. 三方写入数据库提供数据库用户给三方
*/
@Slf4j
@Api(tags = "三方对接")
@RestController
@RequestMapping("/interface")
public class DockController {
@Resource
private DockService dockService;
@Anonymous
@ApiOperation("接收院内推送的待评估患者")
@PostMapping("/assessments/patient")
public JsonResponse<Integer> addDockPatient(@RequestBody @Validated DockDto.AddPatientDto dto){
return JsonResponse.ok(dockService.addDockPatient(dto));
}
@Anonymous
@ApiOperation("对接科室基本信息")
@PostMapping("/dept")
public JsonResponse<Integer> addDept(@RequestBody @Validated DockDto.DockDeptInfo dto){
dockService.addDept(dto);
return JsonResponse.ok();
}
@Anonymous
@ApiOperation("对接医护人员基本信息")
@PostMapping("/empl")
public JsonResponse<Integer> addEmpl(@RequestBody @Validated DockDto.DockEmplInfo dto){
dockService.addEmpl(dto);
return JsonResponse.ok();
}
}

65
ruisi_java/ruisi-web-client/src/main/java/com/ccsens/client/controller/scheduled/SyncHospitalData.java

@ -0,0 +1,65 @@
package com.ccsens.client.controller.scheduled;
import com.ccsens.common.annotation.DataSource;
import com.ccsens.common.core.domain.entity.SysDept;
import com.ccsens.common.core.domain.entity.SysUser;
import com.ccsens.common.enums.DataSourceType;
import com.ccsens.system.service.DockService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
import javax.annotation.Resource;
import java.util.List;
/**
* @author zy
* @date 2026/2/28 16:30
*/
@Slf4j
@Component
public class SyncHospitalData {
@Resource
private DockService dockService;
@DataSource(value = DataSourceType.SLAVE)
@Scheduled(cron = "0 */1 * * * ?")
public void syncHospitalData() {
dockService.syncHospitalData();
}
@DataSource(value = DataSourceType.SLAVE)
@Scheduled(cron = "0 */1 * * * ?")
public void syncDeptData() {
try {
List<SysDept> sysDepts = dockService.syncUmsDeptSlave();
syncDeptMaster(sysDepts);
}catch (Exception e){
log.error("部门信息同步失败",e);
}
}
@DataSource(value = DataSourceType.MASTER)
public void syncDeptMaster(List<SysDept> sysDepts) {
dockService.syncUmsDeptMaster(sysDepts);
}
@DataSource(value = DataSourceType.SLAVE)
@Scheduled(cron = "0 */1 * * * ?")
public void syncUserData() {
try {
List<SysUser> sysUsers = dockService.syncUmsUserSlave();
syncUserMaster(sysUsers);
}catch (Exception e){
log.error("用户信息同步失败",e);
}
}
@DataSource(value = DataSourceType.MASTER)
public void syncUserMaster(List<SysUser> sysUser) {
dockService.syncUmsUserMaster(sysUser);
}
}

24
ruisi_java/ruisi-web-client/src/main/resources/application-prod.yml

@ -12,10 +12,10 @@ spring:
# 从库数据源 # 从库数据源
slave: slave:
# 从数据源开关/默认关闭 # 从数据源开关/默认关闭
enabled: false enabled: true
url: url: jdbc:mysql://172.16.21.24:23306/ruisi_cga_hnszyyy?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
username: username: root
password: password: xian#2024!!!
# 初始连接数 # 初始连接数
initialSize: 5 initialSize: 5
# 最小连接池数量 # 最小连接池数量
@ -81,6 +81,20 @@ spring:
max-active: 8 max-active: 8
# #连接池最大阻塞等待时间(使用负值表示没有限制) # #连接池最大阻塞等待时间(使用负值表示没有限制)
max-wait: -1ms max-wait: -1ms
# 核心:SpringBoot全局UTF-8编码配置
server:
# 配置Tomcat容器UTF-8编码(关键,解决URI中文解码)
tomcat:
uri-encoding: UTF-8 # 强制Tomcat对URI进行UTF-8解码
relaxed-path-chars: [ '%', '#', '&', '=', '|', ',', ';', '\\', ' ', '中' ] # 允许路径包含中文/特殊符号
# 全局请求/响应编码
servlet:
encoding:
enabled: true # 开启编码自动配置
charset: UTF-8 # 编码格式
force: true # 强制所有请求/响应使用UTF-8(覆盖容器默认编码)
force-request: true # 强制请求编码为UTF-8
force-response: true # 强制响应编码为UTF-8
app: app:
# 是否开启调式模式 # 是否开启调式模式
@ -117,5 +131,5 @@ informed:
clientVersion: v1.8.3.0 clientVersion: v1.8.3.0
# 医院id,不同医院部署的时候需要修改 # 医院id,不同医院部署的时候需要修改
hospitalId: 174 hospitalId: 178
generalPassword: cga123# generalPassword: cga123#

209
sql/数据对接.sql

@ -0,0 +1,209 @@
DROP TABLE IF EXISTS `dock_dept`;
CREATE TABLE `dock_dept` (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '表ID(自增)',
`dept_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '科室名称',
`dept_code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '编码',
`del_flag` char(1) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
`create_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '创建者',
`create_time` timestamp NOT NULL DEFAULT current_timestamp() COMMENT '创建时间',
`update_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '更新者',
`update_time` timestamp NULL DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
`sync` varchar(20) NULL DEFAULT '0' COMMENT '是否同步 0否 1是',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '三方部门表' ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Table structure for dock_empl
-- ----------------------------
DROP TABLE IF EXISTS `dock_empl`;
CREATE TABLE `dock_empl` (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '表ID(自增)',
`empl_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '姓名',
`empl_code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '工号或者账号',
`empl_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '医生或者护士身份判断标识',
`dept_code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '所属科室编码',
`del_flag` char(1) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '0' COMMENT '删除标志(0代表存在 2代表删除)',
`create_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '创建者',
`create_time` timestamp NOT NULL DEFAULT current_timestamp() COMMENT '创建时间',
`update_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '更新者',
`update_time` timestamp NULL DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
`sync` varchar(20) NULL DEFAULT '0' COMMENT '是否同步 0否 1是',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '三方员工表' ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Records of dock_empl
-- ----------------------------
-- ----------------------------
-- Table structure for dock_patient_base_info
-- ----------------------------
DROP TABLE IF EXISTS `dock_patient_base_info`;
CREATE TABLE `dock_patient_base_info` (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '表ID(自增)',
`name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '姓名',
`patient_no` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '患者唯一编号',
`id_card` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '证件号码(身份证号)',
`phone` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '联系电话',
`sex` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '性别:0女、1男',
`birthday` date NULL DEFAULT NULL COMMENT '出生日期',
`educational_status` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '受教育程度:0文盲、1小学、2初中、3高中/技校/中专、4大学/专科及以上',
`career` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '职业类型:1:农林牧渔水利生产人员 2:教师 3:医务工作者 4:专业技术人员 5:生产、运输设备操作人员及有关人员6:商业、服务业人员7:国家机关、事业单位、企业负责人8:国家机关、事业单位、企业办事人员和有关人员9:军人 10:媒体、文体类工作人员 11:在校学生 12:未就业 13:家务 14:其他',
`marital_status` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '婚姻状况:0已婚、1未婚、2离婚、3丧偶、4未知',
`nation` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '民族',
`native_place` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '籍贯',
`address` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '现住址',
`dwelling_state` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '居住状态:0独居、1夫妻同住、2多代加入同住、3养老院、4其他',
`contact_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '联系人姓名',
`contact_mobile` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '联系人电话',
`contact_relation` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '与联系人关系',
`abo_blood_type` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT 'ABO血型',
`rh_blood_type` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT 'Rh血型',
`belief` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '信仰',
`hobby` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '爱好',
`create_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建者的用户名',
`create_time` timestamp NOT NULL DEFAULT current_timestamp() COMMENT ' 创建时间 ',
`update_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '更新者的用户名',
`update_time` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE CURRENT_TIMESTAMP COMMENT ' 修改时间 ',
`del_flag` tinyint NULL DEFAULT 0 COMMENT '记录状态 0-正常 1-删除',
`remark` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注',
`sync` varchar(20) NULL DEFAULT '0' COMMENT '是否同步 0否 1是',
PRIMARY KEY (`id`) USING BTREE,
UNIQUE INDEX `idx_id_card`(`id_card` ASC) USING BTREE,
INDEX `idx_phone`(`phone` ASC) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 19 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '患者基础信息表' ROW_FORMAT = Dynamic;
-- ----------------------------
-- Table structure for dock_patient_diagnosis
-- ----------------------------
DROP TABLE IF EXISTS `dock_patient_diagnosis`;
CREATE TABLE `dock_patient_diagnosis` (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '表ID(自增)',
`visit_no` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '就诊流水号,关联就诊信息表的就诊号',
`diagnosis_type` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '诊断类型(如门诊诊断、出院诊断)',
`is_main_diagnosis` tinyint(1) NULL DEFAULT NULL COMMENT '是否主要诊断:0=否,1=是',
`diagnosis_name` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '诊断名称(如高血压2级)',
`diagnosis_code` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '诊断编码(如ICD-10编码)',
`diagnosis_date` date NULL DEFAULT NULL COMMENT '诊断日期',
`create_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建者的用户名',
`create_time` timestamp NOT NULL DEFAULT current_timestamp() COMMENT ' 创建时间 ',
`update_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '更新者的用户名',
`update_time` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE CURRENT_TIMESTAMP COMMENT ' 修改时间 ',
`del_flag` tinyint NULL DEFAULT 0 COMMENT '记录状态 0-正常 1-删除',
`remark` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注',
`sync` varchar(20) NULL DEFAULT '0' COMMENT '是否同步 0否 1是',
PRIMARY KEY (`id`) USING BTREE,
INDEX `idx_diagnosis_visit_no`(`visit_no` ASC) USING BTREE,
INDEX `idx_diagnosis_code`(`diagnosis_code` ASC) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 9 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '患者诊断信息表' ROW_FORMAT = Dynamic;
-- ----------------------------
-- Table structure for dock_patient_medication_info
-- ----------------------------
DROP TABLE IF EXISTS `dock_patient_medication_info`;
CREATE TABLE `dock_patient_medication_info` (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '表ID(自增)',
`visit_no` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '门诊/住院号,关联就诊信息表的就诊号',
`drug_name` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '药物名称',
`dose` decimal(10, 2) NULL DEFAULT NULL COMMENT '剂量',
`unit` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '单位(如mg、ml、片)',
`frequency` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '用药频率(如每日3次、每8小时1次)',
`create_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建者的用户名',
`create_time` timestamp NOT NULL DEFAULT current_timestamp() COMMENT ' 创建时间 ',
`update_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '更新者的用户名',
`update_time` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE CURRENT_TIMESTAMP COMMENT ' 修改时间 ',
`del_flag` tinyint NULL DEFAULT 0 COMMENT '记录状态 0-正常 1-删除',
`remark` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注',
`sync` varchar(20) NULL DEFAULT '0' COMMENT '是否同步 0否 1是',
PRIMARY KEY (`id`) USING BTREE,
INDEX `idx_med_visit_no`(`visit_no` ASC) USING BTREE,
INDEX `idx_drug_name`(`drug_name` ASC) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 2 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '患者用药信息表' ROW_FORMAT = Dynamic;
-- ----------------------------
-- Table structure for dock_patient_visit_info
-- ----------------------------
DROP TABLE IF EXISTS `dock_patient_visit_info`;
CREATE TABLE `dock_patient_visit_info` (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '表ID(自增)',
`id_card` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '证件号码',
`patient_no` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '患者唯一编号',
`visit_type` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '就诊类型',
`visit_no` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '门诊/住院号',
`age` int NULL DEFAULT NULL COMMENT '年龄',
`department` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '就诊/住院科室',
`doctor` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '就诊/主治医师',
`admission_date` datetime NULL DEFAULT NULL COMMENT '就诊/入院日期',
`admission_count` int NULL DEFAULT NULL COMMENT '住院次数',
`bed_number` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '床位号',
`discharge_date` datetime NULL DEFAULT NULL COMMENT '出院日期',
`admission_method` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '入院途径',
`discharge_method` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '离院方式',
`height` decimal(5, 2) NULL DEFAULT NULL COMMENT '身高,单位:厘米',
`weight` decimal(5, 2) NULL DEFAULT NULL COMMENT '体重,单位:千克',
`tz` decimal(5, 2) NULL DEFAULT NULL COMMENT 'T值',
`temperature` decimal(4, 2) NULL DEFAULT NULL COMMENT '体温,单位:摄氏度',
`blood_pressure_shrink` int NULL DEFAULT NULL COMMENT '收缩压',
`blood_pressure_diastole` int NULL DEFAULT NULL COMMENT '舒张压',
`pulse` int NULL DEFAULT NULL COMMENT '脉搏',
`creatinine` decimal(6, 2) NULL DEFAULT NULL COMMENT '肌酐',
`oxygen_saturation` decimal(5, 2) NULL DEFAULT NULL COMMENT '血氧饱和度',
`albumin` decimal(5, 2) NULL DEFAULT NULL COMMENT '白蛋白',
`total_protein` decimal(5, 2) NULL DEFAULT NULL COMMENT '总蛋白',
`vitamin_d3` decimal(5, 2) NULL DEFAULT NULL COMMENT '维生素D3测定',
`hematocrit` decimal(5, 2) NULL DEFAULT NULL COMMENT '凝血酶原时间',
`dimer` decimal(6, 2) NULL DEFAULT NULL COMMENT 'D-二聚体',
`smoking_history` tinyint(1) NULL DEFAULT NULL COMMENT '是否吸烟,0=否,1=是',
`smoking_year` int NULL DEFAULT NULL COMMENT '吸烟年限',
`smoking_quit` tinyint(1) NULL DEFAULT NULL COMMENT '是否戒烟,0=否,1=是',
`smoking_quit_year` int NULL DEFAULT NULL COMMENT '戒烟年限',
`drink_history` tinyint(1) NULL DEFAULT NULL COMMENT '是否饮酒,0=否,1=是',
`drink_year` int NULL DEFAULT NULL COMMENT '饮酒年限',
`drink_quit` tinyint(1) NULL DEFAULT NULL COMMENT '是否戒酒,0=否,1=是',
`drink_quit_year` int NULL DEFAULT NULL COMMENT '戒酒年限',
`has_allergy` tinyint(1) NULL DEFAULT NULL COMMENT '是否过敏,0=否,1=是',
`allergy_drug` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '过敏药',
`create_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建者的用户名',
`create_time` timestamp NOT NULL DEFAULT current_timestamp() COMMENT ' 创建时间 ',
`update_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '更新者的用户名',
`update_time` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE CURRENT_TIMESTAMP COMMENT ' 修改时间 ',
`del_flag` tinyint NULL DEFAULT 0 COMMENT '记录状态 0-正常 1-删除',
`remark` varchar(500) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注',
`sync` varchar(20) NULL DEFAULT '0' COMMENT '是否同步 0否 1是',
PRIMARY KEY (`id`) USING BTREE,
UNIQUE INDEX `idx_visit_no`(`visit_no` ASC) USING BTREE,
INDEX `idx_id_card`(`id_card` ASC) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '患者就诊信息表' ROW_FORMAT = Dynamic;
-- 患者表添加字段
ALTER TABLE `pms_patient`
ADD COLUMN `patient_no` varchar(50) COMMENT '患者院内唯一编号';
-- 主库从库都需要修改部门和用户表,加字段
ALTER TABLE `ums_user`
ADD COLUMN `empl_code` varchar(30) DEFAULT '' COMMENT '工号' AFTER `nick_name`;
ALTER TABLE `ums_dept`
ADD COLUMN `dept_code` varchar(30) DEFAULT '' COMMENT '科室编码' AFTER `dept_name`;
CREATE TABLE `ems_evaluation_scale_cognitive_relevance` (
`id` bigint(20) NOT NULL,
`evaluation_id` bigint(20) DEFAULT 0 COMMENT '测评id',
`scale_code` varchar(20) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT ' 量表code ',
`parent_id` bigint(20) DEFAULT NULL COMMENT '认知域父级CODE',
`cognitive_code` varchar(20) DEFAULT '' COMMENT '认知域code',
`score` decimal(11,1) DEFAULT NULL COMMENT '得分',
`total_score` decimal(10,1) DEFAULT NULL COMMENT '总分',
`combo_id` bigint(20) DEFAULT NULL COMMENT '套餐ID',
`sort` int(11) DEFAULT 0 COMMENT ' 排序',
`create_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '创建者的用户名',
`create_time` timestamp NOT NULL DEFAULT current_timestamp() COMMENT ' 创建时间 ',
`update_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '更新者的用户名',
`update_time` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp() COMMENT ' 修改时间 ',
`del_flag` tinyint(3) unsigned DEFAULT 0 COMMENT ' 是否删除(1:是 0:否) ',
PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_general_ci ROW_FORMAT=DYNAMIC COMMENT='测评量表认知域得分表';
ALTER TABLE `ruisi_cga_yf1`.`ems_evaluation_scale_relevance`
ADD COLUMN `combo_id` bigint NULL AFTER `scale_code`;
Loading…
Cancel
Save