update===>:修改居民主键字段名称。

This commit is contained in:
haown 2023-09-22 15:36:49 +08:00
parent fedaf75aa3
commit e9e3397c51
10 changed files with 47 additions and 47 deletions

View File

@ -109,16 +109,16 @@ public class AppletScreeningRecordController extends BaseController {
return R.ok(screeningRecordVo); return R.ok(screeningRecordVo);
} }
@GetMapping("/getScreening/{registerId}") @GetMapping("/getScreening/{patientId}")
@ApiOperation(value = "获取当前预约信息") @ApiOperation(value = "获取当前预约信息")
public R<ScreeningRecordVo> getScreeningByRegisterId(@PathVariable String registerId) { public R<ScreeningRecordVo> getScreeningByPatientId(@PathVariable String patientId) {
return R.ok(screeningRecordService.getScreeningByRegisterId(registerId)); return R.ok(screeningRecordService.getScreeningByPatientId(patientId));
} }
@GetMapping("/last/{registerId}/{projectId}") @GetMapping("/last/{patientId}/{projectId}")
@ApiOperation(value = "获取最新一次筛查结果") @ApiOperation(value = "获取最新一次筛查结果")
public R<ScreeningRecordVo> last(@PathVariable String registerId, @PathVariable String projectId) { public R<ScreeningRecordVo> last(@PathVariable String patientId, @PathVariable String projectId) {
ScreeningRecordVo screeningRecordVo = screeningRecordService.last(registerId, projectId); ScreeningRecordVo screeningRecordVo = screeningRecordService.last(patientId, projectId);
return R.ok(screeningRecordVo); return R.ok(screeningRecordVo);
} }

View File

@ -59,23 +59,23 @@ public class ScreeningRecordController extends BaseController {
return R.ok(screeningRecordService.detail(screeningId)); return R.ok(screeningRecordService.detail(screeningId));
} }
@GetMapping("/getScreening/{registerId}") @GetMapping("/getScreening/{patientId}")
@ApiOperation(value = "获取当前预约信息") @ApiOperation(value = "获取当前预约信息")
public R<ScreeningRecordVo> getScreeningByRegisterId(@PathVariable String registerId) { public R<ScreeningRecordVo> getScreeningByPatientId(@PathVariable String patientId) {
return R.ok(screeningRecordService.getScreeningByRegisterId(registerId)); return R.ok(screeningRecordService.getScreeningByPatientId(patientId));
} }
@GetMapping("/last/{registerId}") @GetMapping("/last/{patientId}")
@ApiOperation(value = "获取最新一次筛查结果") @ApiOperation(value = "获取最新一次筛查结果")
public R<ScreeningRecordVo> last(@PathVariable String registerId) { public R<ScreeningRecordVo> last(@PathVariable String patientId) {
return R.ok(screeningRecordService.last(registerId,null)); return R.ok(screeningRecordService.last(patientId,null));
} }
@GetMapping("/timelineList/{registerId}") @GetMapping("/timelineList/{patientId}")
@ApiOperation(value = "根据居民业务主键查询筛查记录时间轴", response = TimelineVo.class, notes = "根据居民业务主键查询筛查记录时间轴", httpMethod = "GET") @ApiOperation(value = "根据居民业务主键查询筛查记录时间轴", response = TimelineVo.class, notes = "根据居民业务主键查询筛查记录时间轴", httpMethod = "GET")
@ApiImplicitParam(name = "registerId", value = "居民业务主键", required = true, dataTypeClass = String.class) @ApiImplicitParam(name = "patientId", value = "居民业务主键", required = true, dataTypeClass = String.class)
public R<List<SelectVo>> TimelineList(@PathVariable("registerId") String registerId) { public R<List<SelectVo>> TimelineList(@PathVariable("patientId") String patientId) {
return R.ok(screeningRecordService.getTimelineList(registerId)); return R.ok(screeningRecordService.getTimelineList(patientId));
} }
@GetMapping("/receive/{screeningId}") @GetMapping("/receive/{screeningId}")
@ -109,7 +109,7 @@ public class ScreeningRecordController extends BaseController {
@RepeatSubmit(interval = 2000, message = "请求过于频繁") @RepeatSubmit(interval = 2000, message = "请求过于频繁")
public R<String> pushScreening(@RequestBody ScreeningRecordSaveDTO body) { public R<String> pushScreening(@RequestBody ScreeningRecordSaveDTO body) {
try { try {
if (StringUtils.isBlank(body.getRegisterId())) { if (StringUtils.isBlank(body.getPatientId())) {
return R.fail("请选择居民!"); return R.fail("请选择居民!");
} }
if (CollectionUtils.isEmpty(body.getProjectList())) { if (CollectionUtils.isEmpty(body.getProjectList())) {

View File

@ -22,7 +22,7 @@ public class ScreeningApplyDTO implements Serializable {
* 居民业务主键 * 居民业务主键
*/ */
@ApiModelProperty(value = "居民业务主键") @ApiModelProperty(value = "居民业务主键")
private String registerId; private String patientId;
@ApiModelProperty(value = "居民身份证号") @ApiModelProperty(value = "居民身份证号")
private String identity; private String identity;

View File

@ -28,7 +28,7 @@ public class ScreeningRecordApplyDTO implements Serializable {
* 居民业务主键 * 居民业务主键
*/ */
@ApiModelProperty(value = "居民业务主键", required = true) @ApiModelProperty(value = "居民业务主键", required = true)
private String registerId; private String patientId;
/** /**
* 居民姓名 * 居民姓名

View File

@ -22,7 +22,7 @@ public class ScreeningRecordDTO extends BaseEntity {
* 居民业务主键 * 居民业务主键
*/ */
@ApiModelProperty(value = "居民业务主键") @ApiModelProperty(value = "居民业务主键")
private String registerId; private String patientId;
/** /**
* 居民姓名 * 居民姓名

View File

@ -16,7 +16,7 @@ import lombok.Data;
public class ScreeningRecordSaveDTO { public class ScreeningRecordSaveDTO {
@ApiModelProperty("居民业务主键") @ApiModelProperty("居民业务主键")
private String registerId; private String patientId;
@ApiModelProperty("筛查项目列表") @ApiModelProperty("筛查项目列表")
private List<ScreeningProject> projectList; private List<ScreeningProject> projectList;

View File

@ -57,10 +57,10 @@ public interface ScreeningRecordMapper {
* @Author mengkuiliang * @Author mengkuiliang
* @Description 获取当前居民预约信息 * @Description 获取当前居民预约信息
* @Date 2023-01-29 14:51 * @Date 2023-01-29 14:51
* @Param [registerId] * @Param [patientId]
* @return com.disease.business.domain.vo.ScreeningRecordVo * @return com.disease.business.domain.vo.ScreeningRecordVo
**/ **/
ScreeningRecordVo getScreeningByRegisterId(String registerId); ScreeningRecordVo getScreeningByPatientId(String patientId);
/** /**
* @Author mengkuiliang * @Author mengkuiliang
@ -84,14 +84,14 @@ public interface ScreeningRecordMapper {
* @Author mengkuiliang * @Author mengkuiliang
* @Description 获取最新一次筛查结果 * @Description 获取最新一次筛查结果
* @Date 2023-01-30 13:07 * @Date 2023-01-30 13:07
* @Param [registerId] * @Param [patientId]
* @return com.disease.business.domain.vo.ScreeningRecordVo * @return com.disease.business.domain.vo.ScreeningRecordVo
**/ **/
ScreeningRecordVo getScreeningOfLast(@Param("registerId") String registerId, @Param("screeningStatus")String screeningStatus, @Param("screeningType") String screeningType, @Param("projectId") String projectId); ScreeningRecordVo getScreeningOfLast(@Param("patientId") String patientId, @Param("screeningStatus")String screeningStatus, @Param("screeningType") String screeningType, @Param("projectId") String projectId);
ScreeningRecord selectByScreeningId(String screeningId); ScreeningRecord selectByScreeningId(String screeningId);
List<TimelineVo> selectTimeLineList(@Param("registerId") String registerId); List<TimelineVo> selectTimeLineList(@Param("patientId") String patientId);
List<ScreeningRecordVo> screeningList(ScreeningRecordDTO query); List<ScreeningRecordVo> screeningList(ScreeningRecordDTO query);
} }

View File

@ -98,25 +98,25 @@ public interface IScreeningRecordService {
* @Param * @Param
* @return * @return
**/ **/
ScreeningRecordVo getScreeningByRegisterId(String registerId); ScreeningRecordVo getScreeningByPatientId(String patientId);
/** /**
* @Author mengkuiliang * @Author mengkuiliang
* @Description 获取最新一次筛查结果 * @Description 获取最新一次筛查结果
* @Date 2023-01-30 11:45 * @Date 2023-01-30 11:45
* @Param [registerId] * @Param [patientId]
* @return void * @return void
**/ **/
ScreeningRecordVo last(String registerId,String projectId); ScreeningRecordVo last(String patientId,String projectId);
/** /**
* @Author haown * @Author haown
* @Description 获取居民筛查记录时间轴 * @Description 获取居民筛查记录时间轴
* @Date 2023-02-06 20:49 * @Date 2023-02-06 20:49
* @Param [registerId] * @Param [patientId]
* @return void * @return void
**/ **/
List<SelectVo> getTimelineList(String registerId); List<SelectVo> getTimelineList(String patientId);
Integer pushScreening(ScreeningRecordSaveDTO body) throws Exception; Integer pushScreening(ScreeningRecordSaveDTO body) throws Exception;

View File

@ -96,7 +96,7 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
} }
// 查询 同一机构的同一筛查项目在同一天是否有预约 // 查询 同一机构的同一筛查项目在同一天是否有预约
ScreeningRecordDTO query = new ScreeningRecordDTO(); ScreeningRecordDTO query = new ScreeningRecordDTO();
query.setRegisterId(body.getRegisterId()); query.setPatientId(body.getPatientId());
query.setDeptId(body.getDeptId()); query.setDeptId(body.getDeptId());
query.setProjectId(body.getProjectId()); query.setProjectId(body.getProjectId());
query.setApplyStartDate(body.getApplyStartTime()); query.setApplyStartDate(body.getApplyStartTime());
@ -131,7 +131,7 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
// .fluentPut("contentId", recordBody.getScreeningId()); // .fluentPut("contentId", recordBody.getScreeningId());
//FdmpPushMegUtil.sendPost(jsonObject); //FdmpPushMegUtil.sendPost(jsonObject);
} }
return body.getRegisterId(); return body.getPatientId();
} }
@Override @Override
@ -144,7 +144,7 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
int flag = screeningRecordMapper.update(body); int flag = screeningRecordMapper.update(body);
if (flag > 0) { if (flag > 0) {
// TODO 推送提醒 // TODO 推送提醒
//PatientInfoVO patientInfoVO = patientService.selectPatientInfoById(body.getRegisterId()); //PatientInfoVO patientInfoVO = patientService.selectPatientInfoById(body.getPatientId());
//JSONObject jsonObject = new JSONObject(); //JSONObject jsonObject = new JSONObject();
//jsonObject.fluentPut("senderNo", SecurityUtils.getUserId()) //jsonObject.fluentPut("senderNo", SecurityUtils.getUserId())
// .fluentPut("senderName", SecurityUtils.getLoginUser().getUser().getNickName()) // .fluentPut("senderName", SecurityUtils.getLoginUser().getUser().getNickName())
@ -241,8 +241,8 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
* @return com.disease.business.domain.vo.ScreeningRecordVo * @return com.disease.business.domain.vo.ScreeningRecordVo
**/ **/
@Override @Override
public ScreeningRecordVo getScreeningByRegisterId(String registerId) { public ScreeningRecordVo getScreeningByPatientId(String patientId) {
ScreeningRecordVo recordVo = screeningRecordMapper.getScreeningByRegisterId(registerId); ScreeningRecordVo recordVo = screeningRecordMapper.getScreeningByPatientId(patientId);
if(recordVo == null) { if(recordVo == null) {
return null; return null;
} }
@ -254,12 +254,12 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
* @Author mengkuiliang * @Author mengkuiliang
* @Description 获取最新一次筛查结果 * @Description 获取最新一次筛查结果
* @Date 2023-01-30 11:46 * @Date 2023-01-30 11:46
* @Param [registerId] * @Param [patientId]
* @return com.disease.business.domain.vo.ProjectRecordVo * @return com.disease.business.domain.vo.ProjectRecordVo
**/ **/
@Override @Override
public ScreeningRecordVo last(String registerId,String projectId) { public ScreeningRecordVo last(String patientId,String projectId) {
ScreeningRecordVo recordVo = screeningRecordMapper.getScreeningOfLast(registerId, null, "1",projectId); ScreeningRecordVo recordVo = screeningRecordMapper.getScreeningOfLast(patientId, null, "1",projectId);
if(recordVo == null) { if(recordVo == null) {
return null; return null;
} }
@ -275,8 +275,8 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
return recordVo; return recordVo;
} }
@Override public List<SelectVo> getTimelineList(String registerId) { @Override public List<SelectVo> getTimelineList(String patientId) {
List<TimelineVo> timelineVos = screeningRecordMapper.selectTimeLineList(registerId); List<TimelineVo> timelineVos = screeningRecordMapper.selectTimeLineList(patientId);
// 按照年份进行分组 // 按照年份进行分组
Map<String, List<TimelineVo>> groupByTime = timelineVos.stream().collect(Collectors.groupingBy(item-> DateUtils.formatDate(item.getCreateTime(), "yyyy"))); Map<String, List<TimelineVo>> groupByTime = timelineVos.stream().collect(Collectors.groupingBy(item-> DateUtils.formatDate(item.getCreateTime(), "yyyy")));
List<SelectVo> timeList = new ArrayList<>(); List<SelectVo> timeList = new ArrayList<>();
@ -304,7 +304,7 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
String assessRecordId = ""; String assessRecordId = "";
// 查询居民最新一次评估记录 // 查询居民最新一次评估记录
//List<RiskAssessRecord> riskAssessRecords = riskAssessRecordMapper.selectByPatientId(body.getRegisterId()); //List<RiskAssessRecord> riskAssessRecords = riskAssessRecordMapper.selectByPatientId(body.getPatientId());
//if (riskAssessRecords != null && riskAssessRecords.size() > 0) { //if (riskAssessRecords != null && riskAssessRecords.size() > 0) {
// RiskAssessRecord riskAssessRecord = riskAssessRecords.get(riskAssessRecords.size() - 1); // RiskAssessRecord riskAssessRecord = riskAssessRecords.get(riskAssessRecords.size() - 1);
// if (riskAssessRecord != null) { // if (riskAssessRecord != null) {
@ -319,7 +319,7 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
screeningRecord.setScreeningId(IdUtils.fastSimpleUUID()); screeningRecord.setScreeningId(IdUtils.fastSimpleUUID());
screeningRecord.setProjectId(project.getProjectId()); screeningRecord.setProjectId(project.getProjectId());
screeningRecord.setProjectName(project.getProjectName()); screeningRecord.setProjectName(project.getProjectName());
screeningRecord.setRegisterId(body.getRegisterId()); screeningRecord.setPatientId(body.getPatientId());
// TODO 用户id // TODO 用户id
//screeningRecord.setDoctorId(SecurityUtils.getUserId()); //screeningRecord.setDoctorId(SecurityUtils.getUserId());
screeningRecord.setDoctorName(SecurityUtils.getLoginUser().getUser().getNickName()); screeningRecord.setDoctorName(SecurityUtils.getLoginUser().getUser().getNickName());
@ -334,7 +334,7 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
if (flag > 0) { if (flag > 0) {
// TODO 推送消息通知 // TODO 推送消息通知
//JSONObject jsonObject = new JSONObject(); //JSONObject jsonObject = new JSONObject();
//RegisterVo register = registerService.getByRegisterId(body.getRegisterId()); //RegisterVo register = registerService.getByPatientId(body.getPatientId());
//jsonObject.fluentPut("senderNo", SecurityUtils.getUserId()) //jsonObject.fluentPut("senderNo", SecurityUtils.getUserId())
// .fluentPut("senderName", SecurityUtils.getLoginUser().getUser().getNickName()) // .fluentPut("senderName", SecurityUtils.getLoginUser().getUser().getNickName())
// .fluentPut("doctorName", SecurityUtils.getLoginUser().getUser().getNickName()) // .fluentPut("doctorName", SecurityUtils.getLoginUser().getUser().getNickName())
@ -362,7 +362,7 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
retObject.fluentPut("projectName", String.join("," , projectName)) retObject.fluentPut("projectName", String.join("," , projectName))
.fluentPut("doctorName", screeningRecordVoList.get(0).getDoctorName()); .fluentPut("doctorName", screeningRecordVoList.get(0).getDoctorName());
// TODO 居民信息 // TODO 居民信息
//PatientInfoVO patientInfoVO = patientService.selectPatientInfoById(screeningRecordVoList.get(0).getRegisterId()); //PatientInfoVO patientInfoVO = patientService.selectPatientInfoById(screeningRecordVoList.get(0).getPatientId());
//retObject.fluentPut("name", patientInfoVO.getPatientName()); //retObject.fluentPut("name", patientInfoVO.getPatientName());
} }

View File

@ -32,13 +32,13 @@ public class ScreeningRecordVo {
* 居民业务主键 * 居民业务主键
*/ */
@ApiModelProperty("居民业务主键") @ApiModelProperty("居民业务主键")
private String registerId; private String patientId;
/** /**
* 居民姓名 * 居民姓名
*/ */
@ApiModelProperty("居民姓名") @ApiModelProperty("居民姓名")
private String residentName; private String patientName;
/** /**
* 性别1 2 * 性别1 2