|
|
@@ -88,6 +88,9 @@ public class BusClinicController {
|
|
|
if(clinic==null){
|
|
|
throw new CustomException("该临床信息不存在");
|
|
|
}
|
|
|
+ if(Boolean.TRUE.equals(clinic.getMonitorType())){
|
|
|
+ clinic.setPatientCode(patientService.getById(clinic.getPatientId()).getCode());
|
|
|
+ }
|
|
|
ClinicAnalClinicRecord record = ClinicAnalClinicRecord.parse(clinic);
|
|
|
record.setTenantName(hospitalService.getName(tenantId));
|
|
|
//填充临床信息
|
|
|
@@ -199,22 +202,6 @@ public class BusClinicController {
|
|
|
return R.success(null);
|
|
|
}
|
|
|
|
|
|
- @Log(title = "查看术前访视单")
|
|
|
- @PostMapping("/look/visit/{clinicId}")
|
|
|
- @SaCheckPermission("bus:clinic:query")
|
|
|
- @ApiOperation(value = "查看术前访视单",notes = "查看术前访视单,权限【bus:clinic:query】")
|
|
|
- public R<VisitRecord> queryVisit(@PathVariable("clinicId") String clinicId){
|
|
|
- VisitRecord visitRecord = new VisitRecord();
|
|
|
- visitRecord.setClinicId(clinicId);
|
|
|
- visitRecord.setContent(
|
|
|
- Optional.ofNullable(clinicService.getOne(new QueryWrapper<BusClinicEntity>().lambda().select(BusClinicEntity::getVisitRecord).eq(BusClinicEntity::getId,clinicId)))
|
|
|
- .orElse(new BusClinicEntity())
|
|
|
- .getVisitRecord()
|
|
|
-
|
|
|
- );
|
|
|
- return R.success(visitRecord);
|
|
|
- }
|
|
|
-
|
|
|
|
|
|
@Log(title = "查询病人信息详情")
|
|
|
@PostMapping("/view/{id}")
|
|
|
@@ -228,7 +215,18 @@ public class BusClinicController {
|
|
|
if(StrUtil.isNullOrUndefined(key)){
|
|
|
return R.fail("查询结果不存在");
|
|
|
}
|
|
|
- return R.success(clinicService.getById(key));
|
|
|
+ BusClinicEntity clinic = clinicService.getById(key);
|
|
|
+ if(!Boolean.TRUE.equals(clinic.getMonitorType())){
|
|
|
+ return R.success(clinic);
|
|
|
+ }
|
|
|
+ BusPatientEntity patient = patientService.getById(clinic.getPatientId());
|
|
|
+ if(patient==null){
|
|
|
+ log.warn("输注监控中临床【{}】的病人信息为空",id);
|
|
|
+ return R.success(clinic);
|
|
|
+ }
|
|
|
+ //输注监控的临床使用 格式化后的住院号
|
|
|
+ clinic.setPatientCode(patient.getCode());
|
|
|
+ return R.success(clinic);
|
|
|
}
|
|
|
|
|
|
@PostMapping("/edit/any")
|