修改就诊记录、素材库管理。
This commit is contained in:
parent
d646a62680
commit
657dbb5007
@ -3,6 +3,7 @@ package com.xinelu.manage.controller.patientinfo;
|
||||
import com.xinelu.common.annotation.Log;
|
||||
import com.xinelu.common.core.controller.BaseController;
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.core.domain.R;
|
||||
import com.xinelu.common.core.page.TableDataInfo;
|
||||
import com.xinelu.common.enums.BusinessType;
|
||||
import com.xinelu.common.utils.poi.ExcelUtil;
|
||||
@ -77,8 +78,8 @@ public class PatientInfoController extends BaseController {
|
||||
@PreAuthorize("@ss.hasPermi('manage:patientInfo:add')")
|
||||
@Log(title = "患者信息", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody PatientInfo patientInfo) {
|
||||
return toAjax(patientInfoService.insertPatientInfo(patientInfo));
|
||||
public R<PatientInfo> add(@RequestBody PatientInfo patientInfo) {
|
||||
return R.ok(patientInfoService.insertPatientInfo(patientInfo));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -5,7 +5,6 @@ import com.xinelu.common.constant.Constants;
|
||||
import com.xinelu.common.core.controller.BaseController;
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.core.domain.R;
|
||||
import com.xinelu.common.core.page.TableDataInfo;
|
||||
import com.xinelu.common.enums.BusinessType;
|
||||
import com.xinelu.common.utils.poi.ExcelUtil;
|
||||
import com.xinelu.manage.domain.patientvisitrecord.PatientVisitRecord;
|
||||
@ -48,17 +47,6 @@ public class PatientVisitRecordController extends BaseController {
|
||||
@Resource
|
||||
private IPatientVisitRecordService patientVisitRecordService;
|
||||
|
||||
/**
|
||||
* 查询患者就诊记录基本信息列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('manage:visit:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(PatientVisitRecordDto patientVisitRecord) {
|
||||
startPage();
|
||||
List<PatientVisitRecord> list = patientVisitRecordService.selectPatientVisitRecordList(patientVisitRecord);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询患者就诊记录基本信息列表
|
||||
*/
|
||||
|
||||
@ -10,9 +10,11 @@ import com.xinelu.common.utils.poi.ExcelUtil;
|
||||
import com.xinelu.manage.domain.propagandainfo.PropagandaInfo;
|
||||
import com.xinelu.manage.dto.department.DepartmentDTO;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaInfoDto;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaInfoSaveDto;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaUpdateDto;
|
||||
import com.xinelu.manage.service.propagandainfo.IPropagandaInfoService;
|
||||
import com.xinelu.manage.vo.department.DepartmentVO;
|
||||
import com.xinelu.manage.vo.propagandainfo.PropagandaMaterialsVo;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import java.util.List;
|
||||
@ -71,8 +73,8 @@ public class PropagandaInfoController extends BaseController {
|
||||
@ApiOperation("根据id获取宣教库管理详细信息")
|
||||
@PreAuthorize("@ss.hasPermi('manage:propaganda:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") Long id) {
|
||||
return AjaxResult.success(propagandaInfoService.selectPropagandaInfoById(id));
|
||||
public R<PropagandaMaterialsVo> getInfo(@PathVariable("id") Long id) {
|
||||
return R.ok(propagandaInfoService.selectPropagandaInfoById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -82,8 +84,8 @@ public class PropagandaInfoController extends BaseController {
|
||||
@PreAuthorize("@ss.hasPermi('manage:propaganda:add')")
|
||||
@Log(title = "宣教库管理", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody PropagandaInfo propagandaInfo) {
|
||||
return toAjax(propagandaInfoService.insertPropagandaInfo(propagandaInfo));
|
||||
public AjaxResult add(@RequestBody PropagandaInfoSaveDto propagandaInfoSaveDto) {
|
||||
return toAjax(propagandaInfoService.insertPropagandaInfo(propagandaInfoSaveDto));
|
||||
}
|
||||
|
||||
/**
|
||||
@ -93,8 +95,8 @@ public class PropagandaInfoController extends BaseController {
|
||||
@PreAuthorize("@ss.hasPermi('manage:propaganda:edit')")
|
||||
@Log(title = "宣教库管理", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody PropagandaInfo propagandaInfo) {
|
||||
return toAjax(propagandaInfoService.updatePropagandaInfo(propagandaInfo));
|
||||
public AjaxResult edit(@RequestBody PropagandaInfoSaveDto propagandaInfoSaveDto) {
|
||||
return toAjax(propagandaInfoService.updatePropagandaInfo(propagandaInfoSaveDto));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@ -3,6 +3,7 @@ package com.xinelu.manage.controller.signpatientrecord;
|
||||
import com.xinelu.common.core.controller.BaseController;
|
||||
import com.xinelu.common.core.domain.R;
|
||||
import com.xinelu.common.core.page.TableDataInfo;
|
||||
import com.xinelu.manage.dto.signpatientrecord.IntentionalSignDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientAddDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientListDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientStatusDto;
|
||||
@ -48,6 +49,17 @@ public class SignPatientRecordController extends BaseController {
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 意向签约
|
||||
*/
|
||||
@ApiOperation("意向签约")
|
||||
@PreAuthorize("@ss.hasPermi('manage:signRecord:add')")
|
||||
@PostMapping("/intentionalSign")
|
||||
public R<String> intentionalSign(@Valid @RequestBody IntentionalSignDto body) {
|
||||
int flag = signPatientRecordService.intentionalSign(body);
|
||||
return flag > 0 ? R.ok() : R.fail();
|
||||
}
|
||||
|
||||
/**
|
||||
* 签约
|
||||
*/
|
||||
|
||||
@ -118,4 +118,7 @@ public class MaterialsInfo extends BaseEntity {
|
||||
@Excel(name = "素材排序,值越小排序越靠前")
|
||||
private Integer materialsSort;
|
||||
|
||||
/** 删除标识,0:未删除,1:已删除 */
|
||||
private Integer delFlag;
|
||||
|
||||
}
|
||||
|
||||
@ -30,6 +30,10 @@ public class PatientInfo extends BaseEntity {
|
||||
/** 主键id */
|
||||
private Long id;
|
||||
|
||||
/** 居民信息表id */
|
||||
@ApiModelProperty(value = "居民信息表id")
|
||||
private Long residentId;
|
||||
|
||||
/** 患者姓名 */
|
||||
@ApiModelProperty(value = "患者姓名")
|
||||
@Excel(name = "患者姓名")
|
||||
@ -196,14 +200,6 @@ public class PatientInfo extends BaseEntity {
|
||||
@Excel(name = "出院方式", readConverterExp = "出=院患者")
|
||||
private String dischargeMethod;
|
||||
|
||||
/** 微信openid,微信小程序唯一标识 */
|
||||
@ApiModelProperty(value = "微信openid,微信小程序唯一标识")
|
||||
private String openId;
|
||||
|
||||
/** 微信unionid,微信小程序和微信公众号统一标识 */
|
||||
@ApiModelProperty(value = "微信unionid,微信小程序和微信公众号统一标识 ")
|
||||
private String unionId;
|
||||
|
||||
/** 患者来源,微信小程序:WE_CHAT_APPLET,微信公众号:WE_CHAT_OFFICIAL_ACCOUNT,管理端:MANAGE_END */
|
||||
@ApiModelProperty(value = "患者来源,微信小程序:WE_CHAT_APPLET,微信公众号:WE_CHAT_OFFICIAL_ACCOUNT,管理端:MANAGE_END")
|
||||
@Excel(name = "患者来源,微信小程序:WE_CHAT_APPLET,微信公众号:WE_CHAT_OFFICIAL_ACCOUNT,管理端:MANAGE_END")
|
||||
|
||||
@ -20,6 +20,12 @@ public class PatientPreHospitalization extends BaseEntity {
|
||||
*/
|
||||
@ApiModelProperty("主键Id")
|
||||
private Long id;
|
||||
/**
|
||||
* 居民信息表id
|
||||
*/
|
||||
@ApiModelProperty("居民信息表id")
|
||||
private Long residentId;
|
||||
|
||||
/**
|
||||
* 患者表id
|
||||
*/
|
||||
|
||||
@ -29,6 +29,10 @@ public class PatientVisitRecord extends BaseEntity {
|
||||
/** 主键Id */
|
||||
private Long id;
|
||||
|
||||
/** 居民信息表id */
|
||||
@ApiModelProperty(value = "居民信息表id")
|
||||
private Long residentId;
|
||||
|
||||
/** 患者表id */
|
||||
@ApiModelProperty(value = "患者表id")
|
||||
@Excel(name = "患者表id")
|
||||
@ -218,4 +222,11 @@ public class PatientVisitRecord extends BaseEntity {
|
||||
@Excel(name = "手术名称")
|
||||
private String surgicalName;
|
||||
|
||||
/** 手术记录 */
|
||||
@ApiModelProperty(value = "手术记录")
|
||||
private String surgicalRecord;
|
||||
|
||||
/** 删除标识,0:未删除,1:已删除 */
|
||||
private Integer delFlag;
|
||||
|
||||
}
|
||||
|
||||
@ -33,7 +33,7 @@ public class PropagandaMaterials extends BaseEntity {
|
||||
|
||||
/** 宣教名称(宣教标题) */
|
||||
@ApiModelProperty(value = "宣教名称")
|
||||
@Excel(name = "宣教名称", readConverterExp = "宣=教标题")
|
||||
@Excel(name = "宣教名称", readConverterExp = "宣教标题")
|
||||
private String propagandaTitle;
|
||||
|
||||
/** 素材表id */
|
||||
@ -46,5 +46,6 @@ public class PropagandaMaterials extends BaseEntity {
|
||||
@Excel(name = "素材名称")
|
||||
private String materialsName;
|
||||
|
||||
|
||||
/** 删除标识,0:未删除,1:已删除 */
|
||||
private Integer delFlag;
|
||||
}
|
||||
|
||||
@ -0,0 +1,82 @@
|
||||
package com.xinelu.manage.domain.residentinfo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.xinelu.common.annotation.Excel;
|
||||
import com.xinelu.common.core.domain.BaseEntity;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.Date;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* 居民信息对象 resident_info
|
||||
*
|
||||
* @author haown
|
||||
* @date 2024-03-27
|
||||
*/
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@ApiModel(value = "居民信息对象", description = "resident_info")
|
||||
public class ResidentInfo extends BaseEntity {
|
||||
private static final long serialVersionUID=1L;
|
||||
|
||||
/** 主键id */
|
||||
private Long id;
|
||||
|
||||
/** 姓名 */
|
||||
@ApiModelProperty(value = "姓名")
|
||||
@Excel(name = "姓名")
|
||||
private String patientName;
|
||||
|
||||
/** 电话 */
|
||||
@ApiModelProperty(value = "电话")
|
||||
@Excel(name = "电话")
|
||||
private String patientPhone;
|
||||
|
||||
/** 家属电话 */
|
||||
@ApiModelProperty(value = "家属电话")
|
||||
@Excel(name = "家属电话")
|
||||
private String familyMemberPhone;
|
||||
|
||||
/** 出生日期,格式:yyyy-MM-dd */
|
||||
@ApiModelProperty(value = "出生日期,格式:yyyy-MM-dd")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@Excel(name = "出生日期,格式:yyyy-MM-dd", width = 30, dateFormat = "yyyy-MM-dd")
|
||||
private Date birthDate;
|
||||
|
||||
/** 身份证号 */
|
||||
@ApiModelProperty(value = "身份证号")
|
||||
@Excel(name = "身份证号")
|
||||
private String cardNo;
|
||||
|
||||
/** 性别,男:MALE,女:FEMALE */
|
||||
@ApiModelProperty(value = "性别,男:MALE,女:FEMALE")
|
||||
@Excel(name = "性别,男:MALE,女:FEMALE")
|
||||
private String sex;
|
||||
|
||||
/** 住址 */
|
||||
@ApiModelProperty(value = "住址")
|
||||
@Excel(name = "住址")
|
||||
private String address;
|
||||
|
||||
/** 微信小程序openid,微信小程序唯一标识 */
|
||||
@ApiModelProperty(value = "微信小程序openid,微信小程序唯一标识")
|
||||
@Excel(name = "微信小程序openid,微信小程序唯一标识")
|
||||
private String openId;
|
||||
|
||||
/** 微信unionid,微信小程序和微信公众号统一标识 */
|
||||
@ApiModelProperty(value = "微信unionid,微信小程序和微信公众号统一标识")
|
||||
@Excel(name = "微信unionid,微信小程序和微信公众号统一标识")
|
||||
private String unionId;
|
||||
|
||||
/** 微信公众号openid,微信公众号唯一标识 */
|
||||
@ApiModelProperty(value = "微信公众号openid,微信公众号唯一标识")
|
||||
@Excel(name = "微信公众号openid,微信公众号唯一标识")
|
||||
private String officialAccountOpenid;
|
||||
|
||||
}
|
||||
@ -1,11 +1,11 @@
|
||||
package com.xinelu.manage.dto.materialsinfo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.xinelu.common.annotation.Excel;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.time.LocalDate;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
/**
|
||||
* @description: 素材库查询传输对象
|
||||
@ -17,11 +17,11 @@ import lombok.Data;
|
||||
public class MaterialsInfoDto {
|
||||
|
||||
@ApiModelProperty(value = "创建时间开始,yyyy-MM-dd")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDate createTimeStart;
|
||||
|
||||
@ApiModelProperty(value = "创建时间结束,yyyy-MM-dd")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDate createTimeEnd;
|
||||
|
||||
/** 素材状态,已上架:LISTED,未上架:NOT_LISTED */
|
||||
|
||||
@ -92,7 +92,7 @@ public class PatientInfoDto {
|
||||
|
||||
/** 开证医生(预住院患者) */
|
||||
@ApiModelProperty(value = "开证医生")
|
||||
private String certificateIssuingDoctor;
|
||||
private String certificateIssuingDoctorId;
|
||||
|
||||
/** 登记号(预住院患者) */
|
||||
@ApiModelProperty(value = "登记号(预住院患者)")
|
||||
|
||||
@ -14,6 +14,10 @@ import org.springframework.format.annotation.DateTimeFormat;
|
||||
@Data
|
||||
public class PatientVisitRecordDto {
|
||||
|
||||
/** 居民信息表id */
|
||||
@ApiModelProperty(value = "居民信息表id")
|
||||
private Long residentId;
|
||||
|
||||
/** 患者表id */
|
||||
@ApiModelProperty(value = "患者表id")
|
||||
private Long patientId;
|
||||
|
||||
@ -120,4 +120,9 @@ public class PatientVisitRecordInfoSaveDto {
|
||||
@Excel(name = "手术名称")
|
||||
private String surgicalName;
|
||||
|
||||
/** 手术记录 */
|
||||
@ApiModelProperty(value = "手术记录")
|
||||
@Excel(name = "手术记录")
|
||||
private String surgicalRecord;
|
||||
|
||||
}
|
||||
|
||||
@ -159,4 +159,8 @@ public class PatientVisitRecordSaveDto {
|
||||
@ApiModelProperty(value = "患者类型,预住院患者:PRE_HOSPITALIZED_PATIENT,在院患者:IN_HOSPITAL_PATIENT,门诊患者:OUTPATIENT,出院患者:DISCHARGED_PATIENT,签约患者:CONTRACTED_PATIENT")
|
||||
@NotNull(message = "患者类型不能为空")
|
||||
private String patientType;
|
||||
|
||||
/** 手术记录 */
|
||||
@ApiModelProperty(value = "手术记录")
|
||||
private String surgicalRecord;
|
||||
}
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
package com.xinelu.manage.dto.propagandainfo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.xinelu.common.annotation.Excel;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.time.LocalDate;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
/**
|
||||
* @description: 宣教库查询传输对象
|
||||
@ -55,13 +55,13 @@ public class PropagandaInfoDto {
|
||||
* 创建时间
|
||||
*/
|
||||
@ApiModelProperty(value = "创建时间开始")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDate createTimeStart;
|
||||
|
||||
/**
|
||||
* 创建时间
|
||||
*/
|
||||
@ApiModelProperty(value = "创建时间结束")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private LocalDate createTimeEnd;
|
||||
}
|
||||
|
||||
@ -0,0 +1,92 @@
|
||||
package com.xinelu.manage.dto.propagandainfo;
|
||||
|
||||
import com.xinelu.common.annotation.Excel;
|
||||
import com.xinelu.manage.domain.materialsinfo.MaterialsInfo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.List;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @description: 宣教库保存传输对象
|
||||
* @author: haown
|
||||
* @create: 2024-03-28 09:08
|
||||
**/
|
||||
@ApiModel("宣教库保存传输对象")
|
||||
@Data
|
||||
public class PropagandaInfoSaveDto {
|
||||
/** 所属医院id */
|
||||
@ApiModelProperty(value = "所属医院id")
|
||||
private Long hospitalAgencyId;
|
||||
|
||||
/** 所属医院名称 */
|
||||
@ApiModelProperty(value = "所属医院名称")
|
||||
@Excel(name = "所属医院名称")
|
||||
private String hospitalAgencyName;
|
||||
|
||||
/** 所属科室id */
|
||||
@ApiModelProperty(value = "所属科室id")
|
||||
private Long departmentId;
|
||||
|
||||
/** 所属科室名称 */
|
||||
@ApiModelProperty(value = "所属科室名称")
|
||||
@Excel(name = "所属科室名称")
|
||||
private String departmentName;
|
||||
|
||||
/** 宣教标题(宣教名称) */
|
||||
@ApiModelProperty(value = "宣教标题")
|
||||
@Excel(name = "宣教标题", readConverterExp = "宣教名称")
|
||||
private String propagandaTitle;
|
||||
|
||||
/** 宣教类型,用药知识:MEDICATION_KNOWLEDGE,疾病科普:DISEASE_POPULARIZATION,运动营养:SPORT_NUTRITION,其他知识:OTHER_KNOWLEDGE,
|
||||
定制内容:CUSTOMIZED_CONTENT */
|
||||
@ApiModelProperty(value = "宣教类型,用药知识:MEDICATION_KNOWLEDGE,疾病科普:DISEASE_POPULARIZATION,运动营养:SPORT_NUTRITION,其他知识:OTHER_KNOWLEDGE,定制内容:CUSTOMIZED_CONTENT")
|
||||
@Excel(name = "宣教类型,用药知识:MEDICATION_KNOWLEDGE,疾病科普:DISEASE_POPULARIZATION,运动营养:SPORT_NUTRITION,其他知识:OTHER_KNOWLEDGE,定制内容:CUSTOMIZED_CONTENT")
|
||||
private String propagandaType;
|
||||
|
||||
/** 宣教ID */
|
||||
@ApiModelProperty(value = "宣教ID")
|
||||
private String propagandaCode;
|
||||
|
||||
/** 宣教状态,创作中:CREATE_PROCESS,创作完成:CREATE_COMPLETE,审核中:IN_REVIEW,审核通过:APPROVED,审核不通过:REVIEW_FAILED */
|
||||
@ApiModelProperty(value = "宣教状态,创作中:CREATE_PROCESS,创作完成:CREATE_COMPLETE,审核中:IN_REVIEW,审核通过:APPROVED,审核不通过:REVIEW_FAILED")
|
||||
@Excel(name = "宣教状态,创作中:CREATE_PROCESS,创作完成:CREATE_COMPLETE,审核中:IN_REVIEW,审核通过:APPROVED,审核不通过:REVIEW_FAILED")
|
||||
private String propagandaStatus;
|
||||
|
||||
/** 宣教正文内容 */
|
||||
@ApiModelProperty(value = "宣教正文内容")
|
||||
private String propagandaContent;
|
||||
|
||||
/** 宣教封面文件存放地址 */
|
||||
@ApiModelProperty(value = "宣教封面文件存放地址")
|
||||
private String propagandaCoverPath;
|
||||
|
||||
/** 宣教文章摘要 */
|
||||
@ApiModelProperty(value = "宣教文章摘要")
|
||||
private String articleSummary;
|
||||
|
||||
/** 语音播报 */
|
||||
@ApiModelProperty(value = "语音播报")
|
||||
private String voicebroadcast;
|
||||
|
||||
/** 所属病种id */
|
||||
@ApiModelProperty(value = "所属病种id")
|
||||
private Long diseaseTypeId;
|
||||
|
||||
/** 所属病种名称 */
|
||||
@ApiModelProperty(value = "所属病种名称")
|
||||
@Excel(name = "所属病种名称")
|
||||
private String diseaseTypeName;
|
||||
|
||||
/** 宣教链接 */
|
||||
@ApiModelProperty(value = "宣教链接")
|
||||
private String propagandaLink;
|
||||
|
||||
/** 宣教二维码图片存放地址 */
|
||||
@ApiModelProperty(value = "宣教二维码图片存放地址")
|
||||
private String propagandaBarcodePath;
|
||||
|
||||
/** 所选素材对象列表 */
|
||||
@ApiModelProperty(value = "所选素材对象列表")
|
||||
List<MaterialsInfo> materialsInfoList;
|
||||
}
|
||||
@ -0,0 +1,32 @@
|
||||
package com.xinelu.manage.dto.signpatientrecord;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @description: 意向签约传输对象
|
||||
* @author: haown
|
||||
* @create: 2024-03-28 16:51
|
||||
**/
|
||||
@ApiModel("意向签约传输对象")
|
||||
@Data
|
||||
public class IntentionalSignDto {
|
||||
|
||||
@ApiModelProperty("患者信息表id")
|
||||
@NotNull(message = "患者信息不能为空")
|
||||
private Long patientId;
|
||||
|
||||
@ApiModelProperty("开单医生id(意向签约)")
|
||||
@NotNull(message = "开单医生不能为空")
|
||||
private Long billingDoctorId;
|
||||
|
||||
@ApiModelProperty("开单医生姓名(意向签约)")
|
||||
@NotNull(message = "开单医生不能为空")
|
||||
private String billingDoctorName;
|
||||
|
||||
@ApiModelProperty("意向来源(意向签约,字典枚举),DOCTOR_BILLING:医生开单")
|
||||
@NotNull(message = "意向来源不能为空")
|
||||
private String intentionalSource;
|
||||
}
|
||||
@ -41,4 +41,7 @@ public class SignPatientAddDto {
|
||||
|
||||
private List<SignPatientInformed> informeds;
|
||||
|
||||
@ApiModelProperty("签约类型,签约:sign, 续约:reSign")
|
||||
private String signCategory;
|
||||
|
||||
}
|
||||
|
||||
@ -1,10 +1,10 @@
|
||||
package com.xinelu.manage.mapper.patientvisitrecord;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import java.util.Collection;
|
||||
|
||||
import com.xinelu.manage.domain.patientvisitrecord.PatientVisitRecord;
|
||||
import com.xinelu.manage.dto.patientvisitrecord.PatientVisitRecordDto;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
/**
|
||||
* 患者就诊记录基本信息Mapper接口
|
||||
@ -64,4 +64,12 @@ public interface PatientVisitRecordMapper {
|
||||
|
||||
PatientVisitRecord judgeRepeat(@Param("hospitalAgencyId") Long hospitalAgencyId, @Param("cardNo") String cardNo,
|
||||
@Param("inHospitalNumber") String inHospitalNumber);
|
||||
|
||||
/**
|
||||
* 获取居民在当前机构最新一条就诊记录
|
||||
* @param hospitalAgencyId 机构id
|
||||
* @param patientId 患者id
|
||||
* @return 结果
|
||||
*/
|
||||
PatientVisitRecord getLastRecord(@Param("hospitalAgencyId") Long hospitalAgencyId, @Param("patientId") Long patientId);
|
||||
}
|
||||
|
||||
@ -4,6 +4,7 @@ import com.xinelu.manage.domain.propagandainfo.PropagandaInfo;
|
||||
import com.xinelu.manage.dto.department.DepartmentDTO;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaInfoDto;
|
||||
import com.xinelu.manage.vo.department.DepartmentVO;
|
||||
import com.xinelu.manage.vo.propagandainfo.PropagandaMaterialsVo;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@ -21,6 +22,14 @@ public interface PropagandaInfoMapper {
|
||||
*/
|
||||
public PropagandaInfo selectPropagandaInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 查询宣教素材信息
|
||||
*
|
||||
* @param id 宣教库管理主键
|
||||
* @return 宣教库管理
|
||||
*/
|
||||
PropagandaMaterialsVo selectPropagandaInfo(Long id);
|
||||
|
||||
/**
|
||||
* 查询宣教库管理列表
|
||||
*
|
||||
|
||||
@ -35,6 +35,7 @@ public interface PropagandaMaterialsMapper {
|
||||
*/
|
||||
public int insertPropagandaMaterials(PropagandaMaterials propagandaMaterials);
|
||||
|
||||
|
||||
/**
|
||||
* 修改宣教素材关系
|
||||
*
|
||||
@ -46,10 +47,26 @@ public interface PropagandaMaterialsMapper {
|
||||
/**
|
||||
* 删除宣教素材关系
|
||||
*
|
||||
* @param id 宣教素材关系主键
|
||||
* @param propagandaId 宣教库id
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePropagandaMaterialsById(Long id);
|
||||
public int deleteByPropagandaId(Long propagandaId);
|
||||
|
||||
/**
|
||||
* 批量删除宣教素材关系
|
||||
*
|
||||
* @param propagandaIds 宣教库id
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteByPropagandaIds(Long[] propagandaIds);
|
||||
|
||||
/**
|
||||
* 删除宣教素材关系
|
||||
*
|
||||
* @param id 宣教素材关系
|
||||
* @return 结果
|
||||
*/
|
||||
public int deletePropagandaMaterialsById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除宣教素材关系
|
||||
|
||||
@ -0,0 +1,61 @@
|
||||
package com.xinelu.manage.mapper.residentinfo;
|
||||
|
||||
import com.xinelu.manage.domain.residentinfo.ResidentInfo;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 居民信息Mapper接口
|
||||
*
|
||||
* @author haown
|
||||
* @date 2024-03-27
|
||||
*/
|
||||
public interface ResidentInfoMapper {
|
||||
/**
|
||||
* 查询居民信息
|
||||
*
|
||||
* @param id 居民信息主键
|
||||
* @return 居民信息
|
||||
*/
|
||||
public ResidentInfo selectResidentInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 查询居民信息列表
|
||||
*
|
||||
* @param residentInfo 居民信息
|
||||
* @return 居民信息集合
|
||||
*/
|
||||
List<ResidentInfo> selectResidentInfoList(ResidentInfo residentInfo);
|
||||
|
||||
/**
|
||||
* 新增居民信息
|
||||
*
|
||||
* @param residentInfo 居民信息
|
||||
* @return 结果
|
||||
*/
|
||||
int insertResidentInfo(ResidentInfo residentInfo);
|
||||
|
||||
/**
|
||||
* 修改居民信息
|
||||
*
|
||||
* @param residentInfo 居民信息
|
||||
* @return 结果
|
||||
*/
|
||||
int updateResidentInfo(ResidentInfo residentInfo);
|
||||
|
||||
/**
|
||||
* 删除居民信息
|
||||
*
|
||||
* @param id 居民信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
int deleteResidentInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除居民信息
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
int deleteResidentInfoByIds(Long[] ids);
|
||||
}
|
||||
@ -1,4 +1,6 @@
|
||||
package com.xinelu.manage.mapper.signroutetriggercondition;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import java.util.Collection;
|
||||
|
||||
import com.xinelu.manage.domain.signroutetriggercondition.SignRouteTriggerCondition;
|
||||
import java.util.List;
|
||||
@ -58,4 +60,6 @@ public interface SignRouteTriggerConditionMapper {
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteSignRouteTriggerConditionByIds(Long[] ids);
|
||||
|
||||
int insertBatch(@Param("signRouteTriggerConditionCollection") Collection<SignRouteTriggerCondition> signRouteTriggerConditionCollection);
|
||||
}
|
||||
|
||||
@ -1,14 +1,17 @@
|
||||
package com.xinelu.manage.service.materialsinfo.impl;
|
||||
|
||||
import com.xinelu.common.exception.ServiceException;
|
||||
import com.xinelu.manage.domain.materialsinfo.MaterialsInfo;
|
||||
import com.xinelu.manage.domain.propagandamaterials.PropagandaMaterials;
|
||||
import com.xinelu.manage.dto.materialsinfo.MaterialsInfoDto;
|
||||
import com.xinelu.manage.mapper.materialsinfo.MaterialsInfoMapper;
|
||||
import com.xinelu.manage.mapper.propagandamaterials.PropagandaMaterialsMapper;
|
||||
import com.xinelu.manage.service.materialsinfo.IMaterialsInfoService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* 素材信息Service业务层处理
|
||||
@ -20,6 +23,8 @@ import java.util.List;
|
||||
public class MaterialsInfoServiceImpl implements IMaterialsInfoService {
|
||||
@Resource
|
||||
private MaterialsInfoMapper materialsInfoMapper;
|
||||
@Resource
|
||||
private PropagandaMaterialsMapper propagandaMaterialsMapper;
|
||||
|
||||
/**
|
||||
* 查询素材信息
|
||||
@ -75,6 +80,19 @@ public class MaterialsInfoServiceImpl implements IMaterialsInfoService {
|
||||
*/
|
||||
@Override
|
||||
public int deleteMaterialsInfoByIds(Long[] ids) {
|
||||
// 查询素材是否被使用
|
||||
int used = 0;
|
||||
for(Long id : ids) {
|
||||
PropagandaMaterials queryObj = new PropagandaMaterials();
|
||||
queryObj.setMaterialsId(id);
|
||||
List<PropagandaMaterials> pmList = propagandaMaterialsMapper.selectPropagandaMaterialsList(queryObj);
|
||||
if (CollectionUtils.isNotEmpty(pmList)) {
|
||||
used++;
|
||||
}
|
||||
}
|
||||
if (used > 0) {
|
||||
throw new ServiceException("选中的素材已在宣教库中被占用不能删除");
|
||||
}
|
||||
return materialsInfoMapper.deleteMaterialsInfoByIds(ids);
|
||||
}
|
||||
|
||||
@ -86,6 +104,13 @@ public class MaterialsInfoServiceImpl implements IMaterialsInfoService {
|
||||
*/
|
||||
@Override
|
||||
public int deleteMaterialsInfoById(Long id) {
|
||||
return materialsInfoMapper.deleteMaterialsInfoById(id);
|
||||
PropagandaMaterials queryObj = new PropagandaMaterials();
|
||||
queryObj.setMaterialsId(id);
|
||||
List<PropagandaMaterials> pmList = propagandaMaterialsMapper.selectPropagandaMaterialsList(queryObj);
|
||||
if (CollectionUtils.isNotEmpty(pmList)) {
|
||||
throw new ServiceException("该素材已在宣教库中被使用不能删除");
|
||||
} else {
|
||||
return materialsInfoMapper.deleteMaterialsInfoById(id);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -33,7 +33,7 @@ public interface IPatientInfoService {
|
||||
* @param patientInfo 患者信息
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertPatientInfo(PatientInfo patientInfo);
|
||||
PatientInfo insertPatientInfo(PatientInfo patientInfo);
|
||||
|
||||
/**
|
||||
* 修改患者信息
|
||||
|
||||
@ -1,14 +1,23 @@
|
||||
package com.xinelu.manage.service.patientinfo.impl;
|
||||
|
||||
import com.xinelu.common.utils.SecurityUtils;
|
||||
import com.xinelu.common.utils.bean.BeanUtils;
|
||||
import com.xinelu.manage.domain.patientinfo.PatientInfo;
|
||||
import com.xinelu.manage.domain.patientvisitrecord.PatientVisitRecord;
|
||||
import com.xinelu.manage.domain.residentinfo.ResidentInfo;
|
||||
import com.xinelu.manage.dto.patientinfo.PatientInfoDto;
|
||||
import com.xinelu.manage.dto.patientvisitrecord.PatientVisitRecordDto;
|
||||
import com.xinelu.manage.mapper.patientinfo.PatientInfoMapper;
|
||||
import com.xinelu.manage.mapper.residentinfo.ResidentInfoMapper;
|
||||
import com.xinelu.manage.service.patientinfo.IPatientInfoService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import com.xinelu.manage.service.patientvisitrecord.IPatientVisitRecordService;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.commons.lang3.ObjectUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
/**
|
||||
* 患者信息Service业务层处理
|
||||
@ -21,6 +30,10 @@ public class PatientInfoServiceImpl implements IPatientInfoService {
|
||||
|
||||
@Resource
|
||||
private PatientInfoMapper patientInfoMapper;
|
||||
@Resource
|
||||
private ResidentInfoMapper residentInfoMapper;
|
||||
@Resource
|
||||
private IPatientVisitRecordService patientVisitRecordService;
|
||||
|
||||
/**
|
||||
* 查询患者信息
|
||||
@ -51,10 +64,30 @@ public class PatientInfoServiceImpl implements IPatientInfoService {
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertPatientInfo(PatientInfo patientInfo) {
|
||||
patientInfo.setCreateTime(LocalDateTime.now());
|
||||
patientInfo.setDelFlag(0);
|
||||
return patientInfoMapper.insertPatientInfo(patientInfo);
|
||||
@Transactional
|
||||
public PatientInfo insertPatientInfo(PatientInfo patientInfo) {
|
||||
patientInfo.setCreateTime(LocalDateTime.now());
|
||||
patientInfo.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
patientInfo.setDelFlag(0);
|
||||
// 根据身份证号查询是否有该居民
|
||||
ResidentInfo residentQuery = new ResidentInfo();
|
||||
residentQuery.setCardNo(patientInfo.getCardNo());
|
||||
List<ResidentInfo> residentList = residentInfoMapper.selectResidentInfoList(residentQuery);
|
||||
|
||||
ResidentInfo residentInfo = new ResidentInfo();
|
||||
BeanUtils.copyBeanProp(residentInfo, patientInfo);
|
||||
if (CollectionUtils.isEmpty(residentList)) {
|
||||
// 新增居民
|
||||
residentInfoMapper.insertResidentInfo(residentInfo);
|
||||
patientInfo.setResidentId(residentInfo.getId());
|
||||
} else {
|
||||
// 修改居民信息
|
||||
residentInfo.setId(residentList.get(0).getId());
|
||||
residentInfoMapper.updateResidentInfo(residentInfo);
|
||||
patientInfo.setResidentId(residentList.get(0).getId());
|
||||
}
|
||||
patientInfoMapper.insertPatientInfo(patientInfo);
|
||||
return patientInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -65,8 +98,14 @@ public class PatientInfoServiceImpl implements IPatientInfoService {
|
||||
*/
|
||||
@Override
|
||||
public int updatePatientInfo(PatientInfo patientInfo) {
|
||||
patientInfo.setUpdateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
patientInfo.setUpdateTime(LocalDateTime.now());
|
||||
return patientInfoMapper.updatePatientInfo(patientInfo);
|
||||
patientInfo.setDelFlag(0);
|
||||
patientInfoMapper.updatePatientInfo(patientInfo);
|
||||
ResidentInfo residentInfo = residentInfoMapper.selectResidentInfoById(patientInfo.getResidentId());
|
||||
BeanUtils.copyBeanProp(residentInfo, patientInfo);
|
||||
residentInfo.setId(patientInfo.getResidentId());
|
||||
return residentInfoMapper.updateResidentInfo(residentInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -76,12 +115,49 @@ public class PatientInfoServiceImpl implements IPatientInfoService {
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int deletePatientInfoByIds(Long[] ids) {
|
||||
for (Long id : ids) {
|
||||
PatientInfo patientInfo = patientInfoMapper.selectPatientInfoById(id);
|
||||
patientVisitRecordService.deletePatientVisitRecordById(patientInfo.getPatientVisitRecordId());
|
||||
// 根据患者最新一条就诊记录修改患者状态
|
||||
PatientVisitRecordDto patientVisitRecordDto = new PatientVisitRecordDto();
|
||||
patientVisitRecordDto.setPatientId(id);
|
||||
PatientVisitRecord patientVisitRecord = patientVisitRecordService.getLastRecord(patientInfo.getHospitalAgencyId(), id);
|
||||
if (ObjectUtils.isEmpty(patientVisitRecord)) {
|
||||
setVisitInfoNull(patientInfo);
|
||||
} else {
|
||||
BeanUtils.copyBeanProp(patientInfo, patientVisitRecord);
|
||||
patientInfo.setId(id);
|
||||
patientInfo.setPatientVisitRecordId(patientVisitRecord.getId());
|
||||
// 设置patientType
|
||||
patientVisitRecordService.setPatientType(patientInfo, patientVisitRecord);
|
||||
}
|
||||
patientInfoMapper.updatePatientInfo(patientInfo);
|
||||
}
|
||||
return patientInfoMapper.deletePatientInfoByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置患者就诊信息为空
|
||||
* @param patientInfo 患者信息
|
||||
*/
|
||||
private void setVisitInfoNull(PatientInfo patientInfo){
|
||||
patientInfo.setVisitDate(null);
|
||||
patientInfo.setPatientType(null);
|
||||
patientInfo.setPatientVisitRecordId(null);
|
||||
patientInfo.setVisitMethod(null);
|
||||
patientInfo.setAdmissionDate(null);
|
||||
patientInfo.setDischargeDate(null);
|
||||
patientInfo.setAttendingPhysicianId(null);
|
||||
patientInfo.setAttendingPhysicianName(null);
|
||||
patientInfo.setResponsibleNurse(null);
|
||||
patientInfo.setMainDiagnosis(null);
|
||||
patientInfo.setVisitSerialNumber(null);
|
||||
patientInfo.setInHospitalNumber(null);
|
||||
}
|
||||
/**
|
||||
* 删除患者信息信息
|
||||
* 删除患者信息
|
||||
*
|
||||
* @param id 患者信息主键
|
||||
* @return 结果
|
||||
|
||||
@ -12,12 +12,14 @@ import com.xinelu.manage.domain.agency.Agency;
|
||||
import com.xinelu.manage.domain.department.Department;
|
||||
import com.xinelu.manage.domain.patientinfo.PatientInfo;
|
||||
import com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization;
|
||||
import com.xinelu.manage.domain.patientvisitrecord.PatientVisitRecord;
|
||||
import com.xinelu.manage.dto.patientinfo.PatientInfoDto;
|
||||
import com.xinelu.manage.mapper.agency.AgencyMapper;
|
||||
import com.xinelu.manage.mapper.department.DepartmentMapper;
|
||||
import com.xinelu.manage.mapper.patientinfo.PatientInfoMapper;
|
||||
import com.xinelu.manage.mapper.patientprehospitalization.PatientPreHospitalizationMapper;
|
||||
import com.xinelu.manage.service.patientinfo.IPatientInfoService;
|
||||
import com.xinelu.manage.service.patientprehospitalization.IPatientPreHospitalizationService;
|
||||
import com.xinelu.manage.service.patientvisitrecord.IPatientVisitRecordService;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
@ -41,7 +43,7 @@ public class PatientPreHospitalizationServiceImpl implements IPatientPreHospital
|
||||
private PatientPreHospitalizationMapper preHospitalizationMapper;
|
||||
|
||||
@Resource
|
||||
private PatientInfoMapper patientInfoMapper;
|
||||
private IPatientInfoService patientInfoService;
|
||||
|
||||
@Resource
|
||||
private AgencyMapper agencyMapper;
|
||||
@ -49,6 +51,9 @@ public class PatientPreHospitalizationServiceImpl implements IPatientPreHospital
|
||||
@Resource
|
||||
private DepartmentMapper departmentMapper;
|
||||
|
||||
@Resource
|
||||
private IPatientVisitRecordService patientVisitRecordService;
|
||||
|
||||
@Resource
|
||||
private RegexUtil regexUtil;
|
||||
|
||||
@ -58,27 +63,23 @@ public class PatientPreHospitalizationServiceImpl implements IPatientPreHospital
|
||||
PatientInfoDto patientInfoDto = new PatientInfoDto();
|
||||
patientInfoDto.setCardNo(preHospitalization.getCardNo());
|
||||
patientInfoDto.setHospitalAgencyId(preHospitalization.getHospitalAgencyId());
|
||||
List<PatientInfo> patientList = patientInfoMapper.selectPatientInfoList(patientInfoDto);
|
||||
List<PatientInfo> patientList = patientInfoService.selectPatientInfoList(patientInfoDto);
|
||||
if (CollectionUtils.isEmpty(patientList)) {
|
||||
// 保存患者信息
|
||||
PatientInfo patientInfo = new PatientInfo();
|
||||
BeanUtils.copyBeanProp(patientInfo, preHospitalization);
|
||||
patientInfo.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
patientInfo.setCreateTime(LocalDateTime.now());
|
||||
patientInfo.setDelFlag(0);
|
||||
patientInfo.setPatientType(PatientTypeConstants.PRE_HOSPITALIZED_PATIENT);
|
||||
patientInfoMapper.insertPatientInfo(patientInfo);
|
||||
preHospitalization.setPatientId(patientInfo.getId());
|
||||
PatientInfo saveObj = patientInfoService.insertPatientInfo(patientInfo);
|
||||
preHospitalization.setPatientId(saveObj.getId());
|
||||
preHospitalization.setResidentId(saveObj.getResidentId());
|
||||
} else {
|
||||
// 修改患者信息
|
||||
PatientInfo patientInfo = patientList.get(0);
|
||||
BeanUtils.copyBeanProp(patientInfo, preHospitalization);
|
||||
patientInfo.setUpdateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
patientInfo.setUpdateTime(LocalDateTime.now());
|
||||
patientInfo.setDelFlag(0);
|
||||
patientInfo.setPatientType(PatientTypeConstants.PRE_HOSPITALIZED_PATIENT);
|
||||
patientInfoMapper.updatePatientInfo(patientInfo);
|
||||
preHospitalization.setPatientId(patientList.get(0).getId());
|
||||
patientInfoService.updatePatientInfo(patientInfo);
|
||||
preHospitalization.setPatientId(patientInfo.getId());
|
||||
preHospitalization.setResidentId(patientInfo.getResidentId());
|
||||
}
|
||||
// 保存预住院信息
|
||||
preHospitalization.setDelFlag(0);
|
||||
@ -93,22 +94,40 @@ public class PatientPreHospitalizationServiceImpl implements IPatientPreHospital
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
public int update(PatientPreHospitalization preHospitalization) {
|
||||
// 修改患者信息
|
||||
PatientInfo patientInfo = patientInfoMapper.selectPatientInfoById(preHospitalization.getPatientId());
|
||||
PatientInfo patientInfo = patientInfoService.selectPatientInfoById(preHospitalization.getPatientId());
|
||||
Long patientId = patientInfo.getId();
|
||||
BeanUtils.copyBeanProp(patientInfo, preHospitalization);
|
||||
patientInfo.setId(patientId);
|
||||
int flag = patientInfoMapper.updatePatientInfo(patientInfo);
|
||||
int flag = patientInfoService.updatePatientInfo(patientInfo);
|
||||
if (flag >= 0) {
|
||||
return preHospitalizationMapper.updateByPrimaryKeySelective(preHospitalization);
|
||||
}
|
||||
return -1;
|
||||
return flag;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
@Transactional
|
||||
public int deleteByIds(Long[] ids) {
|
||||
for (Long id : ids) {
|
||||
// 将患者状态还原为上一个状态
|
||||
PatientPreHospitalization patientPreHospitalization = preHospitalizationMapper.selectByPrimaryKey(id);
|
||||
PatientInfo patientInfo = patientInfoService.selectPatientInfoById(patientPreHospitalization.getPatientId());
|
||||
PatientVisitRecord patientVisitRecord = patientVisitRecordService.getLastRecord(patientPreHospitalization.getHospitalAgencyId(), patientPreHospitalization.getPatientId());
|
||||
if (ObjectUtils.isEmpty(patientVisitRecord)) {
|
||||
// 患者的预住院信息置空
|
||||
setPreHospitalizationInfoNull(patientInfo);
|
||||
} else {
|
||||
// 将患者信息更改为就诊信息
|
||||
BeanUtils.copyBeanProp(patientInfo, patientVisitRecord);
|
||||
patientInfo.setPatientVisitRecordId(patientVisitRecord.getId());
|
||||
patientVisitRecordService.setPatientType(patientInfo, patientVisitRecord);
|
||||
}
|
||||
patientInfoService.updatePatientInfo(patientInfo);
|
||||
}
|
||||
return preHospitalizationMapper.deleteByIds(ids);
|
||||
}
|
||||
|
||||
@ -184,7 +203,7 @@ public class PatientPreHospitalizationServiceImpl implements IPatientPreHospital
|
||||
PatientInfoDto patientQuery = new PatientInfoDto();
|
||||
patientQuery.setCardNo(item.getCardNo());
|
||||
patientQuery.setHospitalAgencyId(preHospitalization.getHospitalAgencyId());
|
||||
List<PatientInfo> patientInfoList = patientInfoMapper.selectPatientInfoList(patientQuery);
|
||||
List<PatientInfo> patientInfoList = patientInfoService.selectPatientInfoList(patientQuery);
|
||||
if (CollectionUtils.isNotEmpty(patientInfoList)) {
|
||||
// 修改居民信息
|
||||
PatientInfo updInfo = patientInfoList.get(0);
|
||||
@ -192,16 +211,18 @@ public class PatientPreHospitalizationServiceImpl implements IPatientPreHospital
|
||||
BeanUtils.copyProperties(preHospitalization,updInfo, ignore);
|
||||
updInfo.setVisitDate(preHospitalization.getRegistrationDate().atStartOfDay());
|
||||
updInfo.setPatientType(PatientTypeConstants.PRE_HOSPITALIZED_PATIENT);
|
||||
patientInfoMapper.updatePatientInfo(updInfo);
|
||||
preHospitalization.setPatientId(patientInfoList.get(0).getId());
|
||||
patientInfoService.updatePatientInfo(updInfo);
|
||||
preHospitalization.setPatientId(updInfo.getId());
|
||||
preHospitalization.setResidentId(updInfo.getResidentId());
|
||||
} else {
|
||||
PatientInfo saveInfo = new PatientInfo();
|
||||
// 添加居民
|
||||
BeanUtils.copyProperties(preHospitalization, saveInfo);
|
||||
saveInfo.setVisitDate(preHospitalization.getRegistrationDate().atStartOfDay());
|
||||
saveInfo.setPatientType(PatientTypeConstants.PRE_HOSPITALIZED_PATIENT);
|
||||
patientInfoMapper.insertPatientInfo(saveInfo);
|
||||
preHospitalization.setPatientId(saveInfo.getId());
|
||||
PatientInfo patientInfo = patientInfoService.insertPatientInfo(saveInfo);
|
||||
preHospitalization.setPatientId(patientInfo.getId());
|
||||
preHospitalization.setResidentId(patientInfo.getResidentId());
|
||||
}
|
||||
// 根据患者身份证号和预约时间查询是否有记录
|
||||
PatientPreHospitalization preHospitalizationQuery = new PatientPreHospitalization();
|
||||
@ -222,4 +243,10 @@ public class PatientPreHospitalizationServiceImpl implements IPatientPreHospital
|
||||
}
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
private void setPreHospitalizationInfoNull(PatientInfo patientInfo) {
|
||||
patientInfo.setAppointmentDate(null);
|
||||
patientInfo.setAppointmentTreatmentGroup(null);
|
||||
patientInfo.setPatientType(null);
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
package com.xinelu.manage.service.patientvisitrecord;
|
||||
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.manage.domain.patientinfo.PatientInfo;
|
||||
import com.xinelu.manage.domain.patientvisitrecord.PatientVisitRecord;
|
||||
import com.xinelu.manage.dto.patientvisitrecord.PatientVisitRecordDto;
|
||||
import com.xinelu.manage.dto.patientvisitrecord.PatientVisitRecordImportDto;
|
||||
@ -16,6 +17,7 @@ import org.springframework.web.bind.annotation.RequestBody;
|
||||
* @date 2024-02-26
|
||||
*/
|
||||
public interface IPatientVisitRecordService {
|
||||
|
||||
/**
|
||||
* 查询患者就诊记录基本信息
|
||||
*
|
||||
@ -86,4 +88,8 @@ public interface IPatientVisitRecordService {
|
||||
* @return int
|
||||
**/
|
||||
AjaxResult importPatientList(List<PatientVisitRecordImportDto> patientList, String patientType);
|
||||
|
||||
void setPatientType(PatientInfo patientInfo, PatientVisitRecord patientVisitRecord);
|
||||
|
||||
PatientVisitRecord getLastRecord(Long hospitalAgencyId,Long patientId);
|
||||
}
|
||||
|
||||
@ -24,6 +24,7 @@ import com.xinelu.manage.mapper.agency.AgencyMapper;
|
||||
import com.xinelu.manage.mapper.department.DepartmentMapper;
|
||||
import com.xinelu.manage.mapper.patientinfo.PatientInfoMapper;
|
||||
import com.xinelu.manage.mapper.patientvisitrecord.PatientVisitRecordMapper;
|
||||
import com.xinelu.manage.service.patientinfo.IPatientInfoService;
|
||||
import com.xinelu.manage.service.patientvisitrecord.IPatientVisitRecordService;
|
||||
import com.xinelu.manage.vo.patientinfo.PatientBaseInfoVo;
|
||||
import java.time.LocalDateTime;
|
||||
@ -58,8 +59,10 @@ public class PatientVisitRecordServiceImpl implements IPatientVisitRecordService
|
||||
private DepartmentMapper departmentMapper;
|
||||
@Resource
|
||||
private PatientInfoMapper patientInfoMapper;
|
||||
@Resource
|
||||
private IPatientInfoService patientInfoService;
|
||||
|
||||
/**
|
||||
/**
|
||||
* 查询患者就诊记录基本信息
|
||||
*
|
||||
* @param id 患者就诊记录基本信息主键
|
||||
@ -91,7 +94,7 @@ public class PatientVisitRecordServiceImpl implements IPatientVisitRecordService
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void insertPatientVisitRecord(PatientVisitRecordSaveDto saveDto) {
|
||||
// 根据机构id、患者身份证号判断门诊/住院号是否重复
|
||||
PatientVisitRecord patientVisitRecord = patientVisitRecordMapper.judgeRepeat(saveDto.getHospitalAgencyId(), saveDto.getCardNo(), saveDto.getInHospitalNumber());
|
||||
PatientVisitRecord patientVisitRecord = patientVisitRecordMapper.judgeRepeat(saveDto.getHospitalAgencyId(), null, saveDto.getInHospitalNumber());
|
||||
if (ObjectUtils.isNotEmpty(patientVisitRecord)) {
|
||||
throw new ServiceException("门诊/住院号重复,请确认后重新输入!");
|
||||
}
|
||||
@ -101,28 +104,28 @@ public class PatientVisitRecordServiceImpl implements IPatientVisitRecordService
|
||||
// 1、保存患者信息-查询是否有患者档案
|
||||
PatientInfoDto patientInfoDto = new PatientInfoDto();
|
||||
patientInfoDto.setHospitalAgencyId(saveBody.getHospitalAgencyId());
|
||||
patientInfoDto.setCardNo(patientInfoDto.getCardNo());
|
||||
patientInfoDto.setCardNo(saveBody.getCardNo());
|
||||
List<PatientInfo> patientInfoList = patientInfoMapper.selectPatientInfoList(patientInfoDto);
|
||||
// 患者档案信息新增/修改
|
||||
PatientInfo patientInfo = new PatientInfo();
|
||||
if(CollectionUtils.isEmpty(patientInfoList)) {
|
||||
// 新增档案
|
||||
BeanUtils.copyBeanProp(patientInfo, patientVisitRecord);
|
||||
BeanUtils.copyBeanProp(patientInfo, saveDto);
|
||||
patientInfo.setPatientSource(PatientSourceEnum.MANAGE_END.name());
|
||||
patientInfo.setDelFlag(0);
|
||||
patientInfo.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
patientInfo.setCreateTime(LocalDateTime.now());
|
||||
patientInfoMapper.insertPatientInfo(patientInfo);
|
||||
patientInfoService.insertPatientInfo(patientInfo);
|
||||
saveBody.setPatientId(patientInfo.getId());
|
||||
} else {
|
||||
patientInfo = patientInfoList.get(0);
|
||||
Long patientId = patientInfo.getId();
|
||||
// 修改档案
|
||||
BeanUtils.copyBeanProp(patientInfo, patientVisitRecord);
|
||||
BeanUtils.copyBeanProp(patientInfo, saveDto);
|
||||
patientInfo.setUpdateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
patientInfo.setUpdateTime(LocalDateTime.now());
|
||||
patientInfo.setId(patientId);
|
||||
patientInfoMapper.updatePatientInfo(patientInfo);
|
||||
patientInfoService.updatePatientInfo(patientInfo);
|
||||
saveBody.setPatientId(patientId);
|
||||
}
|
||||
// 保存/修改就诊记录
|
||||
@ -163,7 +166,7 @@ public class PatientVisitRecordServiceImpl implements IPatientVisitRecordService
|
||||
PatientInfo patientInfo = patientMapper.selectPatientInfoById(patientVisitRecord.getPatientId());
|
||||
setVisitDate(patientVisitRecord);
|
||||
BeanUtils.copyBeanProp(patientInfo, patientVisitRecord);
|
||||
patientMapper.updatePatientInfo(patientInfo);
|
||||
patientInfoService.updatePatientInfo(patientInfo);
|
||||
// 修改就诊记录信息
|
||||
return patientVisitRecordMapper.updatePatientVisitRecord(patientVisitRecord);
|
||||
}
|
||||
@ -193,7 +196,7 @@ public class PatientVisitRecordServiceImpl implements IPatientVisitRecordService
|
||||
// 设置患者类型
|
||||
setPatientType(patientInfo, patientVisitRecord);
|
||||
patientInfo.setPatientVisitRecordId(patientVisitRecord.getId());
|
||||
patientMapper.updatePatientInfo(patientInfo);
|
||||
patientInfoService.updatePatientInfo(patientInfo);
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
@ -225,7 +228,7 @@ public class PatientVisitRecordServiceImpl implements IPatientVisitRecordService
|
||||
patientInfo.setDepartmentId(updDto.getDepartmentId());
|
||||
patientInfo.setDepartmentName(updDto.getDepartmentName());
|
||||
setPatientType(patientInfo, patientVisitRecord);
|
||||
patientMapper.updatePatientInfo(patientInfo);
|
||||
patientInfoService.updatePatientInfo(patientInfo);
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
@ -381,18 +384,8 @@ public class PatientVisitRecordServiceImpl implements IPatientVisitRecordService
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
private void setVisitDate(PatientVisitRecord patientVisitRecord) {
|
||||
if (StringUtils.equals(VisitMethodConstants.OUTPATIENT_SERVICE, patientVisitRecord.getVisitMethod())) {
|
||||
patientVisitRecord.setVisitDate(patientVisitRecord.getDischargeTime());
|
||||
} else if (StringUtils.equals(VisitMethodConstants.BE_HOSPITALIZED, patientVisitRecord.getVisitMethod())) {
|
||||
// 住院时间,出院时间-入院时间
|
||||
long daysBetween = ChronoUnit.DAYS.between(patientVisitRecord.getAdmissionTime(), patientVisitRecord.getDischargeTime());
|
||||
patientVisitRecord.setHospitalizationDays((int) daysBetween + 1);
|
||||
patientVisitRecord.setVisitDate(patientVisitRecord.getAdmissionTime());
|
||||
}
|
||||
}
|
||||
|
||||
private void setPatientType(PatientInfo patientInfo, PatientVisitRecord patientVisitRecord) {
|
||||
@Override
|
||||
public void setPatientType(PatientInfo patientInfo, PatientVisitRecord patientVisitRecord) {
|
||||
if (StringUtils.equals(VisitMethodConstants.BE_HOSPITALIZED, patientVisitRecord.getVisitMethod())) {
|
||||
// 住院患者:有出院时间,设置患者类型为出院,没有出院时间,设置患者类型为在院
|
||||
if (patientVisitRecord.getDischargeTime() == null) {
|
||||
@ -404,4 +397,19 @@ public class PatientVisitRecordServiceImpl implements IPatientVisitRecordService
|
||||
patientInfo.setPatientType(PatientTypeConstants.OUTPATIENT);
|
||||
}
|
||||
}
|
||||
|
||||
@Override public PatientVisitRecord getLastRecord(Long hospitalAgencyId, Long patientId) {
|
||||
return patientVisitRecordMapper.getLastRecord(hospitalAgencyId, patientId);
|
||||
}
|
||||
|
||||
private void setVisitDate(PatientVisitRecord patientVisitRecord) {
|
||||
if (StringUtils.equals(VisitMethodConstants.OUTPATIENT_SERVICE, patientVisitRecord.getVisitMethod())) {
|
||||
patientVisitRecord.setVisitDate(patientVisitRecord.getDischargeTime());
|
||||
} else if (StringUtils.equals(VisitMethodConstants.BE_HOSPITALIZED, patientVisitRecord.getVisitMethod())) {
|
||||
// 住院时间,出院时间-入院时间
|
||||
long daysBetween = ChronoUnit.DAYS.between(patientVisitRecord.getAdmissionTime(), patientVisitRecord.getDischargeTime());
|
||||
patientVisitRecord.setHospitalizationDays((int) daysBetween + 1);
|
||||
patientVisitRecord.setVisitDate(patientVisitRecord.getAdmissionTime());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -3,8 +3,10 @@ package com.xinelu.manage.service.propagandainfo;
|
||||
import com.xinelu.manage.domain.propagandainfo.PropagandaInfo;
|
||||
import com.xinelu.manage.dto.department.DepartmentDTO;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaInfoDto;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaInfoSaveDto;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaUpdateDto;
|
||||
import com.xinelu.manage.vo.department.DepartmentVO;
|
||||
import com.xinelu.manage.vo.propagandainfo.PropagandaMaterialsVo;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@ -20,7 +22,7 @@ public interface IPropagandaInfoService {
|
||||
* @param id 宣教库管理主键
|
||||
* @return 宣教库管理
|
||||
*/
|
||||
public PropagandaInfo selectPropagandaInfoById(Long id);
|
||||
public PropagandaMaterialsVo selectPropagandaInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 查询宣教库管理列表
|
||||
@ -33,18 +35,18 @@ public interface IPropagandaInfoService {
|
||||
/**
|
||||
* 新增宣教库管理
|
||||
*
|
||||
* @param propagandaInfo 宣教库管理
|
||||
* @param propagandaInfoSaveDto 宣教库保存传输对象
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertPropagandaInfo(PropagandaInfo propagandaInfo);
|
||||
public int insertPropagandaInfo(PropagandaInfoSaveDto propagandaInfoSaveDto);
|
||||
|
||||
/**
|
||||
* 修改宣教库管理
|
||||
*
|
||||
* @param propagandaInfo 宣教库管理
|
||||
* @param propagandaInfoSaveDto 宣教库管理
|
||||
* @return 结果
|
||||
*/
|
||||
public int updatePropagandaInfo(PropagandaInfo propagandaInfo);
|
||||
public int updatePropagandaInfo(PropagandaInfoSaveDto propagandaInfoSaveDto);
|
||||
|
||||
/**
|
||||
* 复制宣教库管理
|
||||
|
||||
@ -1,18 +1,26 @@
|
||||
package com.xinelu.manage.service.propagandainfo.impl;
|
||||
|
||||
import com.xinelu.common.utils.SecurityUtils;
|
||||
import com.xinelu.common.utils.bean.BeanUtils;
|
||||
import com.xinelu.manage.domain.materialsinfo.MaterialsInfo;
|
||||
import com.xinelu.manage.domain.propagandainfo.PropagandaInfo;
|
||||
import com.xinelu.manage.domain.propagandamaterials.PropagandaMaterials;
|
||||
import com.xinelu.manage.dto.department.DepartmentDTO;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaInfoDto;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaInfoSaveDto;
|
||||
import com.xinelu.manage.dto.propagandainfo.PropagandaUpdateDto;
|
||||
import com.xinelu.manage.mapper.materialsinfo.MaterialsInfoMapper;
|
||||
import com.xinelu.manage.mapper.propagandainfo.PropagandaInfoMapper;
|
||||
import com.xinelu.manage.mapper.propagandamaterials.PropagandaMaterialsMapper;
|
||||
import com.xinelu.manage.service.propagandainfo.IPropagandaInfoService;
|
||||
import com.xinelu.manage.vo.department.DepartmentVO;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import com.xinelu.manage.vo.propagandainfo.PropagandaMaterialsVo;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
/**
|
||||
* 宣教库管理Service业务层处理
|
||||
@ -24,6 +32,10 @@ import java.util.List;
|
||||
public class PropagandaInfoServiceImpl implements IPropagandaInfoService {
|
||||
@Resource
|
||||
private PropagandaInfoMapper propagandaInfoMapper;
|
||||
@Resource
|
||||
private PropagandaMaterialsMapper propagandaMaterialsMapper;
|
||||
@Resource
|
||||
private MaterialsInfoMapper materialsInfoMapper;
|
||||
|
||||
/**
|
||||
* 查询宣教库管理
|
||||
@ -32,8 +44,8 @@ public class PropagandaInfoServiceImpl implements IPropagandaInfoService {
|
||||
* @return 宣教库管理
|
||||
*/
|
||||
@Override
|
||||
public PropagandaInfo selectPropagandaInfoById(Long id) {
|
||||
return propagandaInfoMapper.selectPropagandaInfoById(id);
|
||||
public PropagandaMaterialsVo selectPropagandaInfoById(Long id) {
|
||||
return propagandaInfoMapper.selectPropagandaInfo(id);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -50,38 +62,100 @@ public class PropagandaInfoServiceImpl implements IPropagandaInfoService {
|
||||
/**
|
||||
* 新增宣教库管理
|
||||
*
|
||||
* @param propagandaInfo 宣教库管理
|
||||
* @param propagandaInfoSaveDto 宣教库保存传输对象
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertPropagandaInfo(PropagandaInfo propagandaInfo) {
|
||||
@Transactional
|
||||
public int insertPropagandaInfo(PropagandaInfoSaveDto propagandaInfoSaveDto) {
|
||||
PropagandaInfo propagandaInfo = new PropagandaInfo();
|
||||
BeanUtils.copyBeanProp(propagandaInfo, propagandaInfoSaveDto);
|
||||
propagandaInfo.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
propagandaInfo.setCreateTime(LocalDateTime.now());
|
||||
return propagandaInfoMapper.insertPropagandaInfo(propagandaInfo);
|
||||
propagandaInfo.setDelFlag(0);
|
||||
int flag = propagandaInfoMapper.insertPropagandaInfo(propagandaInfo);
|
||||
if (flag > 0) {
|
||||
// 保存宣教素材关联关系
|
||||
if (CollectionUtils.isNotEmpty(propagandaInfoSaveDto.getMaterialsInfoList())) {
|
||||
for (MaterialsInfo materialsInfo : propagandaInfoSaveDto.getMaterialsInfoList()) {
|
||||
PropagandaMaterials propagandaMaterials = new PropagandaMaterials();
|
||||
propagandaMaterials.setPropagandaId(propagandaInfo.getId());
|
||||
propagandaMaterials.setPropagandaTitle(propagandaInfo.getPropagandaTitle());
|
||||
propagandaMaterials.setMaterialsId(materialsInfo.getId());
|
||||
propagandaMaterials.setMaterialsName(materialsInfo.getMaterialsName());
|
||||
propagandaMaterials.setCreateTime(LocalDateTime.now());
|
||||
propagandaMaterials.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
propagandaMaterials.setDelFlag(0);
|
||||
propagandaMaterialsMapper.insertPropagandaMaterials(propagandaMaterials);
|
||||
}
|
||||
}
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改宣教库管理
|
||||
*
|
||||
* @param propagandaInfo 宣教库管理
|
||||
* @param propagandaInfoSaveDto 宣教库管理
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updatePropagandaInfo(PropagandaInfo propagandaInfo) {
|
||||
public int updatePropagandaInfo(PropagandaInfoSaveDto propagandaInfoSaveDto) {
|
||||
PropagandaInfo propagandaInfo = new PropagandaInfo();
|
||||
BeanUtils.copyBeanProp(propagandaInfo, propagandaInfoSaveDto);
|
||||
propagandaInfo.setUpdateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
propagandaInfo.setUpdateTime(LocalDateTime.now());
|
||||
return propagandaInfoMapper.updatePropagandaInfo(propagandaInfo);
|
||||
int flag = propagandaInfoMapper.updatePropagandaInfo(propagandaInfo);
|
||||
if (flag > 0) {
|
||||
// 删除之前的关联关系
|
||||
propagandaMaterialsMapper.deleteByPropagandaId(propagandaInfo.getId());
|
||||
// 修改宣教素材关联关系
|
||||
if (CollectionUtils.isNotEmpty(propagandaInfoSaveDto.getMaterialsInfoList())) {
|
||||
for (MaterialsInfo materialsInfo : propagandaInfoSaveDto.getMaterialsInfoList()) {
|
||||
PropagandaMaterials propagandaMaterials = new PropagandaMaterials();
|
||||
propagandaMaterials.setPropagandaId(propagandaInfo.getId());
|
||||
propagandaMaterials.setPropagandaTitle(propagandaInfo.getPropagandaTitle());
|
||||
propagandaMaterials.setMaterialsId(materialsInfo.getId());
|
||||
propagandaMaterials.setMaterialsName(materialsInfo.getMaterialsName());
|
||||
propagandaMaterials.setCreateTime(LocalDateTime.now());
|
||||
propagandaMaterials.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
propagandaMaterials.setDelFlag(0);
|
||||
propagandaMaterialsMapper.insertPropagandaMaterials(propagandaMaterials);
|
||||
}
|
||||
}
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int copyPropagandaInfo(Long id) {
|
||||
PropagandaInfo propagandaInfo = propagandaInfoMapper.selectPropagandaInfoById(id);
|
||||
propagandaInfo.setId(null);
|
||||
propagandaInfo.setDelFlag(0);
|
||||
propagandaInfo.setCreateTime(LocalDateTime.now());
|
||||
propagandaInfo.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
propagandaInfo.setUpdateTime(null);
|
||||
propagandaInfo.setUpdateBy(null);
|
||||
propagandaInfo.setPropagandaCode(propagandaInfo.getPropagandaCode() + "-COPY");
|
||||
propagandaInfo.setPropagandaCode(propagandaInfo.getPropagandaCode().replaceAll("-COPY", "") + "-COPY");
|
||||
propagandaInfo.setPropagandaStatus("CREATE_COMPLETE");
|
||||
return propagandaInfoMapper.insertPropagandaInfo(propagandaInfo);
|
||||
int flag = propagandaInfoMapper.insertPropagandaInfo(propagandaInfo);
|
||||
if (flag > 0) {
|
||||
// 查询宣教素材关联关系
|
||||
PropagandaMaterials query = new PropagandaMaterials();
|
||||
query.setPropagandaId(id);
|
||||
List<PropagandaMaterials> propagandaMaterialsList = propagandaMaterialsMapper.selectPropagandaMaterialsList(query);
|
||||
if (CollectionUtils.isNotEmpty(propagandaMaterialsList)) {
|
||||
for (PropagandaMaterials propagandaMaterials : propagandaMaterialsList) {
|
||||
propagandaMaterials.setPropagandaId(id);
|
||||
propagandaMaterials.setPropagandaTitle(propagandaInfo.getPropagandaTitle());
|
||||
propagandaMaterials.setDelFlag(0);
|
||||
propagandaMaterials.setCreateBy(SecurityUtils.getLoginUser().getUser().getCreateBy());
|
||||
propagandaMaterials.setCreateTime(LocalDateTime.now());
|
||||
propagandaMaterialsMapper.insertPropagandaMaterials(propagandaMaterials);
|
||||
}
|
||||
}
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -100,6 +174,8 @@ public class PropagandaInfoServiceImpl implements IPropagandaInfoService {
|
||||
*/
|
||||
@Override
|
||||
public int deletePropagandaInfoByIds(Long[] ids) {
|
||||
// 删除宣教素材关系
|
||||
propagandaMaterialsMapper.deleteByPropagandaIds(ids);
|
||||
return propagandaInfoMapper.deletePropagandaInfoByIds(ids);
|
||||
}
|
||||
|
||||
|
||||
@ -0,0 +1,60 @@
|
||||
package com.xinelu.manage.service.residentinfo;
|
||||
|
||||
import com.xinelu.manage.domain.residentinfo.ResidentInfo;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 居民信息Service接口
|
||||
*
|
||||
* @author haown
|
||||
* @date 2024-03-27
|
||||
*/
|
||||
public interface IResidentInfoService {
|
||||
/**
|
||||
* 查询居民信息
|
||||
*
|
||||
* @param id 居民信息主键
|
||||
* @return 居民信息
|
||||
*/
|
||||
public ResidentInfo selectResidentInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 查询居民信息列表
|
||||
*
|
||||
* @param residentInfo 居民信息
|
||||
* @return 居民信息集合
|
||||
*/
|
||||
List<ResidentInfo> selectResidentInfoList(ResidentInfo residentInfo);
|
||||
|
||||
/**
|
||||
* 新增居民信息
|
||||
*
|
||||
* @param residentInfo 居民信息
|
||||
* @return 结果
|
||||
*/
|
||||
int insertResidentInfo(ResidentInfo residentInfo);
|
||||
|
||||
/**
|
||||
* 修改居民信息
|
||||
*
|
||||
* @param residentInfo 居民信息
|
||||
* @return 结果
|
||||
*/
|
||||
int updateResidentInfo(ResidentInfo residentInfo);
|
||||
|
||||
/**
|
||||
* 批量删除居民信息
|
||||
*
|
||||
* @param ids 需要删除的居民信息主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
int deleteResidentInfoByIds(Long[] ids);
|
||||
|
||||
/**
|
||||
* 删除居民信息信息
|
||||
*
|
||||
* @param id 居民信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
int deleteResidentInfoById(Long id);
|
||||
}
|
||||
@ -0,0 +1,81 @@
|
||||
package com.xinelu.manage.service.residentinfo.impl;
|
||||
|
||||
import com.xinelu.manage.domain.residentinfo.ResidentInfo;
|
||||
import com.xinelu.manage.mapper.residentinfo.ResidentInfoMapper;
|
||||
import com.xinelu.manage.service.residentinfo.IResidentInfoService;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
import javax.annotation.Resource;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* 居民信息Service业务层处理
|
||||
*
|
||||
* @author haown
|
||||
* @date 2024-03-27
|
||||
*/
|
||||
@Service public class ResidentInfoServiceImpl implements IResidentInfoService {
|
||||
@Resource private ResidentInfoMapper residentInfoMapper;
|
||||
|
||||
/**
|
||||
* 查询居民信息
|
||||
*
|
||||
* @param id 居民信息主键
|
||||
* @return 居民信息
|
||||
*/
|
||||
@Override public ResidentInfo selectResidentInfoById(Long id) {
|
||||
return residentInfoMapper.selectResidentInfoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询居民信息列表
|
||||
*
|
||||
* @param residentInfo 居民信息
|
||||
* @return 居民信息
|
||||
*/
|
||||
@Override public List<ResidentInfo> selectResidentInfoList(ResidentInfo residentInfo) {
|
||||
return residentInfoMapper.selectResidentInfoList(residentInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增居民信息
|
||||
*
|
||||
* @param residentInfo 居民信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override public int insertResidentInfo(ResidentInfo residentInfo) {
|
||||
residentInfo.setCreateTime(LocalDateTime.now());
|
||||
return residentInfoMapper.insertResidentInfo(residentInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改居民信息
|
||||
*
|
||||
* @param residentInfo 居民信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override public int updateResidentInfo(ResidentInfo residentInfo) {
|
||||
residentInfo.setUpdateTime(LocalDateTime.now());
|
||||
return residentInfoMapper.updateResidentInfo(residentInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除居民信息
|
||||
*
|
||||
* @param ids 需要删除的居民信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override public int deleteResidentInfoByIds(Long[] ids) {
|
||||
return residentInfoMapper.deleteResidentInfoByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除居民信息信息
|
||||
*
|
||||
* @param id 居民信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override public int deleteResidentInfoById(Long id) {
|
||||
return residentInfoMapper.deleteResidentInfoById(id);
|
||||
}
|
||||
}
|
||||
@ -1,11 +1,12 @@
|
||||
package com.xinelu.manage.service.signpatientrecord;
|
||||
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientStatusDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.IntentionalSignDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientAddDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientListDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientStatusDto;
|
||||
import com.xinelu.manage.vo.signpatientrecord.SignPatientInfoVo;
|
||||
import com.xinelu.manage.vo.signpatientrecord.SignPatientRecordVo;
|
||||
import com.xinelu.manage.vo.signpatientrecord.SignPatientListVo;
|
||||
import com.xinelu.manage.vo.signpatientrecord.SignPatientRecordVo;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@ -38,4 +39,11 @@ public interface ISignPatientRecordService {
|
||||
int add(SignPatientAddDto body);
|
||||
|
||||
int updateSignStatus(SignPatientStatusDto patientCancelSignDto);
|
||||
|
||||
/**
|
||||
* 意向签约
|
||||
* @param intentionalSignDto 意向签约传输对象
|
||||
* @return
|
||||
*/
|
||||
int intentionalSign(IntentionalSignDto intentionalSignDto);
|
||||
}
|
||||
|
||||
@ -13,10 +13,12 @@ import com.xinelu.manage.domain.signpatientmanageroutenode.SignPatientManageRout
|
||||
import com.xinelu.manage.domain.signpatientpackage.SignPatientPackage;
|
||||
import com.xinelu.manage.domain.signpatientpackagehardware.SignPatientPackageHardware;
|
||||
import com.xinelu.manage.domain.signpatientrecord.SignPatientRecord;
|
||||
import com.xinelu.manage.domain.signroutetriggercondition.SignRouteTriggerCondition;
|
||||
import com.xinelu.manage.domain.specialdiseasenode.SpecialDiseaseNode;
|
||||
import com.xinelu.manage.domain.specialdiseaseroute.SpecialDiseaseRoute;
|
||||
import com.xinelu.manage.domain.specialdiseasetriggercondition.SpecialDiseaseTriggerCondition;
|
||||
import com.xinelu.manage.dto.signpatientpackage.SignPatientPackageSaveDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.IntentionalSignDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientAddDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientListDto;
|
||||
import com.xinelu.manage.dto.signpatientrecord.SignPatientStatusDto;
|
||||
@ -27,6 +29,7 @@ import com.xinelu.manage.mapper.signpatientmanageroutenode.SignPatientManageRout
|
||||
import com.xinelu.manage.mapper.signpatientpackage.SignPatientPackageMapper;
|
||||
import com.xinelu.manage.mapper.signpatientpackagehardware.SignPatientPackageHardwareMapper;
|
||||
import com.xinelu.manage.mapper.signpatientrecord.SignPatientRecordMapper;
|
||||
import com.xinelu.manage.mapper.signroutetriggercondition.SignRouteTriggerConditionMapper;
|
||||
import com.xinelu.manage.mapper.specialdiseasenode.SpecialDiseaseNodeMapper;
|
||||
import com.xinelu.manage.mapper.specialdiseaseroute.SpecialDiseaseRouteMapper;
|
||||
import com.xinelu.manage.mapper.specialdiseasetriggercondition.SpecialDiseaseTriggerConditionMapper;
|
||||
@ -76,6 +79,8 @@ public class SignPatientRecordServiceImpl implements ISignPatientRecordService {
|
||||
private SignPatientManageRouteNodeMapper manageRouteNodeMapper;
|
||||
@Resource
|
||||
private SpecialDiseaseTriggerConditionMapper triggerConditionMapper;
|
||||
@Resource
|
||||
private SignRouteTriggerConditionMapper signRouteTriggerConditionMapper;
|
||||
|
||||
@Override public List<SignPatientListVo> selectList(SignPatientListDto signPatientRecord) {
|
||||
return signPatientRecordMapper.selectList(signPatientRecord);
|
||||
@ -112,7 +117,6 @@ public class SignPatientRecordServiceImpl implements ISignPatientRecordService {
|
||||
}
|
||||
if (ObjectUtils.isNotEmpty(body.getRecord())) {
|
||||
SignPatientRecord signPatientRecord = body.getRecord();
|
||||
signPatientRecord.setId(null);
|
||||
if (signPatientRecord.getPatientId() == null) {
|
||||
throw new ServiceException("请选择签约居民");
|
||||
}
|
||||
@ -129,8 +133,13 @@ public class SignPatientRecordServiceImpl implements ISignPatientRecordService {
|
||||
signPatientRecord.setCreateTime(LocalDateTime.now());
|
||||
signPatientRecord.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
// 保存签约记录
|
||||
int flag = signPatientRecordMapper.insert(signPatientRecord);
|
||||
|
||||
int flag = 0;
|
||||
if (body.getSignCategory() == "sign") {
|
||||
flag = signPatientRecordMapper.updateByPrimaryKey(signPatientRecord);
|
||||
} else {
|
||||
signPatientRecord.setId(null);
|
||||
flag = signPatientRecordMapper.insert(signPatientRecord);
|
||||
}
|
||||
// 签约信息保存到患者表
|
||||
patient.setSignPatientRecordId(signPatientRecord.getId());
|
||||
patient.setSignStatus(SignRecordServiceStatusConstants.IN_SIGN);
|
||||
@ -157,6 +166,7 @@ public class SignPatientRecordServiceImpl implements ISignPatientRecordService {
|
||||
SignPatientManageRoute signPatientManageRoute = new SignPatientManageRoute();
|
||||
BeanUtils.copyBeanProp(signPatientManageRoute, specialDiseaseRoute);
|
||||
signPatientManageRoute.setSignPatientRecordId(signPatientRecord.getId());
|
||||
signPatientManageRoute.setId(null);
|
||||
signPatientManageRoute.setRouteId(specialDiseaseRoute.getId());
|
||||
signPatientManageRoute.setTaskCreateType(TaskCreateTypeConstant.MANUAL_MATCHE);
|
||||
signPatientManageRoute.setCreateTime(LocalDateTime.now());
|
||||
@ -173,6 +183,7 @@ public class SignPatientRecordServiceImpl implements ISignPatientRecordService {
|
||||
SignPatientManageRouteNode manageRouteNode = new SignPatientManageRouteNode();
|
||||
BeanUtils.copyBeanProp(manageRouteNode, node);
|
||||
manageRouteNode.setManageRouteId(body.getRouteId());
|
||||
manageRouteNode.setId(null);
|
||||
manageRouteNode.setCreateTime(LocalDateTime.now());
|
||||
manageRouteNode.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
return manageRouteNode;
|
||||
@ -183,9 +194,14 @@ public class SignPatientRecordServiceImpl implements ISignPatientRecordService {
|
||||
SpecialDiseaseTriggerCondition triggerConditionQuery = new SpecialDiseaseTriggerCondition();
|
||||
triggerConditionQuery.setRouteId(body.getRouteId());
|
||||
List<SpecialDiseaseTriggerCondition> triggerConditions = triggerConditionMapper.selectSpecialDiseaseTriggerConditionList(triggerConditionQuery);
|
||||
//triggerConditions.stream().map(item->{
|
||||
//
|
||||
//})
|
||||
List<SignRouteTriggerCondition> routeTriggerConditionList = triggerConditions.stream().map(item->{
|
||||
SignRouteTriggerCondition signRouteTriggerCondition = new SignRouteTriggerCondition();
|
||||
BeanUtils.copyBeanProp(signRouteTriggerCondition, item);
|
||||
signRouteTriggerCondition.setPatientManageRouteId(signPatientManageRoute.getRouteId());
|
||||
signRouteTriggerCondition.setId(null);
|
||||
return signRouteTriggerCondition;
|
||||
}).collect(Collectors.toList());
|
||||
signRouteTriggerConditionMapper.insertBatch(routeTriggerConditionList);
|
||||
}
|
||||
|
||||
// 保存硬件
|
||||
@ -235,4 +251,35 @@ public class SignPatientRecordServiceImpl implements ISignPatientRecordService {
|
||||
return signPatientRecordMapper.updateByPrimaryKeySelective(signRecord);
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public int intentionalSign(IntentionalSignDto intentionalSignDto) {
|
||||
PatientInfo patientInfo = patientInfoMapper.selectPatientInfoById(intentionalSignDto.getPatientId());
|
||||
if (ObjectUtils.isEmpty(patientInfo)) {
|
||||
throw new ServiceException("未找到该居民");
|
||||
}
|
||||
// 查询当前居民签约状态是否已签约
|
||||
if (StringUtils.equals(SignRecordServiceStatusConstants.IN_SIGN, patientInfo.getSignStatus())) {
|
||||
throw new ServiceException("该居民已签约!");
|
||||
}
|
||||
|
||||
patientInfo.setServiceStatus(SignRecordServiceStatusConstants.INTENTIONAL_SIGNING);
|
||||
SignPatientRecord signRecord = new SignPatientRecord();
|
||||
// 患者信息保存到签约表
|
||||
BeanUtils.copyBeanProp(signRecord, patientInfo);
|
||||
signRecord.setSignDiagnosis(patientInfo.getMainDiagnosis());
|
||||
signRecord.setBillingDoctorId(intentionalSignDto.getBillingDoctorId());
|
||||
signRecord.setBillingDoctorName(intentionalSignDto.getBillingDoctorName());
|
||||
signRecord.setIntentionalSource(intentionalSignDto.getIntentionalSource());
|
||||
signRecord.setIntentionalTime(LocalDateTime.now());
|
||||
signRecord.setPatientId(patientInfo.getId());
|
||||
signRecord.setCreateBy(SecurityUtils.getLoginUser().getUser().getNickName());
|
||||
signRecord.setCreateTime(LocalDateTime.now());
|
||||
int flag = signPatientRecordMapper.insertSelective(signRecord);
|
||||
if (flag > 0) {
|
||||
patientInfo.setSignPatientRecordId(signRecord.getId());
|
||||
patientInfoMapper.updatePatientInfo(patientInfo);
|
||||
}
|
||||
return flag;
|
||||
}
|
||||
}
|
||||
|
||||
@ -16,6 +16,10 @@ public class PatientBaseInfoVo {
|
||||
/** 主键id */
|
||||
private Long id;
|
||||
|
||||
/** 居民信息表id */
|
||||
@ApiModelProperty(value = "居民信息表id")
|
||||
private Long residentId;
|
||||
|
||||
/** 患者姓名 */
|
||||
@ApiModelProperty(value = "患者姓名")
|
||||
@Excel(name = "患者姓名")
|
||||
|
||||
@ -0,0 +1,94 @@
|
||||
package com.xinelu.manage.vo.propagandainfo;
|
||||
|
||||
import com.xinelu.common.annotation.Excel;
|
||||
import com.xinelu.manage.domain.materialsinfo.MaterialsInfo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.util.List;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @description: 宣教对象查询返回视图类
|
||||
* @author: haown
|
||||
* @create: 2024-03-28 10:50
|
||||
**/
|
||||
@ApiModel("宣教对象查询返回视图类")
|
||||
@Data
|
||||
public class PropagandaMaterialsVo {
|
||||
/** 主键id */
|
||||
private Long id;
|
||||
|
||||
/** 所属医院id */
|
||||
@ApiModelProperty(value = "所属医院id")
|
||||
private Long hospitalAgencyId;
|
||||
|
||||
/** 所属医院名称 */
|
||||
@ApiModelProperty(value = "所属医院名称")
|
||||
@Excel(name = "所属医院名称")
|
||||
private String hospitalAgencyName;
|
||||
|
||||
/** 所属科室id */
|
||||
@ApiModelProperty(value = "所属科室id")
|
||||
private Long departmentId;
|
||||
|
||||
/** 所属科室名称 */
|
||||
@ApiModelProperty(value = "所属科室名称")
|
||||
@Excel(name = "所属科室名称")
|
||||
private String departmentName;
|
||||
|
||||
/** 宣教标题(宣教名称) */
|
||||
@ApiModelProperty(value = "宣教标题")
|
||||
@Excel(name = "宣教标题", readConverterExp = "宣=教名称")
|
||||
private String propagandaTitle;
|
||||
|
||||
/** 宣教类型,用药知识:MEDICATION_KNOWLEDGE,疾病科普:DISEASE_POPULARIZATION,运动营养:SPORT_NUTRITION,其他知识:OTHER_KNOWLEDGE,
|
||||
定制内容:CUSTOMIZED_CONTENT */
|
||||
@ApiModelProperty(value = "宣教类型,用药知识:MEDICATION_KNOWLEDGE,疾病科普:DISEASE_POPULARIZATION,运动营养:SPORT_NUTRITION,其他知识:OTHER_KNOWLEDGE,定制内容:CUSTOMIZED_CONTENT")
|
||||
@Excel(name = "宣教类型,用药知识:MEDICATION_KNOWLEDGE,疾病科普:DISEASE_POPULARIZATION,运动营养:SPORT_NUTRITION,其他知识:OTHER_KNOWLEDGE,定制内容:CUSTOMIZED_CONTENT")
|
||||
private String propagandaType;
|
||||
|
||||
/** 宣教ID */
|
||||
@ApiModelProperty(value = "宣教ID")
|
||||
private String propagandaCode;
|
||||
|
||||
/** 宣教状态,创作中:CREATE_PROCESS,创作完成:CREATE_COMPLETE,审核中:IN_REVIEW,审核通过:APPROVED,审核不通过:REVIEW_FAILED */
|
||||
@ApiModelProperty(value = "宣教状态,创作中:CREATE_PROCESS,创作完成:CREATE_COMPLETE,审核中:IN_REVIEW,审核通过:APPROVED,审核不通过:REVIEW_FAILED")
|
||||
@Excel(name = "宣教状态,创作中:CREATE_PROCESS,创作完成:CREATE_COMPLETE,审核中:IN_REVIEW,审核通过:APPROVED,审核不通过:REVIEW_FAILED")
|
||||
private String propagandaStatus;
|
||||
|
||||
/** 宣教正文内容 */
|
||||
@ApiModelProperty(value = "宣教正文内容")
|
||||
private String propagandaContent;
|
||||
|
||||
/** 宣教封面文件存放地址 */
|
||||
@ApiModelProperty(value = "宣教封面文件存放地址")
|
||||
private String propagandaCoverPath;
|
||||
|
||||
/** 宣教文章摘要 */
|
||||
@ApiModelProperty(value = "宣教文章摘要")
|
||||
private String articleSummary;
|
||||
|
||||
/** 语音播报 */
|
||||
@ApiModelProperty(value = "语音播报")
|
||||
private String voicebroadcast;
|
||||
|
||||
/** 所属病种id */
|
||||
@ApiModelProperty(value = "所属病种id")
|
||||
private Long diseaseTypeId;
|
||||
|
||||
/** 所属病种名称 */
|
||||
@ApiModelProperty(value = "所属病种名称")
|
||||
@Excel(name = "所属病种名称")
|
||||
private String diseaseTypeName;
|
||||
|
||||
/** 宣教链接 */
|
||||
@ApiModelProperty(value = "宣教链接")
|
||||
private String propagandaLink;
|
||||
|
||||
/** 宣教二维码图片存放地址 */
|
||||
@ApiModelProperty(value = "宣教二维码图片存放地址")
|
||||
private String propagandaBarcodePath;
|
||||
|
||||
@ApiModelProperty("关联的素材列表")
|
||||
List<MaterialsInfo> materialsInfoList;
|
||||
}
|
||||
@ -24,6 +24,7 @@
|
||||
<result property="materialsStatus" column="materials_status"/>
|
||||
<result property="materialsRemark" column="materials_remark"/>
|
||||
<result property="materialsSort" column="materials_sort"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
@ -31,12 +32,13 @@
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectMaterialsInfoVo">
|
||||
select id, materials_name, materials_type, materials_option, materials_file_path, video_cover_type, video_cover_file_path, materials_abstract, indications, applicable_diseases, drug_name, surgical_name, check_items, inspection_items, crowd_id, crow_name, materials_status, materials_remark, materials_sort, create_by, create_time, update_by, update_time from materials_info
|
||||
select id, materials_name, materials_type, materials_option, materials_file_path, video_cover_type, video_cover_file_path, materials_abstract, indications, applicable_diseases, drug_name, surgical_name, check_items, inspection_items, crowd_id, crow_name, materials_status, materials_remark, materials_sort, del_flag, create_by, create_time, update_by, update_time from materials_info
|
||||
</sql>
|
||||
|
||||
<select id="selectMaterialsInfoList" parameterType="com.xinelu.manage.dto.materialsinfo.MaterialsInfoDto" resultMap="MaterialsInfoResult">
|
||||
<include refid="selectMaterialsInfoVo"/>
|
||||
<where>
|
||||
del_flag = 0
|
||||
<if test="materialsName != null and materialsName != ''">
|
||||
and materials_name like concat('%', #{materialsName}, '%')
|
||||
</if>
|
||||
@ -101,6 +103,8 @@
|
||||
</if>
|
||||
<if test="materialsSort != null">materials_sort,
|
||||
</if>
|
||||
<if test="delFlag != null">del_flag,
|
||||
</if>
|
||||
<if test="createBy != null">create_by,
|
||||
</if>
|
||||
<if test="createTime != null">create_time,
|
||||
@ -147,6 +151,8 @@
|
||||
</if>
|
||||
<if test="materialsSort != null">#{materialsSort},
|
||||
</if>
|
||||
<if test="delFlag != null">#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
@ -215,6 +221,9 @@
|
||||
<if test="materialsSort != null">materials_sort =
|
||||
#{materialsSort},
|
||||
</if>
|
||||
<if test="delFlag != null">del_flag =
|
||||
#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
@ -231,14 +240,14 @@
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteMaterialsInfoById" parameterType="Long">
|
||||
delete from materials_info where id = #{id}
|
||||
</delete>
|
||||
<update id="deleteMaterialsInfoById" parameterType="Long">
|
||||
update materials_info set del_flag = 1 where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteMaterialsInfoByIds" parameterType="String">
|
||||
delete from materials_info where id in
|
||||
<update id="deleteMaterialsInfoByIds" parameterType="String">
|
||||
update materials_info set del_flag = 1 where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</update>
|
||||
</mapper>
|
||||
@ -5,6 +5,7 @@
|
||||
<mapper namespace="com.xinelu.manage.mapper.patientinfo.PatientInfoMapper">
|
||||
<resultMap type="com.xinelu.manage.domain.patientinfo.PatientInfo" id="PatientInfoResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="residentId" column="resident_id" />
|
||||
<result property="patientName" column="patient_name" />
|
||||
<result property="patientPhone" column="patient_phone" />
|
||||
<result property="familyMemberPhone" column="family_member_phone" />
|
||||
@ -41,8 +42,6 @@
|
||||
<result property="inHospitalNumber" column="in_hospital_number" />
|
||||
<result property="visitDate" column="visit_date" />
|
||||
<result property="dischargeMethod" column="discharge_method" />
|
||||
<result property="openId" column="open_id" />
|
||||
<result property="unionId" column="union_id" />
|
||||
<result property="patientSource" column="patient_source" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
<result property="createBy" column="create_by" />
|
||||
@ -52,7 +51,7 @@
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectPatientInfoVo">
|
||||
select id,
|
||||
select id,resident_id,
|
||||
patient_name,
|
||||
patient_phone,
|
||||
family_member_phone,
|
||||
@ -68,7 +67,7 @@
|
||||
responsible_nurse, patient_visit_record_id, visit_serial_number,
|
||||
admission_date, discharge_date, appointment_treatment_group,
|
||||
registration_no, registration_date, appointment_date, in_hospital_number, visit_date, discharge_method,
|
||||
open_id, union_id, patient_source, del_flag, create_by, create_time, update_by, update_time
|
||||
patient_source, del_flag, create_by, create_time, update_by, update_time
|
||||
from patient_info
|
||||
</sql>
|
||||
|
||||
@ -158,7 +157,7 @@
|
||||
</select>
|
||||
|
||||
<select id="getPatientBaseInfo" parameterType="Long" resultType="com.xinelu.manage.vo.patientinfo.PatientBaseInfoVo">
|
||||
select id, patient_name, patient_phone, family_member_phone,
|
||||
select id, resident_id, patient_name, patient_phone, family_member_phone,
|
||||
birth_date, card_no, sex, address
|
||||
from patient_info
|
||||
where id = #{id}
|
||||
@ -167,6 +166,9 @@
|
||||
<insert id="insertPatientInfo" parameterType="com.xinelu.manage.domain.patientinfo.PatientInfo" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into patient_info
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="residentId != null">
|
||||
resident_id,
|
||||
</if>
|
||||
<if test="patientName != null">
|
||||
patient_name,
|
||||
</if>
|
||||
@ -245,10 +247,6 @@
|
||||
</if>
|
||||
<if test="dischargeMethod != null">discharge_method,
|
||||
</if>
|
||||
<if test="openId != null">open_id,
|
||||
</if>
|
||||
<if test="unionId != null">union_id,
|
||||
</if>
|
||||
<if test="patientSource != null">patient_source,
|
||||
</if>
|
||||
<if test="delFlag != null">del_flag,
|
||||
@ -263,6 +261,8 @@
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="residentId != null">#{residentId},
|
||||
</if>
|
||||
<if test="patientName != null">#{patientName},
|
||||
</if>
|
||||
<if test="patientPhone != null">#{patientPhone},
|
||||
@ -335,10 +335,6 @@
|
||||
</if>
|
||||
<if test="dischargeMethod != null">#{dischargeMethod},
|
||||
</if>
|
||||
<if test="openId != null">#{openId},
|
||||
</if>
|
||||
<if test="unionId != null">#{unionId},
|
||||
</if>
|
||||
<if test="patientSource != null">#{patientSource},
|
||||
</if>
|
||||
<if test="delFlag != null">#{delFlag},
|
||||
@ -357,6 +353,9 @@
|
||||
<update id="updatePatientInfo" parameterType="com.xinelu.manage.domain.patientinfo.PatientInfo">
|
||||
update patient_info
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="residentId != null">
|
||||
resident_id = #{residentId},
|
||||
</if>
|
||||
<if test="patientName != null">
|
||||
patient_name = #{patientName},
|
||||
</if>
|
||||
@ -463,12 +462,6 @@
|
||||
<if test="dischargeMethod != null">discharge_method =
|
||||
#{dischargeMethod},
|
||||
</if>
|
||||
<if test="openId != null">open_id =
|
||||
#{openId},
|
||||
</if>
|
||||
<if test="unionId != null">union_id =
|
||||
#{unionId},
|
||||
</if>
|
||||
<if test="patientSource != null">patient_source =
|
||||
#{patientSource},
|
||||
</if>
|
||||
|
||||
@ -1,44 +1,44 @@
|
||||
<?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">
|
||||
<?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.xinelu.manage.mapper.patientprehospitalization.PatientPreHospitalizationMapper">
|
||||
|
||||
<resultMap id="BaseResultMap" type="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization">
|
||||
<id property="id" column="id" jdbcType="BIGINT"/>
|
||||
<result property="patientId" column="patient_id" jdbcType="BIGINT"/>
|
||||
<result property="patientName" column="patient_name" jdbcType="VARCHAR"/>
|
||||
<result property="patientPhone" column="patient_phone" jdbcType="VARCHAR"/>
|
||||
<result property="cardNo" column="card_no" jdbcType="VARCHAR"/>
|
||||
<result property="sex" column="sex" jdbcType="VARCHAR"/>
|
||||
<result property="birthDate" column="birth_date" jdbcType="DATE"/>
|
||||
<result property="familyMemberPhone" column="family_member_phone" jdbcType="VARCHAR"/>
|
||||
<result property="address" column="address" jdbcType="VARCHAR"/>
|
||||
<result property="mainDiagnosis" column="main_diagnosis" jdbcType="VARCHAR"/>
|
||||
<result property="hospitalAgencyId" column="hospital_agency_id" jdbcType="BIGINT"/>
|
||||
<result property="hospitalAgencyName" column="hospital_agency_name" jdbcType="VARCHAR"/>
|
||||
<result property="campusAgencyId" column="campus_agency_id" jdbcType="BIGINT"/>
|
||||
<result property="campusAgencyName" column="campus_agency_name" jdbcType="VARCHAR"/>
|
||||
<result property="departmentId" column="department_id" jdbcType="BIGINT"/>
|
||||
<result property="departmentName" column="department_name" jdbcType="VARCHAR"/>
|
||||
<result property="wardId" column="ward_id" jdbcType="BIGINT"/>
|
||||
<result property="wardName" column="ward_name" jdbcType="VARCHAR"/>
|
||||
<result property="appointmentTreatmentGroup" column="appointment_treatment_group" jdbcType="VARCHAR"/>
|
||||
<result property="registrationNo" column="registration_no" jdbcType="VARCHAR"/>
|
||||
<result property="registrationDate" column="registration_date" jdbcType="DATE"/>
|
||||
<result property="appointmentDate" column="appointment_date" jdbcType="DATE"/>
|
||||
<result property="certificateIssuingDoctorId" column="certificate_issuing_doctor_id" jdbcType="BIGINT"/>
|
||||
<result property="certificateIssuingDoctorName" column="certificate_issuing_doctor_name" jdbcType="VARCHAR"/>
|
||||
<result property="responsibleNurse" column="responsible_nurse" jdbcType="VARCHAR"/>
|
||||
<result property="delFlag" column="del_flag" jdbcType="TINYINT"/>
|
||||
<result property="createBy" column="create_by" jdbcType="VARCHAR"/>
|
||||
<result property="createTime" column="create_time" jdbcType="TIMESTAMP"/>
|
||||
<result property="updateBy" column="update_by" jdbcType="VARCHAR"/>
|
||||
<result property="updateTime" column="update_time" jdbcType="TIMESTAMP"/>
|
||||
</resultMap>
|
||||
<resultMap id="BaseResultMap" type="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization">
|
||||
<id property="id" column="id" jdbcType="BIGINT" />
|
||||
<result property="residentId" column="resident_id" jdbcType="BIGINT" />
|
||||
<result property="patientId" column="patient_id" jdbcType="BIGINT" />
|
||||
<result property="patientName" column="patient_name" jdbcType="VARCHAR" />
|
||||
<result property="patientPhone" column="patient_phone" jdbcType="VARCHAR" />
|
||||
<result property="cardNo" column="card_no" jdbcType="VARCHAR" />
|
||||
<result property="sex" column="sex" jdbcType="VARCHAR" />
|
||||
<result property="birthDate" column="birth_date" jdbcType="DATE" />
|
||||
<result property="familyMemberPhone" column="family_member_phone" jdbcType="VARCHAR" />
|
||||
<result property="address" column="address" jdbcType="VARCHAR" />
|
||||
<result property="mainDiagnosis" column="main_diagnosis" jdbcType="VARCHAR" />
|
||||
<result property="hospitalAgencyId" column="hospital_agency_id" jdbcType="BIGINT" />
|
||||
<result property="hospitalAgencyName" column="hospital_agency_name" jdbcType="VARCHAR" />
|
||||
<result property="campusAgencyId" column="campus_agency_id" jdbcType="BIGINT" />
|
||||
<result property="campusAgencyName" column="campus_agency_name" jdbcType="VARCHAR" />
|
||||
<result property="departmentId" column="department_id" jdbcType="BIGINT" />
|
||||
<result property="departmentName" column="department_name" jdbcType="VARCHAR" />
|
||||
<result property="wardId" column="ward_id" jdbcType="BIGINT" />
|
||||
<result property="wardName" column="ward_name" jdbcType="VARCHAR" />
|
||||
<result property="appointmentTreatmentGroup" column="appointment_treatment_group" jdbcType="VARCHAR" />
|
||||
<result property="registrationNo" column="registration_no" jdbcType="VARCHAR" />
|
||||
<result property="registrationDate" column="registration_date" jdbcType="DATE" />
|
||||
<result property="appointmentDate" column="appointment_date" jdbcType="DATE" />
|
||||
<result property="certificateIssuingDoctorId" column="certificate_issuing_doctor_id" jdbcType="BIGINT" />
|
||||
<result property="certificateIssuingDoctorName" column="certificate_issuing_doctor_name" jdbcType="VARCHAR" />
|
||||
<result property="responsibleNurse" column="responsible_nurse" jdbcType="VARCHAR" />
|
||||
<result property="delFlag" column="del_flag" jdbcType="TINYINT" />
|
||||
<result property="createBy" column="create_by" jdbcType="VARCHAR" />
|
||||
<result property="createTime" column="create_time" jdbcType="TIMESTAMP" />
|
||||
<result property="updateBy" column="update_by" jdbcType="VARCHAR" />
|
||||
<result property="updateTime" column="update_time" jdbcType="TIMESTAMP" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="Base_Column_List">
|
||||
id,patient_id,patient_name,
|
||||
<sql id="Base_Column_List">
|
||||
id,resident_id,patient_id,patient_name,
|
||||
patient_phone,card_no,sex,
|
||||
birth_date,family_member_phone,address,
|
||||
main_diagnosis,hospital_agency_id,hospital_agency_name,
|
||||
@ -48,238 +48,243 @@
|
||||
appointment_date,certificate_issuing_doctor_id,certificate_issuing_doctor_name,
|
||||
responsible_nurse,del_flag,create_by,
|
||||
create_time,update_by,update_time
|
||||
</sql>
|
||||
</sql>
|
||||
|
||||
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
|
||||
select
|
||||
<include refid="Base_Column_List" />
|
||||
from patient_pre_hospitalization
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</select>
|
||||
|
||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
|
||||
delete from patient_pre_hospitalization
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</delete>
|
||||
<insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization" useGeneratedKeys="true">
|
||||
insert into patient_pre_hospitalization
|
||||
( id,patient_id,patient_name
|
||||
,patient_phone,card_no,sex
|
||||
,birth_date,family_member_phone,address
|
||||
,main_diagnosis,hospital_agency_id,hospital_agency_name
|
||||
,campus_agency_id,campus_agency_name,department_id
|
||||
,department_name,ward_id,ward_name
|
||||
,appointment_treatment_group,registration_no,registration_date
|
||||
,appointment_date,certificate_issuing_doctor_id,certificate_issuing_doctor_name
|
||||
,responsible_nurse,del_flag,create_by
|
||||
,create_time,update_by,update_time
|
||||
)
|
||||
values (#{id,jdbcType=BIGINT},#{patientId,jdbcType=BIGINT},#{patientName,jdbcType=VARCHAR}
|
||||
,#{patientPhone,jdbcType=VARCHAR},#{cardNo,jdbcType=VARCHAR},#{sex,jdbcType=VARCHAR}
|
||||
,#{birthDate,jdbcType=DATE},#{familyMemberPhone,jdbcType=VARCHAR},#{address,jdbcType=VARCHAR}
|
||||
,#{mainDiagnosis,jdbcType=VARCHAR},#{hospitalAgencyId,jdbcType=BIGINT},#{hospitalAgencyName,jdbcType=VARCHAR}
|
||||
,#{campusAgencyId,jdbcType=BIGINT},#{campusAgencyName,jdbcType=VARCHAR},#{departmentId,jdbcType=BIGINT}
|
||||
,#{departmentName,jdbcType=VARCHAR},#{wardId,jdbcType=BIGINT},#{wardName,jdbcType=VARCHAR}
|
||||
,#{appointmentTreatmentGroup,jdbcType=VARCHAR},#{registrationNo,jdbcType=VARCHAR},#{registrationDate,jdbcType=DATE}
|
||||
,#{appointmentDate,jdbcType=DATE},#{certificateIssuingDoctorId,jdbcType=BIGINT},#{certificateIssuingDoctorName,jdbcType=VARCHAR}
|
||||
,#{responsibleNurse,jdbcType=VARCHAR},#{delFlag,jdbcType=TINYINT},#{createBy,jdbcType=VARCHAR}
|
||||
,#{createTime,jdbcType=TIMESTAMP},#{updateBy,jdbcType=VARCHAR},#{updateTime,jdbcType=TIMESTAMP}
|
||||
)
|
||||
</insert>
|
||||
<insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization" useGeneratedKeys="true">
|
||||
insert into patient_pre_hospitalization
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,</if>
|
||||
<if test="patientId != null">patient_id,</if>
|
||||
<if test="patientName != null">patient_name,</if>
|
||||
<if test="patientPhone != null">patient_phone,</if>
|
||||
<if test="cardNo != null">card_no,</if>
|
||||
<if test="sex != null">sex,</if>
|
||||
<if test="birthDate != null">birth_date,</if>
|
||||
<if test="familyMemberPhone != null">family_member_phone,</if>
|
||||
<if test="address != null">address,</if>
|
||||
<if test="mainDiagnosis != null">main_diagnosis,</if>
|
||||
<if test="hospitalAgencyId != null">hospital_agency_id,</if>
|
||||
<if test="hospitalAgencyName != null">hospital_agency_name,</if>
|
||||
<if test="campusAgencyId != null">campus_agency_id,</if>
|
||||
<if test="campusAgencyName != null">campus_agency_name,</if>
|
||||
<if test="departmentId != null">department_id,</if>
|
||||
<if test="departmentName != null">department_name,</if>
|
||||
<if test="wardId != null">ward_id,</if>
|
||||
<if test="wardName != null">ward_name,</if>
|
||||
<if test="appointmentTreatmentGroup != null">appointment_treatment_group,</if>
|
||||
<if test="registrationNo != null">registration_no,</if>
|
||||
<if test="registrationDate != null">registration_date,</if>
|
||||
<if test="appointmentDate != null">appointment_date,</if>
|
||||
<if test="certificateIssuingDoctorId != null">certificate_issuing_doctor_id,</if>
|
||||
<if test="certificateIssuingDoctorName != null">certificate_issuing_doctor_name,</if>
|
||||
<if test="responsibleNurse != null">responsible_nurse,</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>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">#{id,jdbcType=BIGINT},</if>
|
||||
<if test="patientId != null">#{patientId,jdbcType=BIGINT},</if>
|
||||
<if test="patientName != null">#{patientName,jdbcType=VARCHAR},</if>
|
||||
<if test="patientPhone != null">#{patientPhone,jdbcType=VARCHAR},</if>
|
||||
<if test="cardNo != null">#{cardNo,jdbcType=VARCHAR},</if>
|
||||
<if test="sex != null">#{sex,jdbcType=VARCHAR},</if>
|
||||
<if test="birthDate != null">#{birthDate,jdbcType=DATE},</if>
|
||||
<if test="familyMemberPhone != null">#{familyMemberPhone,jdbcType=VARCHAR},</if>
|
||||
<if test="address != null">#{address,jdbcType=VARCHAR},</if>
|
||||
<if test="mainDiagnosis != null">#{mainDiagnosis,jdbcType=VARCHAR},</if>
|
||||
<if test="hospitalAgencyId != null">#{hospitalAgencyId,jdbcType=BIGINT},</if>
|
||||
<if test="hospitalAgencyName != null">#{hospitalAgencyName,jdbcType=VARCHAR},</if>
|
||||
<if test="campusAgencyId != null">#{campusAgencyId,jdbcType=BIGINT},</if>
|
||||
<if test="campusAgencyName != null">#{campusAgencyName,jdbcType=VARCHAR},</if>
|
||||
<if test="departmentId != null">#{departmentId,jdbcType=BIGINT},</if>
|
||||
<if test="departmentName != null">#{departmentName,jdbcType=VARCHAR},</if>
|
||||
<if test="wardId != null">#{wardId,jdbcType=BIGINT},</if>
|
||||
<if test="wardName != null">#{wardName,jdbcType=VARCHAR},</if>
|
||||
<if test="appointmentTreatmentGroup != null">#{appointmentTreatmentGroup,jdbcType=VARCHAR},</if>
|
||||
<if test="registrationNo != null">#{registrationNo,jdbcType=VARCHAR},</if>
|
||||
<if test="registrationDate != null">#{registrationDate,jdbcType=DATE},</if>
|
||||
<if test="appointmentDate != null">#{appointmentDate,jdbcType=DATE},</if>
|
||||
<if test="certificateIssuingDoctorId != null">#{certificateIssuingDoctorId,jdbcType=BIGINT},</if>
|
||||
<if test="certificateIssuingDoctorName != null">#{certificateIssuingDoctorName,jdbcType=VARCHAR},</if>
|
||||
<if test="responsibleNurse != null">#{responsibleNurse,jdbcType=VARCHAR},</if>
|
||||
<if test="delFlag != null">#{delFlag,jdbcType=TINYINT},</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>
|
||||
</trim>
|
||||
</insert>
|
||||
<update id="updateByPrimaryKeySelective" parameterType="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization">
|
||||
update patient_pre_hospitalization
|
||||
<set>
|
||||
<if test="patientId != null">
|
||||
patient_id = #{patientId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="patientName != null">
|
||||
patient_name = #{patientName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="patientPhone != null">
|
||||
patient_phone = #{patientPhone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="cardNo != null">
|
||||
card_no = #{cardNo,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="sex != null">
|
||||
sex = #{sex,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="birthDate != null">
|
||||
birth_date = #{birthDate,jdbcType=DATE},
|
||||
</if>
|
||||
<if test="familyMemberPhone != null">
|
||||
family_member_phone = #{familyMemberPhone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="address != null">
|
||||
address = #{address,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="mainDiagnosis != null">
|
||||
main_diagnosis = #{mainDiagnosis,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="hospitalAgencyId != null">
|
||||
hospital_agency_id = #{hospitalAgencyId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="hospitalAgencyName != null">
|
||||
hospital_agency_name = #{hospitalAgencyName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="campusAgencyId != null">
|
||||
campus_agency_id = #{campusAgencyId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="campusAgencyName != null">
|
||||
campus_agency_name = #{campusAgencyName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="departmentId != null">
|
||||
department_id = #{departmentId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="departmentName != null">
|
||||
department_name = #{departmentName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="wardId != null">
|
||||
ward_id = #{wardId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="wardName != null">
|
||||
ward_name = #{wardName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="appointmentTreatmentGroup != null">
|
||||
appointment_treatment_group = #{appointmentTreatmentGroup,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="registrationNo != null">
|
||||
registration_no = #{registrationNo,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="registrationDate != null">
|
||||
registration_date = #{registrationDate,jdbcType=DATE},
|
||||
</if>
|
||||
<if test="appointmentDate != null">
|
||||
appointment_date = #{appointmentDate,jdbcType=DATE},
|
||||
</if>
|
||||
<if test="certificateIssuingDoctorId != null">
|
||||
certificate_issuing_doctor_id = #{certificateIssuingDoctorId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="certificateIssuingDoctorName != null">
|
||||
certificate_issuing_doctor_name = #{certificateIssuingDoctorName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="responsibleNurse != null">
|
||||
responsible_nurse = #{responsibleNurse,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="delFlag != null">
|
||||
del_flag = #{delFlag,jdbcType=TINYINT},
|
||||
</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>
|
||||
</set>
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
<update id="updateByPrimaryKey" parameterType="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization">
|
||||
update patient_pre_hospitalization
|
||||
set
|
||||
patient_id = #{patientId,jdbcType=BIGINT},
|
||||
patient_name = #{patientName,jdbcType=VARCHAR},
|
||||
patient_phone = #{patientPhone,jdbcType=VARCHAR},
|
||||
card_no = #{cardNo,jdbcType=VARCHAR},
|
||||
sex = #{sex,jdbcType=VARCHAR},
|
||||
birth_date = #{birthDate,jdbcType=DATE},
|
||||
family_member_phone = #{familyMemberPhone,jdbcType=VARCHAR},
|
||||
address = #{address,jdbcType=VARCHAR},
|
||||
main_diagnosis = #{mainDiagnosis,jdbcType=VARCHAR},
|
||||
hospital_agency_id = #{hospitalAgencyId,jdbcType=BIGINT},
|
||||
hospital_agency_name = #{hospitalAgencyName,jdbcType=VARCHAR},
|
||||
campus_agency_id = #{campusAgencyId,jdbcType=BIGINT},
|
||||
campus_agency_name = #{campusAgencyName,jdbcType=VARCHAR},
|
||||
department_id = #{departmentId,jdbcType=BIGINT},
|
||||
department_name = #{departmentName,jdbcType=VARCHAR},
|
||||
ward_id = #{wardId,jdbcType=BIGINT},
|
||||
ward_name = #{wardName,jdbcType=VARCHAR},
|
||||
appointment_treatment_group = #{appointmentTreatmentGroup,jdbcType=VARCHAR},
|
||||
registration_no = #{registrationNo,jdbcType=VARCHAR},
|
||||
registration_date = #{registrationDate,jdbcType=DATE},
|
||||
appointment_date = #{appointmentDate,jdbcType=DATE},
|
||||
certificate_issuing_doctor_id = #{certificateIssuingDoctorId,jdbcType=BIGINT},
|
||||
certificate_issuing_doctor_name = #{certificateIssuingDoctorName,jdbcType=VARCHAR},
|
||||
responsible_nurse = #{responsibleNurse,jdbcType=VARCHAR},
|
||||
del_flag = #{delFlag,jdbcType=TINYINT},
|
||||
create_by = #{createBy,jdbcType=VARCHAR},
|
||||
create_time = #{createTime,jdbcType=TIMESTAMP},
|
||||
update_by = #{updateBy,jdbcType=VARCHAR},
|
||||
update_time = #{updateTime,jdbcType=TIMESTAMP}
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
|
||||
delete
|
||||
from patient_pre_hospitalization
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</delete>
|
||||
<insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization" useGeneratedKeys="true">
|
||||
insert into patient_pre_hospitalization
|
||||
( id, resident_id, patient_id, patient_name
|
||||
, patient_phone, card_no, sex
|
||||
, birth_date, family_member_phone, address
|
||||
, main_diagnosis, hospital_agency_id, hospital_agency_name
|
||||
, campus_agency_id, campus_agency_name, department_id
|
||||
, department_name, ward_id, ward_name
|
||||
, appointment_treatment_group, registration_no, registration_date
|
||||
, appointment_date, certificate_issuing_doctor_id, certificate_issuing_doctor_name
|
||||
, responsible_nurse, del_flag, create_by
|
||||
, create_time, update_by, update_time)
|
||||
values ( #{id,jdbcType=BIGINT}, #{residentId,jdbcType=BIGINT}, #{patientId,jdbcType=BIGINT}, #{patientName,jdbcType=VARCHAR}
|
||||
, #{patientPhone,jdbcType=VARCHAR}, #{cardNo,jdbcType=VARCHAR}, #{sex,jdbcType=VARCHAR}
|
||||
, #{birthDate,jdbcType=DATE}, #{familyMemberPhone,jdbcType=VARCHAR}, #{address,jdbcType=VARCHAR}
|
||||
, #{mainDiagnosis,jdbcType=VARCHAR}, #{hospitalAgencyId,jdbcType=BIGINT}, #{hospitalAgencyName,jdbcType=VARCHAR}
|
||||
, #{campusAgencyId,jdbcType=BIGINT}, #{campusAgencyName,jdbcType=VARCHAR}, #{departmentId,jdbcType=BIGINT}
|
||||
, #{departmentName,jdbcType=VARCHAR}, #{wardId,jdbcType=BIGINT}, #{wardName,jdbcType=VARCHAR}
|
||||
, #{appointmentTreatmentGroup,jdbcType=VARCHAR}, #{registrationNo,jdbcType=VARCHAR}, #{registrationDate,jdbcType=DATE}
|
||||
, #{appointmentDate,jdbcType=DATE}, #{certificateIssuingDoctorId,jdbcType=BIGINT}, #{certificateIssuingDoctorName,jdbcType=VARCHAR}
|
||||
, #{responsibleNurse,jdbcType=VARCHAR}, #{delFlag,jdbcType=TINYINT}, #{createBy,jdbcType=VARCHAR}
|
||||
, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP})
|
||||
</insert>
|
||||
<insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization" useGeneratedKeys="true">
|
||||
insert into patient_pre_hospitalization
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,</if>
|
||||
<if test="residentId != null">resident_id,</if>
|
||||
<if test="patientId != null">patient_id,</if>
|
||||
<if test="patientName != null">patient_name,</if>
|
||||
<if test="patientPhone != null">patient_phone,</if>
|
||||
<if test="cardNo != null">card_no,</if>
|
||||
<if test="sex != null">sex,</if>
|
||||
<if test="birthDate != null">birth_date,</if>
|
||||
<if test="familyMemberPhone != null">family_member_phone,</if>
|
||||
<if test="address != null">address,</if>
|
||||
<if test="mainDiagnosis != null">main_diagnosis,</if>
|
||||
<if test="hospitalAgencyId != null">hospital_agency_id,</if>
|
||||
<if test="hospitalAgencyName != null">hospital_agency_name,</if>
|
||||
<if test="campusAgencyId != null">campus_agency_id,</if>
|
||||
<if test="campusAgencyName != null">campus_agency_name,</if>
|
||||
<if test="departmentId != null">department_id,</if>
|
||||
<if test="departmentName != null">department_name,</if>
|
||||
<if test="wardId != null">ward_id,</if>
|
||||
<if test="wardName != null">ward_name,</if>
|
||||
<if test="appointmentTreatmentGroup != null">appointment_treatment_group,</if>
|
||||
<if test="registrationNo != null">registration_no,</if>
|
||||
<if test="registrationDate != null">registration_date,</if>
|
||||
<if test="appointmentDate != null">appointment_date,</if>
|
||||
<if test="certificateIssuingDoctorId != null">certificate_issuing_doctor_id,</if>
|
||||
<if test="certificateIssuingDoctorName != null">certificate_issuing_doctor_name,</if>
|
||||
<if test="responsibleNurse != null">responsible_nurse,</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>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">#{id,jdbcType=BIGINT},</if>
|
||||
<if test="residentId != null">#{residentId,jdbcType=BIGINT},</if>
|
||||
<if test="patientId != null">#{patientId,jdbcType=BIGINT},</if>
|
||||
<if test="patientName != null">#{patientName,jdbcType=VARCHAR},</if>
|
||||
<if test="patientPhone != null">#{patientPhone,jdbcType=VARCHAR},</if>
|
||||
<if test="cardNo != null">#{cardNo,jdbcType=VARCHAR},</if>
|
||||
<if test="sex != null">#{sex,jdbcType=VARCHAR},</if>
|
||||
<if test="birthDate != null">#{birthDate,jdbcType=DATE},</if>
|
||||
<if test="familyMemberPhone != null">#{familyMemberPhone,jdbcType=VARCHAR},</if>
|
||||
<if test="address != null">#{address,jdbcType=VARCHAR},</if>
|
||||
<if test="mainDiagnosis != null">#{mainDiagnosis,jdbcType=VARCHAR},</if>
|
||||
<if test="hospitalAgencyId != null">#{hospitalAgencyId,jdbcType=BIGINT},</if>
|
||||
<if test="hospitalAgencyName != null">#{hospitalAgencyName,jdbcType=VARCHAR},</if>
|
||||
<if test="campusAgencyId != null">#{campusAgencyId,jdbcType=BIGINT},</if>
|
||||
<if test="campusAgencyName != null">#{campusAgencyName,jdbcType=VARCHAR},</if>
|
||||
<if test="departmentId != null">#{departmentId,jdbcType=BIGINT},</if>
|
||||
<if test="departmentName != null">#{departmentName,jdbcType=VARCHAR},</if>
|
||||
<if test="wardId != null">#{wardId,jdbcType=BIGINT},</if>
|
||||
<if test="wardName != null">#{wardName,jdbcType=VARCHAR},</if>
|
||||
<if test="appointmentTreatmentGroup != null">#{appointmentTreatmentGroup,jdbcType=VARCHAR},</if>
|
||||
<if test="registrationNo != null">#{registrationNo,jdbcType=VARCHAR},</if>
|
||||
<if test="registrationDate != null">#{registrationDate,jdbcType=DATE},</if>
|
||||
<if test="appointmentDate != null">#{appointmentDate,jdbcType=DATE},</if>
|
||||
<if test="certificateIssuingDoctorId != null">#{certificateIssuingDoctorId,jdbcType=BIGINT},</if>
|
||||
<if test="certificateIssuingDoctorName != null">#{certificateIssuingDoctorName,jdbcType=VARCHAR},</if>
|
||||
<if test="responsibleNurse != null">#{responsibleNurse,jdbcType=VARCHAR},</if>
|
||||
<if test="delFlag != null">#{delFlag,jdbcType=TINYINT},</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>
|
||||
</trim>
|
||||
</insert>
|
||||
<update id="updateByPrimaryKeySelective" parameterType="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization">
|
||||
update patient_pre_hospitalization
|
||||
<set>
|
||||
<if test="residentId != null">
|
||||
resident_id = #{residentId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="patientId != null">
|
||||
patient_id = #{patientId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="patientName != null">
|
||||
patient_name = #{patientName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="patientPhone != null">
|
||||
patient_phone = #{patientPhone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="cardNo != null">
|
||||
card_no = #{cardNo,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="sex != null">
|
||||
sex = #{sex,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="birthDate != null">
|
||||
birth_date = #{birthDate,jdbcType=DATE},
|
||||
</if>
|
||||
<if test="familyMemberPhone != null">
|
||||
family_member_phone = #{familyMemberPhone,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="address != null">
|
||||
address = #{address,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="mainDiagnosis != null">
|
||||
main_diagnosis = #{mainDiagnosis,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="hospitalAgencyId != null">
|
||||
hospital_agency_id = #{hospitalAgencyId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="hospitalAgencyName != null">
|
||||
hospital_agency_name = #{hospitalAgencyName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="campusAgencyId != null">
|
||||
campus_agency_id = #{campusAgencyId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="campusAgencyName != null">
|
||||
campus_agency_name = #{campusAgencyName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="departmentId != null">
|
||||
department_id = #{departmentId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="departmentName != null">
|
||||
department_name = #{departmentName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="wardId != null">
|
||||
ward_id = #{wardId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="wardName != null">
|
||||
ward_name = #{wardName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="appointmentTreatmentGroup != null">
|
||||
appointment_treatment_group = #{appointmentTreatmentGroup,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="registrationNo != null">
|
||||
registration_no = #{registrationNo,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="registrationDate != null">
|
||||
registration_date = #{registrationDate,jdbcType=DATE},
|
||||
</if>
|
||||
<if test="appointmentDate != null">
|
||||
appointment_date = #{appointmentDate,jdbcType=DATE},
|
||||
</if>
|
||||
<if test="certificateIssuingDoctorId != null">
|
||||
certificate_issuing_doctor_id = #{certificateIssuingDoctorId,jdbcType=BIGINT},
|
||||
</if>
|
||||
<if test="certificateIssuingDoctorName != null">
|
||||
certificate_issuing_doctor_name = #{certificateIssuingDoctorName,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="responsibleNurse != null">
|
||||
responsible_nurse = #{responsibleNurse,jdbcType=VARCHAR},
|
||||
</if>
|
||||
<if test="delFlag != null">
|
||||
del_flag = #{delFlag,jdbcType=TINYINT},
|
||||
</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>
|
||||
</set>
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
<update id="updateByPrimaryKey" parameterType="com.xinelu.manage.domain.patientprehospitalization.PatientPreHospitalization">
|
||||
update patient_pre_hospitalization
|
||||
set
|
||||
resident_id = #{residentId,jdbcType=BIGINT},
|
||||
patient_id = #{patientId,jdbcType=BIGINT},
|
||||
patient_name = #{patientName,jdbcType=VARCHAR},
|
||||
patient_phone = #{patientPhone,jdbcType=VARCHAR},
|
||||
card_no = #{cardNo,jdbcType=VARCHAR},
|
||||
sex = #{sex,jdbcType=VARCHAR},
|
||||
birth_date = #{birthDate,jdbcType=DATE},
|
||||
family_member_phone = #{familyMemberPhone,jdbcType=VARCHAR},
|
||||
address = #{address,jdbcType=VARCHAR},
|
||||
main_diagnosis = #{mainDiagnosis,jdbcType=VARCHAR},
|
||||
hospital_agency_id = #{hospitalAgencyId,jdbcType=BIGINT},
|
||||
hospital_agency_name = #{hospitalAgencyName,jdbcType=VARCHAR},
|
||||
campus_agency_id = #{campusAgencyId,jdbcType=BIGINT},
|
||||
campus_agency_name = #{campusAgencyName,jdbcType=VARCHAR},
|
||||
department_id = #{departmentId,jdbcType=BIGINT},
|
||||
department_name = #{departmentName,jdbcType=VARCHAR},
|
||||
ward_id = #{wardId,jdbcType=BIGINT},
|
||||
ward_name = #{wardName,jdbcType=VARCHAR},
|
||||
appointment_treatment_group = #{appointmentTreatmentGroup,jdbcType=VARCHAR},
|
||||
registration_no = #{registrationNo,jdbcType=VARCHAR},
|
||||
registration_date = #{registrationDate,jdbcType=DATE},
|
||||
appointment_date = #{appointmentDate,jdbcType=DATE},
|
||||
certificate_issuing_doctor_id = #{certificateIssuingDoctorId,jdbcType=BIGINT},
|
||||
certificate_issuing_doctor_name = #{certificateIssuingDoctorName,jdbcType=VARCHAR},
|
||||
responsible_nurse = #{responsibleNurse,jdbcType=VARCHAR},
|
||||
del_flag = #{delFlag,jdbcType=TINYINT},
|
||||
create_by = #{createBy,jdbcType=VARCHAR},
|
||||
create_time = #{createTime,jdbcType=TIMESTAMP},
|
||||
update_by = #{updateBy,jdbcType=VARCHAR},
|
||||
update_time = #{updateTime,jdbcType=TIMESTAMP}
|
||||
where id = #{id,jdbcType=BIGINT}
|
||||
</update>
|
||||
|
||||
<select id="selectList" parameterType="com.xinelu.manage.dto.patientinfo.PatientInfoDto" resultMap="BaseResultMap">
|
||||
select
|
||||
@ -318,8 +323,8 @@
|
||||
<if test="appointmentTreatmentGroup != null and appointmentTreatmentGroup != ''">
|
||||
and p.appointment_treatment_group = #{appointmentTreatmentGroup}
|
||||
</if>
|
||||
<if test="certificateIssuingDoctor != null and certificateIssuingDoctor != ''">
|
||||
and p.certificate_issuing_doctor = #{certificateIssuingDoctor}
|
||||
<if test="certificateIssuingDoctorId != null and certificateIssuingDoctorId != ''">
|
||||
and p.certificate_issuing_doctor_id = #{certificateIssuingDoctorId}
|
||||
</if>
|
||||
<if test="registrationNo != null and registrationNo != ''">
|
||||
and p.registration_no = #{registrationNo}
|
||||
@ -348,7 +353,7 @@
|
||||
</foreach>
|
||||
</update>
|
||||
<insert id="insertBatch">
|
||||
insert into patient_pre_hospitalization(id,patient_id,patient_name,
|
||||
insert into patient_pre_hospitalization(id,resident_id,patient_id,patient_name,
|
||||
patient_phone,card_no,sex,
|
||||
birth_date,family_member_phone,address,
|
||||
main_diagnosis,hospital_agency_id,hospital_agency_name,
|
||||
@ -361,7 +366,7 @@
|
||||
update_time)
|
||||
values
|
||||
<foreach collection="recordList" item="item" separator=",">
|
||||
(#{item.id,jdbcType=NUMERIC},#{item.patientId,jdbcType=NUMERIC},#{item.patientName,jdbcType=VARCHAR},
|
||||
(#{item.id,jdbcType=NUMERIC},#{item.residentId,jdbcType=NUMERIC},#{item.patientId,jdbcType=NUMERIC},#{item.patientName,jdbcType=VARCHAR},
|
||||
#{item.patientPhone,jdbcType=VARCHAR},#{item.cardNo,jdbcType=VARCHAR},#{item.sex,jdbcType=VARCHAR},
|
||||
#{item.birthDate,jdbcType=TIMESTAMP},#{item.familyMemberPhone,jdbcType=VARCHAR},#{item.address,jdbcType=VARCHAR},
|
||||
#{item.mainDiagnosis,jdbcType=VARCHAR},#{item.hospitalAgencyId,jdbcType=NUMERIC},#{item.hospitalAgencyName,jdbcType=VARCHAR},
|
||||
|
||||
@ -6,6 +6,7 @@
|
||||
|
||||
<resultMap type="com.xinelu.manage.domain.patientvisitrecord.PatientVisitRecord" id="PatientVisitRecordResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="residentId" column="resident_id"/>
|
||||
<result property="patientId" column="patient_id"/>
|
||||
<result property="cardNo" column="card_no"/>
|
||||
<result property="patientName" column="patient_name"/>
|
||||
@ -43,6 +44,8 @@
|
||||
<result property="inHospitalNumber" column="in_hospital_number"/>
|
||||
<result property="responsibleNurse" column="responsible_nurse"/>
|
||||
<result property="surgicalName" column="surgical_name"/>
|
||||
<result property="surgicalRecord" column="surgical_record"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
@ -50,12 +53,21 @@
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectPatientVisitRecordVo">
|
||||
select id, patient_id, card_no, patient_name, patient_phone, family_member_phone, address, sex, birth_date, age, nation, visit_method, visit_date, visit_name, hospital_agency_id, hospital_agency_name, campus_agency_id, campus_agency_name, department_id, department_name, ward_id, ward_name, attending_physician_id, attending_physician_name, main_diagnosis, marriage, medical_history_narrator, admission_time, discharge_time, record_time, outpatient_visit_info, hospitalization_days, in_hospital_info, out_hospital_info, visit_serial_number, in_hospital_number, responsible_nurse, surgical_name, create_by, create_time, update_by, update_time from patient_visit_record
|
||||
select id, resident_id, patient_id, card_no, patient_name, patient_phone, family_member_phone, address, sex, birth_date, age, nation,
|
||||
visit_method, visit_date, visit_name, hospital_agency_id, hospital_agency_name, campus_agency_id, campus_agency_name,
|
||||
department_id, department_name, ward_id, ward_name, attending_physician_id, attending_physician_name, main_diagnosis,
|
||||
marriage, medical_history_narrator, admission_time, discharge_time, record_time, outpatient_visit_info, hospitalization_days,
|
||||
in_hospital_info, out_hospital_info, visit_serial_number, in_hospital_number, responsible_nurse, surgical_name, surgical_record,del_flag,
|
||||
create_by, create_time, update_by, update_time from patient_visit_record
|
||||
</sql>
|
||||
|
||||
<select id="selectPatientVisitRecordList" parameterType="com.xinelu.manage.dto.patientvisitrecord.PatientVisitRecordDto" resultMap="PatientVisitRecordResult">
|
||||
<include refid="selectPatientVisitRecordVo"/>
|
||||
<where>
|
||||
del_flag = 0
|
||||
<if test="residentId != null ">
|
||||
and resident_id = #{residentId}
|
||||
</if>
|
||||
<if test="patientId != null ">
|
||||
and patient_id = #{patientId}
|
||||
</if>
|
||||
@ -88,6 +100,8 @@
|
||||
keyProperty="id">
|
||||
insert into patient_visit_record
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="residentId != null">resident_id,
|
||||
</if>
|
||||
<if test="patientId != null">patient_id,
|
||||
</if>
|
||||
<if test="cardNo != null">card_no,
|
||||
@ -162,6 +176,10 @@
|
||||
</if>
|
||||
<if test="surgicalName != null">surgical_name,
|
||||
</if>
|
||||
<if test="surgicalRecord != null">surgical_record,
|
||||
</if>
|
||||
<if test="delFlag != null">del_flag,
|
||||
</if>
|
||||
<if test="createBy != null">create_by,
|
||||
</if>
|
||||
<if test="createTime != null">create_time,
|
||||
@ -172,6 +190,8 @@
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="residentId != null">#{residentId},
|
||||
</if>
|
||||
<if test="patientId != null">#{patientId},
|
||||
</if>
|
||||
<if test="cardNo != null">#{cardNo},
|
||||
@ -246,6 +266,10 @@
|
||||
</if>
|
||||
<if test="surgicalName != null">#{surgicalName},
|
||||
</if>
|
||||
<if test="surgicalRecord != null">#{surgicalRecord},
|
||||
</if>
|
||||
<if test="delFlag != null">#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
@ -260,6 +284,9 @@
|
||||
<update id="updatePatientVisitRecord" parameterType="PatientVisitRecord">
|
||||
update patient_visit_record
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="residentId != null">resident_id =
|
||||
#{residentId},
|
||||
</if>
|
||||
<if test="patientId != null">patient_id =
|
||||
#{patientId},
|
||||
</if>
|
||||
@ -371,6 +398,12 @@
|
||||
<if test="surgicalName != null">surgical_name =
|
||||
#{surgicalName},
|
||||
</if>
|
||||
<if test="surgicalRecord != null">surgical_record =
|
||||
#{surgicalRecord},
|
||||
</if>
|
||||
<if test="delFlag != null">del_flag =
|
||||
#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
@ -386,18 +419,18 @@
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
<delete id="deletePatientVisitRecordById" parameterType="Long">
|
||||
delete from patient_visit_record where id = #{id}
|
||||
</delete>
|
||||
<update id="deletePatientVisitRecordById" parameterType="Long">
|
||||
update patient_visit_record set del_flag = 1 where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deletePatientVisitRecordByIds" parameterType="String">
|
||||
delete from patient_visit_record where id in
|
||||
<update id="deletePatientVisitRecordByIds" parameterType="String">
|
||||
update patient_visit_record set del_flag = 1 where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</update>
|
||||
<insert id="insertBatch">
|
||||
insert into patient_visit_record(patient_id,card_no,
|
||||
insert into patient_visit_record(resident_id,patient_id,card_no,
|
||||
patient_name,patient_phone,family_member_phone,
|
||||
address,sex,birth_date,
|
||||
age,nation,visit_method,
|
||||
@ -409,12 +442,11 @@
|
||||
admission_time,discharge_time,record_time,
|
||||
outpatient_visit_info,hospitalization_days,in_hospital_info,
|
||||
out_hospital_info,visit_serial_number,in_hospital_number,
|
||||
responsible_nurse,surgical_name,
|
||||
create_by,create_time,update_by,
|
||||
update_time,remark)
|
||||
responsible_nurse,surgical_name,surgical_record,del_flag,
|
||||
create_by,create_time,update_by,update_time)
|
||||
values
|
||||
<foreach collection="patientVisitRecordCollection" item="item" separator=",">
|
||||
(#{item.patientId,jdbcType=NUMERIC},#{item.cardNo,jdbcType=VARCHAR},
|
||||
(#{item.residentId,jdbcType=BIGINT},#{item.patientId,jdbcType=BIGINT},#{item.cardNo,jdbcType=VARCHAR},
|
||||
#{item.patientName,jdbcType=VARCHAR},#{item.patientPhone,jdbcType=VARCHAR},#{item.familyMemberPhone,jdbcType=VARCHAR},
|
||||
#{item.address,jdbcType=VARCHAR},#{item.sex,jdbcType=VARCHAR},#{item.birthDate,jdbcType=TIMESTAMP},
|
||||
#{item.age,jdbcType=NUMERIC},#{item.nation,jdbcType=VARCHAR},#{item.visitMethod,jdbcType=VARCHAR},
|
||||
@ -426,16 +458,26 @@
|
||||
#{item.admissionTime,jdbcType=TIMESTAMP},#{item.dischargeTime,jdbcType=TIMESTAMP},#{item.recordTime,jdbcType=TIMESTAMP},
|
||||
#{item.outpatientVisitInfo,jdbcType=VARCHAR},#{item.hospitalizationDays,jdbcType=NUMERIC},#{item.inHospitalInfo,jdbcType=VARCHAR},
|
||||
#{item.outHospitalInfo,jdbcType=VARCHAR},#{item.visitSerialNumber,jdbcType=VARCHAR},#{item.inHospitalNumber,jdbcType=VARCHAR},
|
||||
#{item.responsibleNurse,jdbcType=VARCHAR},#{item.surgicalName,jdbcType=VARCHAR},
|
||||
#{item.responsibleNurse,jdbcType=VARCHAR},#{item.surgicalName,jdbcType=VARCHAR},#{item.surgicalRecord,jdbcType=VARCHAR},#{item.delFlag,jdbcType=TINYINT},
|
||||
#{item.createBy,jdbcType=VARCHAR},#{item.createTime,jdbcType=TIMESTAMP},#{item.updateBy,jdbcType=VARCHAR},
|
||||
#{item.updateTime,jdbcType=TIMESTAMP},#{item.remark,jdbcType=VARCHAR})
|
||||
#{item.updateTime,jdbcType=TIMESTAMP})
|
||||
</foreach>
|
||||
</insert>
|
||||
<select id="judgeRepeat" resultMap="PatientVisitRecordResult">>
|
||||
<select id="judgeRepeat" resultMap="PatientVisitRecordResult">
|
||||
<include refid="selectPatientVisitRecordVo"/>
|
||||
where
|
||||
hospital_agency_id = #{hospitalAgencyId,jdbcType=NUMERIC}
|
||||
AND card_no != #{cardNo,jdbcType=VARCHAR}
|
||||
AND in_hospital_number = #{inHospitalNumber,jdbcType=VARCHAR}
|
||||
where del_flag = 0
|
||||
and hospital_agency_id = #{hospitalAgencyId,jdbcType=BIGINT}
|
||||
and in_hospital_number = #{inHospitalNumber,jdbcType=VARCHAR}
|
||||
<if test="cardNo != null">
|
||||
and card_no != #{cardNo,jdbcType=VARCHAR}
|
||||
</if>
|
||||
</select>
|
||||
|
||||
<select id="getLastRecord" resultMap="PatientVisitRecordResult">
|
||||
<include refid="selectPatientVisitRecordVo"/>
|
||||
where del_flag = 0
|
||||
AND hospital_agency_id = #{hospitalAgencyId,jdbcType=BIGINT}
|
||||
AND patient_id = #{patientId,jdbcType=BIGINT}
|
||||
ORDER BY id desc
|
||||
</select>
|
||||
</mapper>
|
||||
@ -4,37 +4,69 @@
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.xinelu.manage.mapper.propagandainfo.PropagandaInfoMapper">
|
||||
|
||||
<resultMap type="PropagandaInfo" id="PropagandaInfoResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="hospitalAgencyId" column="hospital_agency_id"/>
|
||||
<result property="hospitalAgencyName" column="hospital_agency_name"/>
|
||||
<result property="departmentId" column="department_id"/>
|
||||
<result property="departmentName" column="department_name"/>
|
||||
<result property="propagandaTitle" column="propaganda_title"/>
|
||||
<result property="propagandaType" column="propaganda_type"/>
|
||||
<result property="propagandaCode" column="propaganda_code"/>
|
||||
<result property="propagandaStatus" column="propaganda_status"/>
|
||||
<result property="propagandaContent" column="propaganda_content"/>
|
||||
<result property="propagandaCoverPath" column="propaganda_cover_path"/>
|
||||
<result property="articleSummary" column="article_summary"/>
|
||||
<result property="voicebroadcast" column="voicebroadcast"/>
|
||||
<result property="diseaseTypeId" column="disease_type_id"/>
|
||||
<result property="diseaseTypeName" column="disease_type_name"/>
|
||||
<result property="propagandaLink" column="propaganda_link"/>
|
||||
<result property="propagandaBarcodePath" column="propaganda_barcode_path"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<resultMap type="com.xinelu.manage.domain.propagandainfo.PropagandaInfo" id="PropagandaInfoResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="hospitalAgencyId" column="hospital_agency_id"/>
|
||||
<result property="hospitalAgencyName" column="hospital_agency_name"/>
|
||||
<result property="departmentId" column="department_id"/>
|
||||
<result property="departmentName" column="department_name"/>
|
||||
<result property="propagandaTitle" column="propaganda_title"/>
|
||||
<result property="propagandaType" column="propaganda_type"/>
|
||||
<result property="propagandaCode" column="propaganda_code"/>
|
||||
<result property="propagandaStatus" column="propaganda_status"/>
|
||||
<result property="propagandaContent" column="propaganda_content"/>
|
||||
<result property="propagandaCoverPath" column="propaganda_cover_path"/>
|
||||
<result property="articleSummary" column="article_summary"/>
|
||||
<result property="voicebroadcast" column="voicebroadcast"/>
|
||||
<result property="diseaseTypeId" column="disease_type_id"/>
|
||||
<result property="diseaseTypeName" column="disease_type_name"/>
|
||||
<result property="propagandaLink" column="propaganda_link"/>
|
||||
<result property="propagandaBarcodePath" column="propaganda_barcode_path"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
</resultMap>
|
||||
|
||||
<resultMap type="com.xinelu.manage.vo.propagandainfo.PropagandaMaterialsVo" id="PropagandaMaterialsResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="hospitalAgencyId" column="hospital_agency_id"/>
|
||||
<result property="hospitalAgencyName" column="hospital_agency_name"/>
|
||||
<result property="departmentId" column="department_id"/>
|
||||
<result property="departmentName" column="department_name"/>
|
||||
<result property="propagandaTitle" column="propaganda_title"/>
|
||||
<result property="propagandaType" column="propaganda_type"/>
|
||||
<result property="propagandaCode" column="propaganda_code"/>
|
||||
<result property="propagandaStatus" column="propaganda_status"/>
|
||||
<result property="propagandaContent" column="propaganda_content"/>
|
||||
<result property="propagandaCoverPath" column="propaganda_cover_path"/>
|
||||
<result property="articleSummary" column="article_summary"/>
|
||||
<result property="voicebroadcast" column="voicebroadcast"/>
|
||||
<result property="diseaseTypeId" column="disease_type_id"/>
|
||||
<result property="diseaseTypeName" column="disease_type_name"/>
|
||||
<result property="propagandaLink" column="propaganda_link"/>
|
||||
<result property="propagandaBarcodePath" column="propaganda_barcode_path"/>
|
||||
<collection property="materialsInfoList" javaType="java.util.List" resultMap="materialsResult"/>
|
||||
</resultMap>
|
||||
<resultMap id="materialsResult" type="com.xinelu.manage.domain.materialsinfo.MaterialsInfo">
|
||||
<result property="id" column="id"/>
|
||||
<result property="materialsName" column="materials_name"/>
|
||||
<result property="materialsType" column="materials_type"/>
|
||||
<result property="materialsOption" column="materials_option"/>
|
||||
<result property="materialsFilePath" column="materials_file_path"/>
|
||||
<result property="videoCoverType" column="video_cover_type"/>
|
||||
<result property="videoCoverFilePath" column="video_cover_file_path"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectPropagandaInfoVo">
|
||||
select id, hospital_agency_id, hospital_agency_name, department_id, department_name, propaganda_title, propaganda_type, propaganda_code, propaganda_status, propaganda_content, propaganda_cover_path, article_summary, voicebroadcast, disease_type_id, disease_type_name, propaganda_link, propaganda_barcode_path, create_by, create_time, update_by, update_time from propaganda_info
|
||||
select id, hospital_agency_id, hospital_agency_name, department_id, department_name, propaganda_title, propaganda_type, propaganda_code, propaganda_status, propaganda_content, propaganda_cover_path, article_summary, voicebroadcast, disease_type_id, disease_type_name, propaganda_link, propaganda_barcode_path,del_flag, create_by, create_time, update_by, update_time from propaganda_info
|
||||
</sql>
|
||||
|
||||
<select id="selectPropagandaInfoList" parameterType="com.xinelu.manage.dto.propagandainfo.PropagandaInfoDto" resultMap="PropagandaInfoResult">
|
||||
<include refid="selectPropagandaInfoVo"/>
|
||||
<where>
|
||||
del_flag = 0
|
||||
<if test="hospitalAgencyId != null ">
|
||||
and hospital_agency_id = #{hospitalAgencyId}
|
||||
</if>
|
||||
@ -71,96 +103,112 @@
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertPropagandaInfo" parameterType="PropagandaInfo" useGeneratedKeys="true"
|
||||
<select id="selectPropagandaInfo" parameterType="Long" resultMap="PropagandaMaterialsResult">
|
||||
select p.id, p.hospital_agency_id, p.hospital_agency_name, p.department_id, p.department_name, p.propaganda_title,
|
||||
p.propaganda_type, p.propaganda_code, p.propaganda_status, p.propaganda_content, p.propaganda_cover_path,
|
||||
p.article_summary, voicebroadcast, disease_type_id, disease_type_name, propaganda_link,
|
||||
p.propaganda_barcode_path, pm.materials_id,
|
||||
m.id, m.materials_name, m.materials_type, m.materials_option, m.materials_file_path, m.video_cover_type,
|
||||
m.video_cover_file_path from propaganda_materials pm
|
||||
left join propaganda_info p on pm.propaganda_id = p.id
|
||||
left join materials_info m on m.id = pm.materials_id
|
||||
where p.id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertPropagandaInfo" parameterType="com.xinelu.manage.domain.propagandainfo.PropagandaInfo" useGeneratedKeys="true"
|
||||
keyProperty="id">
|
||||
insert into propaganda_info
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="hospitalAgencyId != null">hospital_agency_id,
|
||||
</if>
|
||||
<if test="hospitalAgencyName != null">hospital_agency_name,
|
||||
</if>
|
||||
<if test="departmentId != null">department_id,
|
||||
</if>
|
||||
<if test="departmentName != null">department_name,
|
||||
</if>
|
||||
<if test="propagandaTitle != null">propaganda_title,
|
||||
</if>
|
||||
<if test="propagandaType != null">propaganda_type,
|
||||
</if>
|
||||
<if test="propagandaCode != null">propaganda_code,
|
||||
</if>
|
||||
<if test="propagandaStatus != null">propaganda_status,
|
||||
</if>
|
||||
<if test="propagandaContent != null">propaganda_content,
|
||||
</if>
|
||||
<if test="propagandaCoverPath != null">propaganda_cover_path,
|
||||
</if>
|
||||
<if test="articleSummary != null">article_summary,
|
||||
</if>
|
||||
<if test="voicebroadcast != null">voicebroadcast,
|
||||
</if>
|
||||
<if test="diseaseTypeId != null">disease_type_id,
|
||||
</if>
|
||||
<if test="diseaseTypeName != null">disease_type_name,
|
||||
</if>
|
||||
<if test="propagandaLink != null">propaganda_link,
|
||||
</if>
|
||||
<if test="propagandaBarcodePath != null">propaganda_barcode_path,
|
||||
</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="hospitalAgencyId != null">hospital_agency_id,
|
||||
</if>
|
||||
<if test="hospitalAgencyName != null">hospital_agency_name,
|
||||
</if>
|
||||
<if test="departmentId != null">department_id,
|
||||
</if>
|
||||
<if test="departmentName != null">department_name,
|
||||
</if>
|
||||
<if test="propagandaTitle != null">propaganda_title,
|
||||
</if>
|
||||
<if test="propagandaType != null">propaganda_type,
|
||||
</if>
|
||||
<if test="propagandaCode != null">propaganda_code,
|
||||
</if>
|
||||
<if test="propagandaStatus != null">propaganda_status,
|
||||
</if>
|
||||
<if test="propagandaContent != null">propaganda_content,
|
||||
</if>
|
||||
<if test="propagandaCoverPath != null">propaganda_cover_path,
|
||||
</if>
|
||||
<if test="articleSummary != null">article_summary,
|
||||
</if>
|
||||
<if test="voicebroadcast != null">voicebroadcast,
|
||||
</if>
|
||||
<if test="diseaseTypeId != null">disease_type_id,
|
||||
</if>
|
||||
<if test="diseaseTypeName != null">disease_type_name,
|
||||
</if>
|
||||
<if test="propagandaLink != null">propaganda_link,
|
||||
</if>
|
||||
<if test="propagandaBarcodePath != null">propaganda_barcode_path,
|
||||
</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>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="hospitalAgencyId != null">#{hospitalAgencyId},
|
||||
</if>
|
||||
<if test="hospitalAgencyName != null">#{hospitalAgencyName},
|
||||
</if>
|
||||
<if test="departmentId != null">#{departmentId},
|
||||
</if>
|
||||
<if test="departmentName != null">#{departmentName},
|
||||
</if>
|
||||
<if test="propagandaTitle != null">#{propagandaTitle},
|
||||
</if>
|
||||
<if test="propagandaType != null">#{propagandaType},
|
||||
</if>
|
||||
<if test="propagandaCode != null">#{propagandaCode},
|
||||
</if>
|
||||
<if test="propagandaStatus != null">#{propagandaStatus},
|
||||
</if>
|
||||
<if test="propagandaContent != null">#{propagandaContent},
|
||||
</if>
|
||||
<if test="propagandaCoverPath != null">#{propagandaCoverPath},
|
||||
</if>
|
||||
<if test="articleSummary != null">#{articleSummary},
|
||||
</if>
|
||||
<if test="voicebroadcast != null">#{voicebroadcast},
|
||||
</if>
|
||||
<if test="diseaseTypeId != null">#{diseaseTypeId},
|
||||
</if>
|
||||
<if test="diseaseTypeName != null">#{diseaseTypeName},
|
||||
</if>
|
||||
<if test="propagandaLink != null">#{propagandaLink},
|
||||
</if>
|
||||
<if test="propagandaBarcodePath != null">#{propagandaBarcodePath},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
<if test="hospitalAgencyId != null">#{hospitalAgencyId},
|
||||
</if>
|
||||
<if test="hospitalAgencyName != null">#{hospitalAgencyName},
|
||||
</if>
|
||||
<if test="departmentId != null">#{departmentId},
|
||||
</if>
|
||||
<if test="departmentName != null">#{departmentName},
|
||||
</if>
|
||||
<if test="propagandaTitle != null">#{propagandaTitle},
|
||||
</if>
|
||||
<if test="propagandaType != null">#{propagandaType},
|
||||
</if>
|
||||
<if test="propagandaCode != null">#{propagandaCode},
|
||||
</if>
|
||||
<if test="propagandaStatus != null">#{propagandaStatus},
|
||||
</if>
|
||||
<if test="propagandaContent != null">#{propagandaContent},
|
||||
</if>
|
||||
<if test="propagandaCoverPath != null">#{propagandaCoverPath},
|
||||
</if>
|
||||
<if test="articleSummary != null">#{articleSummary},
|
||||
</if>
|
||||
<if test="voicebroadcast != null">#{voicebroadcast},
|
||||
</if>
|
||||
<if test="diseaseTypeId != null">#{diseaseTypeId},
|
||||
</if>
|
||||
<if test="diseaseTypeName != null">#{diseaseTypeName},
|
||||
</if>
|
||||
<if test="propagandaLink != null">#{propagandaLink},
|
||||
</if>
|
||||
<if test="propagandaBarcodePath != null">#{propagandaBarcodePath},
|
||||
</if>
|
||||
<if test="delFlag != null">#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updatePropagandaInfo" parameterType="PropagandaInfo">
|
||||
<update id="updatePropagandaInfo" parameterType="com.xinelu.manage.domain.propagandainfo.PropagandaInfo">
|
||||
update propaganda_info
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="hospitalAgencyId != null">hospital_agency_id =
|
||||
@ -211,6 +259,9 @@
|
||||
<if test="propagandaBarcodePath != null">propaganda_barcode_path =
|
||||
#{propagandaBarcodePath},
|
||||
</if>
|
||||
<if test="delFlag != null">del_flag =
|
||||
#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
@ -227,22 +278,23 @@
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deletePropagandaInfoById" parameterType="Long">
|
||||
delete from propaganda_info where id = #{id}
|
||||
</delete>
|
||||
<update id="deletePropagandaInfoById" parameterType="Long">
|
||||
update propaganda_info set del_flag = 1 where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deletePropagandaInfoByIds" parameterType="String">
|
||||
delete from propaganda_info where id in
|
||||
<update id="deletePropagandaInfoByIds" parameterType="String">
|
||||
update propaganda_info set del_flag = 1 where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</update>
|
||||
<select id="selectNumByDept" resultType="com.xinelu.manage.vo.department.DepartmentVO">
|
||||
select d.id,
|
||||
d.department_name,
|
||||
count(p.id) AS countNum
|
||||
from department d left join propaganda_info p on d.id = p.department_id
|
||||
<where>
|
||||
p.del_flag = 0
|
||||
<if test="departmentName != null and departmentName != ''">
|
||||
and d.department_name like concat('%', #{departmentName}, '%')
|
||||
</if>
|
||||
|
||||
@ -4,37 +4,39 @@
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.xinelu.manage.mapper.propagandamaterials.PropagandaMaterialsMapper">
|
||||
|
||||
<resultMap type="PropagandaMaterials" id="PropagandaMaterialsResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="propagandaId" column="propaganda_id"/>
|
||||
<result property="propagandaTitle" column="propaganda_title"/>
|
||||
<result property="materialsId" column="materials_id"/>
|
||||
<result property="materialsName" column="materials_name"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<resultMap type="com.xinelu.manage.domain.propagandamaterials.PropagandaMaterials" id="PropagandaMaterialsResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="propagandaId" column="propaganda_id"/>
|
||||
<result property="propagandaTitle" column="propaganda_title"/>
|
||||
<result property="materialsId" column="materials_id"/>
|
||||
<result property="materialsName" column="materials_name"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectPropagandaMaterialsVo">
|
||||
select id, propaganda_id, propaganda_title, materials_id, materials_name, create_by, create_time, update_by, update_time from propaganda_materials
|
||||
select id, propaganda_id, propaganda_title, materials_id, materials_name, del_flag, create_by, create_time, update_by, update_time from propaganda_materials
|
||||
</sql>
|
||||
|
||||
<select id="selectPropagandaMaterialsList" parameterType="PropagandaMaterials" resultMap="PropagandaMaterialsResult">
|
||||
<select id="selectPropagandaMaterialsList" parameterType="com.xinelu.manage.domain.propagandamaterials.PropagandaMaterials" resultMap="PropagandaMaterialsResult">
|
||||
<include refid="selectPropagandaMaterialsVo"/>
|
||||
<where>
|
||||
<if test="propagandaId != null ">
|
||||
and propaganda_id = #{propagandaId}
|
||||
</if>
|
||||
<if test="propagandaTitle != null and propagandaTitle != ''">
|
||||
and propaganda_title = #{propagandaTitle}
|
||||
</if>
|
||||
<if test="materialsId != null ">
|
||||
and materials_id = #{materialsId}
|
||||
</if>
|
||||
<if test="materialsName != null and materialsName != ''">
|
||||
and materials_name like concat('%', #{materialsName}, '%')
|
||||
</if>
|
||||
del_flag = 0
|
||||
<if test="propagandaId != null ">
|
||||
and propaganda_id = #{propagandaId}
|
||||
</if>
|
||||
<if test="propagandaTitle != null and propagandaTitle != ''">
|
||||
and propaganda_title = #{propagandaTitle}
|
||||
</if>
|
||||
<if test="materialsId != null ">
|
||||
and materials_id = #{materialsId}
|
||||
</if>
|
||||
<if test="materialsName != null and materialsName != ''">
|
||||
and materials_name like concat('%', #{materialsName}, '%')
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
@ -44,86 +46,103 @@
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertPropagandaMaterials" parameterType="PropagandaMaterials" useGeneratedKeys="true"
|
||||
<insert id="insertPropagandaMaterials" parameterType="com.xinelu.manage.domain.propagandamaterials.PropagandaMaterials" useGeneratedKeys="true"
|
||||
keyProperty="id">
|
||||
insert into propaganda_materials
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="propagandaId != null">propaganda_id,
|
||||
</if>
|
||||
<if test="propagandaTitle != null">propaganda_title,
|
||||
</if>
|
||||
<if test="materialsId != null">materials_id,
|
||||
</if>
|
||||
<if test="materialsName != null">materials_name,
|
||||
</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="propagandaId != null">propaganda_id,
|
||||
</if>
|
||||
<if test="propagandaTitle != null">propaganda_title,
|
||||
</if>
|
||||
<if test="materialsId != null">materials_id,
|
||||
</if>
|
||||
<if test="materialsName != null">materials_name,
|
||||
</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>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="propagandaId != null">#{propagandaId},
|
||||
</if>
|
||||
<if test="propagandaTitle != null">#{propagandaTitle},
|
||||
</if>
|
||||
<if test="materialsId != null">#{materialsId},
|
||||
</if>
|
||||
<if test="materialsName != null">#{materialsName},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
<if test="propagandaId != null">#{propagandaId},
|
||||
</if>
|
||||
<if test="propagandaTitle != null">#{propagandaTitle},
|
||||
</if>
|
||||
<if test="materialsId != null">#{materialsId},
|
||||
</if>
|
||||
<if test="materialsName != null">#{materialsName},
|
||||
</if>
|
||||
<if test="delFlag != null">#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updatePropagandaMaterials" parameterType="PropagandaMaterials">
|
||||
<update id="updatePropagandaMaterials" parameterType="com.xinelu.manage.domain.propagandamaterials.PropagandaMaterials">
|
||||
update propaganda_materials
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="propagandaId != null">propaganda_id =
|
||||
#{propagandaId},
|
||||
</if>
|
||||
<if test="propagandaTitle != null">propaganda_title =
|
||||
#{propagandaTitle},
|
||||
</if>
|
||||
<if test="materialsId != null">materials_id =
|
||||
#{materialsId},
|
||||
</if>
|
||||
<if test="materialsName != null">materials_name =
|
||||
#{materialsName},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">create_time =
|
||||
#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">update_by =
|
||||
#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">update_time =
|
||||
#{updateTime},
|
||||
</if>
|
||||
<if test="propagandaId != null">propaganda_id =
|
||||
#{propagandaId},
|
||||
</if>
|
||||
<if test="propagandaTitle != null">propaganda_title =
|
||||
#{propagandaTitle},
|
||||
</if>
|
||||
<if test="materialsId != null">materials_id =
|
||||
#{materialsId},
|
||||
</if>
|
||||
<if test="materialsName != null">materials_name =
|
||||
#{materialsName},
|
||||
</if>
|
||||
<if test="delFlag != null">del_flag =
|
||||
#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">create_time =
|
||||
#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">update_by =
|
||||
#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">update_time =
|
||||
#{updateTime},
|
||||
</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deletePropagandaMaterialsById" parameterType="Long">
|
||||
delete from propaganda_materials where id = #{id}
|
||||
</delete>
|
||||
<update id="deleteByPropagandaId" parameterType="Long">
|
||||
update propaganda_materials set del_flag = 1 where propaganda_id = #{propagandaId}
|
||||
</update>
|
||||
|
||||
<delete id="deletePropagandaMaterialsByIds" parameterType="String">
|
||||
delete from propaganda_materials where id in
|
||||
<update id="deleteByPropagandaIds" parameterType="Long">
|
||||
update propaganda_materials set del_flag = 1 where propaganda_id in
|
||||
<foreach item="propagandaId" collection="array" open="(" separator="," close=")">
|
||||
#{propagandaId}
|
||||
</foreach>
|
||||
</update>
|
||||
|
||||
<update id="deletePropagandaMaterialsById" parameterType="Long">
|
||||
update propaganda_materials set del_flag = 1 where id = #{id}
|
||||
</update>
|
||||
<update id="deletePropagandaMaterialsByIds" parameterType="String">
|
||||
update propaganda_materials set del_flag = 1 where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</update>
|
||||
</mapper>
|
||||
@ -0,0 +1,186 @@
|
||||
<?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.xinelu.manage.mapper.residentinfo.ResidentInfoMapper">
|
||||
|
||||
<resultMap type="com.xinelu.manage.domain.residentinfo.ResidentInfo" id="ResidentInfoResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="patientName" column="patient_name"/>
|
||||
<result property="patientPhone" column="patient_phone"/>
|
||||
<result property="familyMemberPhone" column="family_member_phone"/>
|
||||
<result property="birthDate" column="birth_date"/>
|
||||
<result property="cardNo" column="card_no"/>
|
||||
<result property="sex" column="sex"/>
|
||||
<result property="address" column="address"/>
|
||||
<result property="openId" column="open_id"/>
|
||||
<result property="unionId" column="union_id"/>
|
||||
<result property="officialAccountOpenid" column="official_account_openid"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectResidentInfoVo">
|
||||
select id, patient_name, patient_phone, family_member_phone, birth_date, card_no, sex, address, open_id, union_id, official_account_openid, create_by, create_time, update_by, update_time from resident_info
|
||||
</sql>
|
||||
|
||||
<select id="selectResidentInfoList" parameterType="com.xinelu.manage.domain.residentinfo.ResidentInfo" resultMap="ResidentInfoResult">
|
||||
<include refid="selectResidentInfoVo" />
|
||||
<where>
|
||||
<if test="patientName != null and patientName != ''">
|
||||
and patient_name like concat('%', #{patientName}, '%')
|
||||
</if>
|
||||
<if test="patientPhone != null and patientPhone != ''">
|
||||
and patient_phone = #{patientPhone}
|
||||
</if>
|
||||
<if test="birthDate != null ">
|
||||
and birth_date = #{birthDate}
|
||||
</if>
|
||||
<if test="cardNo != null and cardNo != ''">
|
||||
and card_no = #{cardNo}
|
||||
</if>
|
||||
<if test="openId != null and openId != ''">
|
||||
and open_id = #{openId}
|
||||
</if>
|
||||
<if test="unionId != null and unionId != ''">
|
||||
and union_id = #{unionId}
|
||||
</if>
|
||||
<if test="officialAccountOpenid != null and officialAccountOpenid != ''">
|
||||
and official_account_openid = #{officialAccountOpenid}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectResidentInfoById" parameterType="Long"
|
||||
resultMap="ResidentInfoResult">
|
||||
<include refid="selectResidentInfoVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertResidentInfo" parameterType="com.xinelu.manage.domain.residentinfo.ResidentInfo" useGeneratedKeys="true"
|
||||
keyProperty="id">
|
||||
insert into resident_info
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="patientName != null">patient_name,
|
||||
</if>
|
||||
<if test="patientPhone != null">patient_phone,
|
||||
</if>
|
||||
<if test="familyMemberPhone != null">family_member_phone,
|
||||
</if>
|
||||
<if test="birthDate != null">birth_date,
|
||||
</if>
|
||||
<if test="cardNo != null">card_no,
|
||||
</if>
|
||||
<if test="sex != null">sex,
|
||||
</if>
|
||||
<if test="address != null">address,
|
||||
</if>
|
||||
<if test="openId != null">open_id,
|
||||
</if>
|
||||
<if test="unionId != null">union_id,
|
||||
</if>
|
||||
<if test="officialAccountOpenid != null">official_account_openid,
|
||||
</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>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="patientName != null">#{patientName},
|
||||
</if>
|
||||
<if test="patientPhone != null">#{patientPhone},
|
||||
</if>
|
||||
<if test="familyMemberPhone != null">#{familyMemberPhone},
|
||||
</if>
|
||||
<if test="birthDate != null">#{birthDate},
|
||||
</if>
|
||||
<if test="cardNo != null">#{cardNo},
|
||||
</if>
|
||||
<if test="sex != null">#{sex},
|
||||
</if>
|
||||
<if test="address != null">#{address},
|
||||
</if>
|
||||
<if test="openId != null">#{openId},
|
||||
</if>
|
||||
<if test="unionId != null">#{unionId},
|
||||
</if>
|
||||
<if test="officialAccountOpenid != null">#{officialAccountOpenid},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateResidentInfo" parameterType="com.xinelu.manage.domain.residentinfo.ResidentInfo">
|
||||
update resident_info
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="patientName != null">patient_name =
|
||||
#{patientName},
|
||||
</if>
|
||||
<if test="patientPhone != null">patient_phone =
|
||||
#{patientPhone},
|
||||
</if>
|
||||
<if test="familyMemberPhone != null">family_member_phone =
|
||||
#{familyMemberPhone},
|
||||
</if>
|
||||
<if test="birthDate != null">birth_date =
|
||||
#{birthDate},
|
||||
</if>
|
||||
<if test="cardNo != null">card_no =
|
||||
#{cardNo},
|
||||
</if>
|
||||
<if test="sex != null">sex =
|
||||
#{sex},
|
||||
</if>
|
||||
<if test="address != null">address =
|
||||
#{address},
|
||||
</if>
|
||||
<if test="openId != null">open_id =
|
||||
#{openId},
|
||||
</if>
|
||||
<if test="unionId != null">union_id =
|
||||
#{unionId},
|
||||
</if>
|
||||
<if test="officialAccountOpenid != null">official_account_openid =
|
||||
#{officialAccountOpenid},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">create_time =
|
||||
#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">update_by =
|
||||
#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">update_time =
|
||||
#{updateTime},
|
||||
</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteResidentInfoById" parameterType="Long">
|
||||
delete from resident_info where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteResidentInfoByIds" parameterType="String">
|
||||
delete from resident_info where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@ -170,4 +170,19 @@
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
<insert id="insertBatch">
|
||||
insert into sign_route_trigger_condition(id,patient_manage_route_id,route_name,
|
||||
trigger_condition_code,trigger_condition_name,trigger_condition_operator,
|
||||
trigger_condition_value,trigger_condition_sort,trigger_condition_remark,
|
||||
search_value,create_by,create_time,
|
||||
update_by,update_time)
|
||||
values
|
||||
<foreach collection="signRouteTriggerConditionCollection" item="item" separator=",">
|
||||
(#{item.id,jdbcType=NUMERIC},#{item.patientManageRouteId,jdbcType=NUMERIC},#{item.routeName,jdbcType=VARCHAR},
|
||||
#{item.triggerConditionCode,jdbcType=VARCHAR},#{item.triggerConditionName,jdbcType=VARCHAR},#{item.triggerConditionOperator,jdbcType=VARCHAR},
|
||||
#{item.triggerConditionValue,jdbcType=VARCHAR},#{item.triggerConditionSort,jdbcType=NUMERIC},#{item.triggerConditionRemark,jdbcType=VARCHAR},
|
||||
#{item.searchValue,jdbcType=VARCHAR},#{item.createBy,jdbcType=VARCHAR},#{item.createTime},
|
||||
#{item.updateBy,jdbcType=VARCHAR},#{item.updateTime})
|
||||
</foreach>
|
||||
</insert>
|
||||
</mapper>
|
||||
Loading…
Reference in New Issue
Block a user