|
@@ -112,24 +112,27 @@ public class SetlListUpldService {
|
|
|
}
|
|
|
}
|
|
|
SetlinfoUpld temp = upldCollection.getData().getSetlinfo();
|
|
|
- if (StringUtil.isBlank(temp.getChfpdrCode())) {
|
|
|
- errorMessage.append("主诊医师编码为空。");
|
|
|
- }
|
|
|
- if (StringUtil.isBlank(temp.getRespNursCode())) {
|
|
|
- errorMessage.append("责任护士编码为空。");
|
|
|
+ if (!patNo.contains("-")){
|
|
|
+ if (StringUtil.isBlank(temp.getChfpdrCode())) {
|
|
|
+ errorMessage.append("主诊医师编码为空。");
|
|
|
+ }
|
|
|
+ if (StringUtil.isBlank(temp.getRespNursCode())) {
|
|
|
+ errorMessage.append("责任护士编码为空。");
|
|
|
+ }
|
|
|
}
|
|
|
+
|
|
|
if (ListUtil.notBlank(upldCollection.getData().getOprninfo())) {
|
|
|
for (OprninfoUpld item : upldCollection.getData().getOprninfo()) {
|
|
|
if (StringUtil.isBlank(item.getOperDrCode())) {
|
|
|
errorMessage.append(String.format("医生:【%s】,没有医保编码请去职工字典数据维护中添加", null == item.getOperDrName() ? "没有填写医生" : item.getOperDrName()));
|
|
|
}
|
|
|
- if (StringUtil.notBlank(item.getAnstDrName()) && StringUtil.isBlank(item.getAnstDrCode())) {
|
|
|
+ if (StringUtil.isBlank(item.getAnstDrName()) && StringUtil.isBlank(item.getAnstDrCode())) {
|
|
|
errorMessage.append(String.format("医生:【%s】,没有医保编码请去职工字典数据维护中添加", null == item.getAnstDrName() ? "没有填写医生" : item.getAnstDrName()));
|
|
|
}
|
|
|
if (StringUtil.notBlank(item.getAnstDrName()) && (StringUtil.isBlank(item.getAnstBegntime()) || StringUtil.isBlank(item.getAnstEndtime()))) {
|
|
|
errorMessage.append(String.format("手术:【%s】,有麻醉医生,没有麻时间请填写", item.getOprnOprtName()));
|
|
|
}
|
|
|
- if (StringUtil.notBlank(item.getOprnOprtEndtime())) {
|
|
|
+ if (StringUtil.isBlank(item.getOprnOprtEndtime())) {
|
|
|
errorMessage.append(String.format("手术:【%s】,手术结束时间为空。", item.getOprnOprtName()));
|
|
|
}
|
|
|
}
|
|
@@ -218,13 +221,13 @@ public class SetlListUpldService {
|
|
|
return ResultVoUtil.fail(ExceptionEnum.LOGICAL_ERROR, "结算id为空");
|
|
|
}
|
|
|
// 特级护理
|
|
|
- setlinfoUpld.setSpgaNurscareDays(String.valueOf(dao.teJiHuLi(publicServer.getInpatientNo(patNo), times, ledgerSn, publicServer.getInfantFlag(patNo))));
|
|
|
+ setlinfoUpld.setSpgaNurscareDays(nursingDays(dao.teJiHuLi(publicServer.getInpatientNo(patNo), times, ledgerSn, publicServer.getInfantFlag(patNo))));
|
|
|
// 一级护理
|
|
|
- setlinfoUpld.setLv1NurscareDays(String.valueOf(dao.yiJiHuLi(publicServer.getInpatientNo(patNo), times, ledgerSn, publicServer.getInfantFlag(patNo))));
|
|
|
+ setlinfoUpld.setLv1NurscareDays(nursingDays(dao.yiJiHuLi(publicServer.getInpatientNo(patNo), times, ledgerSn, publicServer.getInfantFlag(patNo))));
|
|
|
// 二级护理
|
|
|
- setlinfoUpld.setScdNurscareDays(String.valueOf(dao.erJiHuLi(publicServer.getInpatientNo(patNo), times, ledgerSn, publicServer.getInfantFlag(patNo))));
|
|
|
+ setlinfoUpld.setScdNurscareDays(nursingDays(dao.erJiHuLi(publicServer.getInpatientNo(patNo), times, ledgerSn, publicServer.getInfantFlag(patNo))));
|
|
|
// 三级护理
|
|
|
- setlinfoUpld.setLv3NurscareDays(String.valueOf(dao.sanJiHuLi(publicServer.getInpatientNo(patNo), times, ledgerSn, publicServer.getInfantFlag(patNo))));
|
|
|
+ setlinfoUpld.setLv3NurscareDays(nursingDays(dao.sanJiHuLi(publicServer.getInpatientNo(patNo), times, ledgerSn, publicServer.getInfantFlag(patNo))));
|
|
|
GetDropdownBox getDropdownBox = dao.userInfo(TokenUtil.getTokenUserId());
|
|
|
// 医疗机构填报人
|
|
|
setlinfoUpld.setMedinsFillPsn(getDropdownBox.getName());
|
|
@@ -320,6 +323,9 @@ public class SetlListUpldService {
|
|
|
if (StringUtil.isBlank(setlinfoUpld.getEmpName())) {
|
|
|
setlinfoUpld.setEmpName("普通职工");
|
|
|
}
|
|
|
+ if (StringUtil.isBlank(setlinfoUpld.getEmpTel())) {
|
|
|
+ setlinfoUpld.setEmpTel(setlinfoUpld.getConerTel());
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
// 呼吸机使用时长
|
|
@@ -359,10 +365,39 @@ public class SetlListUpldService {
|
|
|
upldCollection.getSetlinfo().setNwbAge(null);
|
|
|
upldCollection.getSetlinfo().setNwbAdmType(null);
|
|
|
}
|
|
|
+ List<String> urbanAndRuralMedicalInsurance = Arrays.asList("390", "392");
|
|
|
+ // 城乡医保类型可不填这两项
|
|
|
+ if (urbanAndRuralMedicalInsurance.contains(setlinfoUpld.getHiType())) {
|
|
|
+ setlinfoUpld.setEmpTel(null);
|
|
|
+ setlinfoUpld.setPoscode(null);
|
|
|
+ }
|
|
|
+ // 颅脑损伤患者昏迷时间 没有就不填写
|
|
|
+ if ("0/0/0".equals(setlinfoUpld.getPwcryAfadmComaDura())) {
|
|
|
+ setlinfoUpld.setPwcryAfadmComaDura(null);
|
|
|
+ }
|
|
|
+ if ("0/0/0".equals(setlinfoUpld.getPwcryBfadmComaDura())) {
|
|
|
+ setlinfoUpld.setPwcryBfadmComaDura(null);
|
|
|
+ }
|
|
|
|
|
|
return ResultVoUtil.success(upldCollection);
|
|
|
}
|
|
|
|
|
|
+ /**
|
|
|
+ * 特级护理天数如果是 0 就不传值
|
|
|
+ *
|
|
|
+ * @param days
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ private String nursingDays(Integer days) {
|
|
|
+ if (days == null) {
|
|
|
+ return null;
|
|
|
+ } else if (days.equals(0)) {
|
|
|
+ return null;
|
|
|
+ } else {
|
|
|
+ return String.valueOf(days);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
@NotNull
|
|
|
private List<IcuinfoUpld> getIcuinfoUplds(String patNo, Integer times) {
|
|
|
List<IcuinfoUpld> zhongZhenJianHu = new ArrayList<>();
|
|
@@ -1188,8 +1223,6 @@ public class SetlListUpldService {
|
|
|
} else {
|
|
|
upldCollection.setOpspdiseinfo(dao.outpatientDiagnosis2(patNo, times));
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
mzPatient.setHsorg("长沙市医疗保障事务中心");
|
|
|
mzPatient.setHsorgOpter("长沙市医疗保障事务中心");
|
|
|
GetDropdownBox getDropdownBox = dao.userInfo(TokenUtil.getTokenUserId());
|
|
@@ -1238,6 +1271,12 @@ public class SetlListUpldService {
|
|
|
upldCollection.getSetlinfo().setPsnCashpay(upldCollection.getSetlinfo().getPsnSelfpay());
|
|
|
}
|
|
|
}
|
|
|
+ List<String> urbanAndRuralMedicalInsurance = Arrays.asList("390", "392");
|
|
|
+ // 城乡医保类型可不填这两项
|
|
|
+ if (urbanAndRuralMedicalInsurance.contains(mzPatient.getHiType())) {
|
|
|
+ mzPatient.setEmpTel(null);
|
|
|
+ mzPatient.setPoscode(null);
|
|
|
+ }
|
|
|
return ResultVoUtil.success(upldCollection);
|
|
|
}
|
|
|
|
|
@@ -1294,5 +1333,4 @@ public class SetlListUpldService {
|
|
|
}
|
|
|
|
|
|
|
|
|
-
|
|
|
}
|