Browse Source

修改筛查报告单

newMaster
zzc 4 months ago
parent
commit
14e5c70248
  1. 2
      acupuncture-system/src/main/java/com/acupuncture/system/service/impl/PmsTreatmentServiceImpl.java
  2. 137
      acupuncture-system/src/main/java/com/acupuncture/system/service/impl/ScreeningServiceImpl.java

2
acupuncture-system/src/main/java/com/acupuncture/system/service/impl/PmsTreatmentServiceImpl.java

@ -610,7 +610,7 @@ public class PmsTreatmentServiceImpl implements PmsTreatmentService {
if (StrUtil.isNotEmpty(idcard) && IdcardUtil.isValidCard(idcard)) {
dto.setBirthDate(IdcardUtil.getBirthDate(idcard));
}
dto.setIdCardType(rowList.get(7).toString().trim().equals("身份证") ? 0 : rowList.get(7).toString().trim().equals("护照或外国人永居证") ? 1 : rowList.get(7).toString().trim().equals("港澳居民来往内地通行证") ? 2 : rowList.get(7).toString().trim().equals("台湾居民来往大陆通行证") ? 3 : 4);
// dto.setIdCardType(rowList.get(7).toString().trim().equals("身份证") ? 0 : rowList.get(7).toString().trim().equals("护照或外国人永居证") ? 1 : rowList.get(7).toString().trim().equals("港澳居民来往内地通行证") ? 2 : rowList.get(7).toString().trim().equals("台湾居民来往大陆通行证") ? 3 : 4);
dto.setIdCard(idcard);
dto.setVisitType(rowList.get(9).toString().trim().equals("门诊") ? 0 : 1);
dto.setVisitNumber(rowList.get(10).toString());

137
acupuncture-system/src/main/java/com/acupuncture/system/service/impl/ScreeningServiceImpl.java

@ -87,23 +87,20 @@ public class ScreeningServiceImpl implements IScreeningService {
List<String> headerList = CollectionUtil.newArrayList(
"姓名",
"性别",
"年龄",
"身份证",
"出生日期",
"手机号",
"有高血压,>=140/90mmHg",
"血脂异常,或不清楚",
"有糖尿病",
"心跳不规则",
"吸烟",
"明显超重或肥胖",
"缺乏运动",
"有卒中家族史",
"有既往脑卒中病史",
"有既往短暂脑缺血病史",
"筛查结果",
"数据来源",
"科室名称");
"年龄",
// "身份证",
"联系方式",
"身高",
"体重",
"BMI",
"体重自评结论",
"失眠自评(SRSS)得分",
"可接受的治疗方式",
"可接受的治疗周期",
"筛查时间",
"组织"
);
excelWriter.writeHeadRow(headerList);
PageInfo<ScrScreenVo.Result> page = queryDetailByPage(param, -1, -1);
@ -124,55 +121,66 @@ public class ScreeningServiceImpl implements IScreeningService {
row += 1;
excelWriter.writeCellValue(0, row, detailVos.get(i).getName() + "");
excelWriter.writeCellValue(1, row, map.get("SCWJ-SEX") == null ? "未知" : map.get("SCWJ-SEX").getAnswer());
excelWriter.writeCellValue(2, row, map.get("SCWJ-AGE") == null ? "" : map.get("SCWJ-AGE").getAnswer());
excelWriter.writeCellValue(3, row, map.get("SCWJ-idCard") == null ? "" : map.get("SCWJ-idCard").getAnswer());
excelWriter.writeCellValue(4, row, map.get("SCWJ-BIRTH") == null ? "" : map.get("SCWJ-BIRTH").getAnswer());
excelWriter.writeCellValue(5, row, map.get("SCWJ-PHONE") == null ? "" : map.get("SCWJ-PHONE").getAnswer());
// excelWriter.writeCellValue(3, row, map.get("SCWJ-idCard") == null ? "" : map.get("SCWJ-idCard").getAnswer());
excelWriter.writeCellValue(2, row, map.get("SCWJ-BIRTH") == null ? "" : map.get("SCWJ-BIRTH").getAnswer());
excelWriter.writeCellValue(3, row, map.get("SCWJ-AGE") == null ? "" : map.get("SCWJ-AGE").getAnswer());
excelWriter.writeCellValue(4, row, map.get("SCWJ-PHONE") == null ? "" : map.get("SCWJ-PHONE").getAnswer());
if (record == null || StrUtil.isEmpty(record.getAnswer())) {
excelWriter.writeCellValue(6, row, "否");
excelWriter.writeCellValue(7, row, "否");
excelWriter.writeCellValue(8, row, "否");
excelWriter.writeCellValue(9, row, "否");
excelWriter.writeCellValue(10, row, "否");
excelWriter.writeCellValue(11, row, "否");
excelWriter.writeCellValue(12, row, "否");
excelWriter.writeCellValue(13, row, "否");
excelWriter.writeCellValue(14, row, "否");
excelWriter.writeCellValue(15, row, "否");
} else {
String answer = record.getAnswer();
String[] split = answer.split(",");
excelWriter.writeCellValue(6, row, Arrays.asList(split).contains("01") ? "是" : "否");
excelWriter.writeCellValue(7, row, Arrays.asList(split).contains("02") ? "是" : "否");
excelWriter.writeCellValue(8, row, Arrays.asList(split).contains("03") ? "是" : "否");
excelWriter.writeCellValue(9, row, Arrays.asList(split).contains("04") ? "是" : "否");
excelWriter.writeCellValue(10, row, Arrays.asList(split).contains("05") ? "是" : "否");
excelWriter.writeCellValue(11, row, Arrays.asList(split).contains("06") ? "是" : "否");
excelWriter.writeCellValue(12, row, Arrays.asList(split).contains("07") ? "是" : "否");
excelWriter.writeCellValue(13, row, Arrays.asList(split).contains("08") ? "是" : "否");
excelWriter.writeCellValue(14, row, Arrays.asList(split).contains("09") ? "是" : "否");
excelWriter.writeCellValue(15, row, Arrays.asList(split).contains("10") ? "是" : "否");
}
String str = "";
if (map.get("SCWJ-RESULT") != null && StrUtil.isNotEmpty(map.get("SCWJ-RESULT").getAnswer())) {
String answer1 = map.get("SCWJ-RESULT").getAnswer();
if ("0".equals(answer1)) {
str = "正常";
}
if ("1".equals(answer1)) {
str = "低危";
}
if ("2".equals(answer1)) {
str = "中危";
}
if ("3".equals(answer1)) {
str = "高危";
}
}
excelWriter.writeCellValue(16, row, str);
excelWriter.writeCellValue(17, row, map.get("SCWJ-SQMC") == null ? "" : map.get("SCWJ-SQMC").getAnswer());
excelWriter.writeCellValue(18, row, map.get("SCWJ-DEPT") == null ? "" : map.get("SCWJ-DEPT").getAnswer());
excelWriter.writeCellValue(5, row, map.get("SCWJ-HEIGHT") == null ? "" : map.get("SCWJ-HEIGHT").getAnswer());
excelWriter.writeCellValue(6, row, map.get("SCWJ-WEIGHT") == null ? "" : map.get("SCWJ-WEIGHT").getAnswer());
excelWriter.writeCellValue(7, row, map.get("SCWJ-BMI") == null ? "" : map.get("SCWJ-BMI").getAnswer());
excelWriter.writeCellValue(8, row, map.get("SCWJ-JL") == null ? "" : map.get("SCWJ-JL").getAnswer());
excelWriter.writeCellValue(9, row, map.get("SCWJ-RESULT") == null ? "" : map.get("SCWJ-RESULT").getAnswer());
excelWriter.writeCellValue(10, row, map.get("SCWJ-ZLFS") == null ? "" : map.get("SCWJ-ZLFS").getAnswer());
excelWriter.writeCellValue(11, row, map.get("SCWJ-ZLZQ") == null ? "" : map.get("SCWJ-ZLZQ").getAnswer());
excelWriter.writeCellValue(12, row, DateUtil.format(detailVos.get(i).getCreateTime(), "yyyy-MM-dd HH:mm:ss"));
excelWriter.writeCellValue(13, row, detailVos.get(i).getTenantName());
// if (record == null || StrUtil.isEmpty(record.getAnswer())) {
// excelWriter.writeCellValue(6, row, "否");
// excelWriter.writeCellValue(7, row, "否");
// excelWriter.writeCellValue(8, row, "否");
// excelWriter.writeCellValue(9, row, "否");
// excelWriter.writeCellValue(10, row, "否");
// excelWriter.writeCellValue(11, row, "否");
// excelWriter.writeCellValue(12, row, "否");
// excelWriter.writeCellValue(13, row, "否");
// excelWriter.writeCellValue(14, row, "否");
// excelWriter.writeCellValue(15, row, "否");
// } else {
// String answer = record.getAnswer();
// String[] split = answer.split(",");
// excelWriter.writeCellValue(6, row, Arrays.asList(split).contains("01") ? "是" : "否");
// excelWriter.writeCellValue(7, row, Arrays.asList(split).contains("02") ? "是" : "否");
// excelWriter.writeCellValue(8, row, Arrays.asList(split).contains("03") ? "是" : "否");
// excelWriter.writeCellValue(9, row, Arrays.asList(split).contains("04") ? "是" : "否");
// excelWriter.writeCellValue(10, row, Arrays.asList(split).contains("05") ? "是" : "否");
// excelWriter.writeCellValue(11, row, Arrays.asList(split).contains("06") ? "是" : "否");
// excelWriter.writeCellValue(12, row, Arrays.asList(split).contains("07") ? "是" : "否");
// excelWriter.writeCellValue(13, row, Arrays.asList(split).contains("08") ? "是" : "否");
// excelWriter.writeCellValue(14, row, Arrays.asList(split).contains("09") ? "是" : "否");
// excelWriter.writeCellValue(15, row, Arrays.asList(split).contains("10") ? "是" : "否");
// }
// String str = "";
// if (map.get("SCWJ-RESULT") != null && StrUtil.isNotEmpty(map.get("SCWJ-RESULT").getAnswer())) {
// String answer1 = map.get("SCWJ-RESULT").getAnswer();
// if ("0".equals(answer1)) {
// str = "正常";
// }
// if ("1".equals(answer1)) {
// str = "低危";
// }
// if ("2".equals(answer1)) {
// str = "中危";
// }
// if ("3".equals(answer1)) {
// str = "高危";
// }
// }
// excelWriter.writeCellValue(16, row, map.get("SCWJ-JL") == null ? "" : map.get("SCWJ-JL").getAnswer());
// excelWriter.writeCellValue(17, row, map.get("SCWJ-SQMC") == null ? "" : map.get("SCWJ-SQMC").getAnswer());
// excelWriter.writeCellValue(18, row, map.get("SCWJ-DEPT") == null ? "" : map.get("SCWJ-DEPT").getAnswer());
}
}
}
@ -383,6 +391,7 @@ public class ScreeningServiceImpl implements IScreeningService {
}
if (param.getCode().equals("SCWJ-BIRTH")) {
questionnaireDetail.setAge(DateUtil.ageOfNow(param.getAnswer()));
param.setAnswer(DateUtil.format(DateUtil.parse(param.getAnswer()), "yyyy-MM-dd"));
}
log.info("questionnaireDetail:{}", questionnaireDetail.getId());
log.info("questionnaireDetail:{}", questionnaireDetail.getName());

Loading…
Cancel
Save