Merge remote-tracking branch 'origin/main'

This commit is contained in:
yy2205 2025-04-24 15:37:09 +08:00
commit bd4881839b
8 changed files with 69 additions and 4 deletions

View File

@ -1953,4 +1953,13 @@ public class InspectPatientController {
/*ExcelUtils.write(response, "统计.xls", "数据", InspectDoctorRespVO.class,
BeanUtils.toBean(list, InspectDoctorRespVO.class));*/
}
@PutMapping("/updateBarcodeTime")
@Operation(summary = "更新条码时间")
public CommonResult<Boolean> updateBarcodeTime(@RequestParam("medicalSn") String medicalSn,
@RequestParam(value = "barcodetime", required = false)
@DateTimeFormat(iso = DateTimeFormat.ISO.DATE_TIME) Date barcodetime) {
patientService.updateBarcodeTime(medicalSn, barcodetime);
return success(true);
}
}

View File

@ -140,4 +140,9 @@ public class InspectPatientPageReqVO extends PageParam {
@Schema(description = "报告地址")
private String pdfurl;
@Schema(description = "条形码打印时间")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss ", timezone = "GMT+8")
private LocalDateTime barcodetime;
}

View File

@ -150,4 +150,9 @@ public class InspectPatientRespVO {
@Schema(description = "总检医生")
private String chiefinspector;
@Schema(description = "条形码打印时间")
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss ", timezone = "GMT+8")
private LocalDateTime barcodetime;
}

View File

@ -117,6 +117,9 @@ public class InspectPatientSaveReqVO {
@Schema(description = "打印时间")
private LocalDateTime printtime;
@Schema(description = "条行码打印时间")
private LocalDateTime barcodetime;
@Schema(description = "总检医生id")
private String chiefinspectorid;

View File

@ -206,6 +206,12 @@ public class InspectPatientDO {
@TableField("printtime")
@JsonFormat(pattern = "yyyy-MM-dd yyyy-MM-dd HH:mm:ss")
private LocalDateTime printtime;
/**
* 条行码打印时间
*/
@TableField("barcodetime")
@JsonFormat(pattern = "yyyy-MM-dd yyyy-MM-dd HH:mm:ss")
private LocalDateTime barcodetime;
/**
* 报告地址

View File

@ -40,11 +40,11 @@ public interface InspectPatientMapper extends BaseMapperX<InspectPatientDO> {
.eqIfPresent(InspectPatientDO::getSummaryResult, reqVO.getSummaryResult())
.eqIfPresent(InspectPatientDO::getAuditor, reqVO.getAuditor())
.eqIfPresent(InspectPatientDO::getAuditStatus, reqVO.getAuditStatus())
//.eqIfPresent(InspectPatientDO::getInspectionOpinion, reqVO.getInspectionOpinion())
// .eqIfPresent(InspectPatientDO::getInspectionOpinion, reqVO.getInspectionOpinion())
.eqIfPresent(InspectPatientDO::getIsprint, reqVO.getIsprint())
// .betweenIfPresent(InspectPatientDO::getAuditorTime, reqVO.getAuditorTime())
.betweenIfPresent(InspectPatientDO::getPrinttime, reqVO.getPrintTimeRange())
.orderByDesc(InspectPatientDO::getId);
.betweenIfPresent(InspectPatientDO::getPrinttime, reqVO.getPrintTimeRange());
// .orderByDesc(InspectPatientDO::getId);
// if (reqVO.getInspectionStatus() != null) {
// if (reqVO.getInspectionStatus() == 0) {
// // 如果传过来的值为0查询InspectionOpinion字段不为空
@ -55,7 +55,25 @@ public interface InspectPatientMapper extends BaseMapperX<InspectPatientDO> {
// queryWrapper.and(wrapper -> wrapper.isNull(InspectPatientDO::getSummaryResult).or().eq(InspectPatientDO::getSummaryResult, ""));
// }
// }
// 只查询需要的字段
queryWrapper.select(
InspectPatientDO::getId,
InspectPatientDO::getMedicalSn,
InspectPatientDO::getPName,
InspectPatientDO::getGender,
InspectPatientDO::getBirthday,
InspectPatientDO::getCardType,
InspectPatientDO::getCardId,
InspectPatientDO::getPhoneNum,
InspectPatientDO::getStatus,
InspectPatientDO::getMedicalDateTime,
// InspectPatientDO::getHeadPicUrl,
InspectPatientDO::getSummaryResult,
InspectPatientDO::getAuditor,
InspectPatientDO::getAuditStatus,
InspectPatientDO::getIsprint,
InspectPatientDO::getPrinttime
);
return selectPage(reqVO, queryWrapper);
}

View File

@ -160,4 +160,12 @@ public interface InspectPatientService {
List<PatientSupplementVO> getPatientSupplementsByDates(List<LocalDate> dates);
void exportStatistics(List<LocalDate> dates, HttpServletResponse response);
/**
* 根据体检编号更新条码时间
*
* @param medicalSn 体检编号
* @param barcodetime 条码时间
*/
void updateBarcodeTime(String medicalSn, Date barcodetime);
}

View File

@ -1013,4 +1013,15 @@ public class InspectPatientServiceImpl implements InspectPatientService {
// 转换为Excel VO对象
return BeanUtils.toBean(patientList, InspectPatientExcelVO.class);
}
@Override
public void updateBarcodeTime(String medicalSn, Date barcodetime) {
// 构建更新条件
LambdaUpdateWrapper<InspectPatientDO> updateWrapper = new LambdaUpdateWrapper<>();
updateWrapper.eq(InspectPatientDO::getMedicalSn, medicalSn)
.set(InspectPatientDO::getBarcodetime, barcodetime);
// 执行更新
patientMapper.update(null, updateWrapper);
}
}