xiaochan 3 rokov pred
rodič
commit
363efae1a5

+ 34 - 72
src/main/java/thyyxxk/webserver/dao/his/yibao/XiangMuLuRuDao.java

@@ -445,78 +445,40 @@ public interface XiangMuLuRuDao extends BaseMapper<ZyDetailCharge> {
      * @param opIdCode    录入人id
      * @return 返回模板 下面的详细信息
      */
-    @Select("SELECT charge_name=RTRIM(b.name),   " +
-            "       pattern_name=zy_charge_pattern.pattern_name,   " +
-            "       charge_code_mx=b.code,   " +
-            "       spec=charge_unit,   " +
-            "       group_no='00',   " +
-            "       serial='00',   " +
-            "       amount=zy_charge_pattern.amount,   " +
-            "       charge_amount=b.charge_amount  ,   " +
-            "       self    =b.self_flag,   " +
-            "       separate_flag=b.separate_flag,   " +
-            "       suprice_flag=b.suppress_flag,   " +
-            "       infant='0',   " +
-            "       per1=zy_charge_pattern.per1,   " +
-            "       per2=zy_charge_pattern.per2,   " +
-            "       per3=zy_charge_pattern.per3,   " +
-            "       per4=zy_charge_pattern.per4,   " +
-            "       per5=zy_charge_pattern.per5,   " +
-            "       exec_unit_b=b.exec_unit,   " +
-            "       item_no=zy_charge_pattern.item_no,   " +
-            "       exec_unit_name=c.name,   " +
-            "       exec_unit=zy_charge_pattern.exec_unit,   " +
-            "       op_id_code=zy_charge_pattern.op_id_code,   " +
-            "       zy_charge_pattern.py_code,   " +
-            "       zy_charge_pattern.d_code,   " +
-            "       price_b=b.charge_amount,   " +
-            "       bill_item_code=b.bill_item_zy ," +
-            "       bill_item_name=(select name from zy_bill_item where code = b.bill_item_zy)  " +
-            "FROM zy_charge_pattern ,zd_charge_item b ,zd_unit_code c   " +
-            "WHERE ( zy_charge_pattern.pattern_name = #{patternName})    and   " +
-            "      zy_charge_pattern.op_id_code=#{opIdCode} and   " +
-            "      zy_charge_pattern.charge_code=b.code and   " +
-            "      (isnull(b.del_flag,'0') <> '1' ) and  " +
-            "      zy_charge_pattern.exec_unit*=c.code   " +
-            "union all   " +
-            "SELECT charge_name=RTRIM(d.name),   " +
-            "       pattern_name=zy_charge_pattern.pattern_name,   " +
-            "       charge_code_mx=b.charge_code,   " +
-            "       spec=d.specification,   " +
-            "       group_no=b.group_no,   " +
-            "       serial=isnull(b.serial,'01'),   " +
-            "       amount=zy_charge_pattern.amount,   " +
-            "       charge_amount=d.pack_retprice,   " +
-            "       self    =d.self_flag,   " +
-            "       separate_flag=d.separate_flag,   " +
-            "       suprice=d.suprice_flag,   " +
-            "       infant='0',   " +
-            "       per1=zy_charge_pattern.per1,   " +
-            "       per2=zy_charge_pattern.per2,   " +
-            "       per3=zy_charge_pattern.per3,   " +
-            "       per4=zy_charge_pattern.per4,   " +
-            "       per5=zy_charge_pattern.per5,   " +
-            "       exec_unit_b=''   ,   " +
-            "       item_no=zy_charge_pattern.item_no,   " +
-            "       exec_unit_name=c.name,   " +
-            "       exec_unit=zy_charge_pattern.exec_unit,   " +
-            "       op_id_code=zy_charge_pattern.op_id_code,   " +
-            "       zy_charge_pattern.py_code,   " +
-            "       zy_charge_pattern.d_code,   " +
-            "       price_b=d.pack_retprice,   " +
-            "       bill_item_code=d.bill_item_zy ," +
-            "       bill_item_name=(select name from zy_bill_item where code = d.bill_item_zy)  " +
-            "FROM zy_charge_pattern ,zd_unit_code c,yp_base_yf b,yp_zd_dict d   " +
-            "WHERE ( zy_charge_pattern.pattern_name = #{patternName}) and   " +
-            "      zy_charge_pattern.op_id_code=#{opIdCode} and   " +
-            "      zy_charge_pattern.group_no=b.group_no and   " +
-            "      zy_charge_pattern.charge_code=b.charge_code and   " +
-            "      isnull(zy_charge_pattern.serial,'01')=b.serial and   " +
-            "      b.charge_code=d.code and   " +
-            "      b.serial=d.serial and   " +
-            "      isnull(d.del_flag,'0') <> '1' and " +
-            "      isnull(b.visible_flag_zy,'0') <> '1' and   " +
-            "      zy_charge_pattern.exec_unit*=c.code")
+    @Select("SELECT charge_name=RTRIM(b.name), " +
+            "       charge_code_mx=b.code, " +
+            "       amount=a.amount, " +
+            "       charge_amount=b.charge_amount, " +
+            "       op_id_code=a.op_id_code, " +
+            "       bill_item_code=b.bill_item_zy, " +
+            "       bill_item_name=(select name from zy_bill_item where code = b.bill_item_zy) " +
+            "FROM zy_charge_pattern a, " +
+            "     zd_charge_item b " +
+            "WHERE (a.pattern_name =  #{patternName}) " +
+            "  and a.op_id_code =  #{opIdCode} " +
+            "  and a.charge_code = b.code " +
+            "  and isnull(a.serial, '01') = '00' " +
+            "  and (isnull(b.del_flag, '0') <> '1') " +
+            "union all " +
+            "SELECT charge_name=RTRIM(d.name), " +
+            "       charge_code_mx=b.charge_code, " +
+            "       amount=a.amount, " +
+            "       charge_amount=d.pack_retprice, " +
+            "       op_id_code=a.op_id_code, " +
+            "       bill_item_code=d.bill_item_zy, " +
+            "       bill_item_name=(select name from zy_bill_item where code = d.bill_item_zy) " +
+            "FROM zy_charge_pattern a, " +
+            "     yp_base_yf b, " +
+            "     yp_zd_dict d " +
+            "WHERE (a.pattern_name =  #{patternName}) " +
+            "  and a.op_id_code =  #{opIdCode} " +
+            "  and a.group_no = b.group_no " +
+            "  and a.charge_code = b.charge_code " +
+            "  and isnull(a.serial, '01') = b.serial " +
+            "  and b.charge_code = d.code " +
+            "  and b.serial = d.serial " +
+            "  and isnull(d.del_flag, '0') <> '1' " +
+            "  and isnull(b.visible_flag_zy, '0') <> '1'")
     List<ZyDetailCharge> getMuBanXinXi(@Param("patternName") String patternName, @Param("opIdCode") String opIdCode);
 
     /**

+ 3 - 2
src/main/java/thyyxxk/webserver/service/jimubaobiao/JiMuBaoBiaoService.java

@@ -11,6 +11,7 @@ import thyyxxk.webserver.utils.ResultVoUtil;
 import thyyxxk.webserver.utils.StringUtil;
 
 import java.math.BigDecimal;
+import java.math.RoundingMode;
 import java.sql.Timestamp;
 import java.util.ArrayList;
 import java.util.HashMap;
@@ -55,10 +56,10 @@ public class JiMuBaoBiaoService {
         for (BigDecimal integer : huanZheZhuYuanTianShu) {
             sum = sum.add(integer);
         }
-        // 患者总人数
+        // 患者总人数 totalNumberOfPatients
         BigDecimal huanZheRenShu = dao.huanZheRenShu(Timestamp.valueOf(startTime), Timestamp.valueOf(endTime));
         // 患者的平均住院天数
-        BigDecimal pingJunZhuYuanTianShu = sum.divide(huanZheRenShu, 2, BigDecimal.ROUND_HALF_UP);
+        BigDecimal pingJunZhuYuanTianShu = sum.divide(huanZheRenShu, 2, RoundingMode.HALF_UP);
         List<BaoBiaoChaXun> list = new ArrayList<>();
         list.add(new BaoBiaoChaXun("总住院天数", sum, "天"));
         list.add(new BaoBiaoChaXun("患者的总人数", huanZheRenShu, "人"));

+ 21 - 39
src/main/java/thyyxxk/webserver/service/yibao/XiangMuLuRuService.java

@@ -58,8 +58,7 @@ public class XiangMuLuRuService {
             return ResultVoUtil.fail(ExceptionEnum.LOGICAL_ERROR, "住院号或住院次数为空 <br/>๑乛◡乛๑");
         }
         Integer ledgerSn = publicServer.getLedgerSn(param.getInpatientNo(), param.getAdmissTimes());
-        log.info("查询患者费用==》住院号{},住院次数:{},项目名称:{},费用类型:{},科室:{},当前页:{},页大小:{},退费:{},总数:{},账页号:{}", param.getInpatientNo(), param.getAdmissTimes(),
-                param.getChargeCode(), param.getOrderNo(), param.getDept(), param.getCurrentPage(), param.getPageSize(), param.getTuiFeiFlag(), param.getTotal(), ledgerSn);
+        log.info("查询患者费用==》住院号{},住院次数:{},项目名称:{},费用类型:{},科室:{},当前页:{},页大小:{},退费:{},总数:{},账页号:{}", param.getInpatientNo(), param.getAdmissTimes(), param.getChargeCode(), param.getOrderNo(), param.getDept(), param.getCurrentPage(), param.getPageSize(), param.getTuiFeiFlag(), param.getTotal(), ledgerSn);
         int infantFlag = 0;
         // 如果是婴儿的话那么就需要截取 字符串了 在通过婴儿标识来判断
         if (param.getInpatientNo().contains("$")) {
@@ -73,18 +72,14 @@ public class XiangMuLuRuService {
 
         if (param.getFeiYongLeiXingCode() == 0) {
             if (param.getTotal() == 0) {
-                page.setTotal(dao.huanZheFeiYongToatal(param.getInpatientNo(), param.getAdmissTimes(), ledgerSn, param.getChargeCode(), infantFlag,
-                        param.getStartTime(), param.getEndTime(), param.getOrderNo(), param.getDept(), param.getTuiFeiFlag()));
+                page.setTotal(dao.huanZheFeiYongToatal(param.getInpatientNo(), param.getAdmissTimes(), ledgerSn, param.getChargeCode(), infantFlag, param.getStartTime(), param.getEndTime(), param.getOrderNo(), param.getDept(), param.getTuiFeiFlag()));
             }
-            page.setRecords(dao.huanZheXiangMuFeiYong(param.getCurrentPage(), param.getPageSize(), param.getInpatientNo(), param.getAdmissTimes(), ledgerSn, param.getChargeCode(), infantFlag,
-                    param.getStartTime(), param.getEndTime(), param.getOrderNo(), param.getDept(), param.getRiQiPaiXu(), param.getTuiFeiFlag()));
+            page.setRecords(dao.huanZheXiangMuFeiYong(param.getCurrentPage(), param.getPageSize(), param.getInpatientNo(), param.getAdmissTimes(), ledgerSn, param.getChargeCode(), infantFlag, param.getStartTime(), param.getEndTime(), param.getOrderNo(), param.getDept(), param.getRiQiPaiXu(), param.getTuiFeiFlag()));
         } else {
             if (param.getTotal() == 0) {
-                page.setTotal(dao.huanZheYaoPinFeiYongTotal(param.getInpatientNo(), param.getAdmissTimes(), ledgerSn, param.getChargeCode(), infantFlag,
-                        param.getStartTime(), param.getEndTime(), param.getOrderNo(), param.getDept(), param.getTuiFeiFlag()));
+                page.setTotal(dao.huanZheYaoPinFeiYongTotal(param.getInpatientNo(), param.getAdmissTimes(), ledgerSn, param.getChargeCode(), infantFlag, param.getStartTime(), param.getEndTime(), param.getOrderNo(), param.getDept(), param.getTuiFeiFlag()));
             }
-            page.setRecords(dao.huanZheYaoPinFeiYong(param.getCurrentPage(), param.getPageSize(), param.getInpatientNo(), param.getAdmissTimes(), ledgerSn, param.getChargeCode(), infantFlag,
-                    param.getStartTime(), param.getEndTime(), param.getOrderNo(), param.getDept(), param.getRiQiPaiXu(), param.getTuiFeiFlag()));
+            page.setRecords(dao.huanZheYaoPinFeiYong(param.getCurrentPage(), param.getPageSize(), param.getInpatientNo(), param.getAdmissTimes(), ledgerSn, param.getChargeCode(), infantFlag, param.getStartTime(), param.getEndTime(), param.getOrderNo(), param.getDept(), param.getRiQiPaiXu(), param.getTuiFeiFlag()));
         }
         if (ListUtil.isBlank(page.getRecords())) {
             return ResultVoUtil.fail(ExceptionEnum.NO_DATA_EXIST, "没有查询到符合费用。");
@@ -164,7 +159,9 @@ public class XiangMuLuRuService {
             }
             // 在这里判断执行科室
             ResultVo<String> LOGICAL_ERROR = getStringResultVo(yongHuJueSe, zhiXinKeShi, param, pojo, panDuanYaoPing);
-            if (LOGICAL_ERROR != null) return LOGICAL_ERROR;
+            if (LOGICAL_ERROR != null) {
+                return LOGICAL_ERROR;
+            }
             // 数据库有个 触发器 如果带了医嘱号且有篆刻那么这里就需要改成 0
             if (BigUtils.bigDaYu(pojo.getOrderNo(), 10)) {
                 pojo.setOrderNo(new BigDecimal(0));
@@ -190,14 +187,12 @@ public class XiangMuLuRuService {
                 dao.shenQingYaoPing(param, yaoPingDan, infantFlag, publicServer.getLedgerSn(param.getInpatientNo(), param.getAdmissTimes()), TokenUtil.getTokenUserId());
             }
             fenGe.forEach(dao::xiangMuTuiFei);
-            dao.genXinZhenShuTuiFeiLiuShui(param.getInpatientNo(), param.getAdmissTimes(),
-                    publicServer.getLedgerSn(param.getInpatientNo(), param.getAdmissTimes()), genXingZhenShuTuiFeiLiuShui);
+            dao.genXinZhenShuTuiFeiLiuShui(param.getInpatientNo(), param.getAdmissTimes(), publicServer.getLedgerSn(param.getInpatientNo(), param.getAdmissTimes()), genXingZhenShuTuiFeiLiuShui);
             return ResultVoUtil.success(ExceptionEnum.SUCCESS_AND_NOTIFICATION, "项目退费操作成功。乁( ˙ ω˙乁)");
         }
     }
 
-    private ResultVo<String> getStringResultVo(List<Integer> yongHuJueSe, List<String> zhiXinKeShi, ZyDetailCharge xuYaoTuiDeShuJu,
-                                               ZyDetailCharge piPeiDeShuJu, Boolean panDuanYaoPin) {
+    private ResultVo<String> getStringResultVo(List<Integer> yongHuJueSe, List<String> zhiXinKeShi, ZyDetailCharge xuYaoTuiDeShuJu, ZyDetailCharge piPeiDeShuJu, Boolean panDuanYaoPin) {
         // 获取到用户角色   管理员角色可以无视
         if (!yongHuJueSe.contains(1) && !yongHuJueSe.contains(8)) {
             // 科室开头 是 8 就不是医技科室 只有医技科室可以退药品
@@ -215,7 +210,7 @@ public class XiangMuLuRuService {
             } else if (panDuanYaoPin) {
                 if (!xuYaoTuiDeShuJu.getDeptCode().equals(piPeiDeShuJu.getExecUnit())) {
                     return ResultVoUtil.fail(ExceptionEnum.LOGICAL_ERROR, String.format("流水号为【%s】,请对应的执行科室进行退费。", piPeiDeShuJu.getDetailSn()));
-                } else if ((BigUtils.bigDaYu(piPeiDeShuJu.getOrderNo(), 100) || BigUtils.bigXiaoYu(piPeiDeShuJu.getOrderNo(), 0)) && piPeiDeShuJu.getSerial().equals("01")) {
+                } else if ((BigUtils.bigDaYu(piPeiDeShuJu.getOrderNo(), 100) || BigUtils.bigXiaoYu(piPeiDeShuJu.getOrderNo(), 0)) && "01".equals(piPeiDeShuJu.getSerial())) {
                     return ResultVoUtil.fail(ExceptionEnum.LOGICAL_ERROR, String.format("流水号为【%s】,只能退本科室录入的药品。", piPeiDeShuJu.getDetailSn()));
                 }
             }
@@ -488,13 +483,10 @@ public class XiangMuLuRuService {
         List<ZyDetailCharge> erCiPiPei = new ArrayList<>();
         // 用map 来保存正数的信息,但是有可能匹配的条件中map 的 key会一致 所以在这里使用 java8 的新特性 stream 流来进行分组 这样就不会因为key 一样导致数据被覆盖了
         // 第一次 匹配 根据 医嘱号 收费时间 项目编码 数量 账页号
-        Map<String, List<ZyDetailCharge>> zhenShuMap = getYiZhuFeiYongZhenShu.stream().collect(
-                Collectors.groupingBy(item -> item.getOrderNo() + DateUtil.formatDatetime(item.getChargeDate()) + item.getChargeCodeMx() + item.getChargeAmount() + item.getChargeFee() + item.getLedgerSn())
-        );
+        Map<String, List<ZyDetailCharge>> zhenShuMap = getYiZhuFeiYongZhenShu.stream().collect(Collectors.groupingBy(item -> item.getOrderNo() + DateUtil.formatDatetime(item.getChargeDate()) + item.getChargeCodeMx() + item.getChargeAmount() + item.getChargeFee() + item.getLedgerSn()));
         // 用负数拼接的 key 去查找
         for (ZyDetailCharge fuShu : getYiZhuFeiYongFuShu) {
-            String key = fuShu.getOrderNo() + DateUtil.formatDatetime(fuShu.getChargeDate()) + fuShu.getChargeCodeMx() + fuShu.getChargeAmount().negate()
-                    + fuShu.getChargeFee().negate() + fuShu.getLedgerSn();
+            String key = fuShu.getOrderNo() + DateUtil.formatDatetime(fuShu.getChargeDate()) + fuShu.getChargeCodeMx() + fuShu.getChargeAmount().negate() + fuShu.getChargeFee().negate() + fuShu.getLedgerSn();
             if (zhenShuMap.containsKey(key)) {
                 for (ZyDetailCharge zyDetailCharge : zhenShuMap.get(key)) {
                     if (zyDetailCharge.getTuiFeiFlag() == null && zyDetailCharge.getOriDetailSn() == null) {
@@ -513,13 +505,10 @@ public class XiangMuLuRuService {
         // 下面是二次匹配
         if (erCiPiPei.size() > 0) {
             // 二次匹配 条件为 执行科室 项目编码 数量 账页号
-            Map<String, List<ZyDetailCharge>> erCiPiPeiZhenShu = getYiZhuFeiYongZhenShu.stream().collect(
-                    Collectors.groupingBy(item -> item.getExecUnit() + item.getChargeCodeMx() + item.getChargeAmount() + item.getChargeFee() + item.getLedgerSn())
-            );
+            Map<String, List<ZyDetailCharge>> erCiPiPeiZhenShu = getYiZhuFeiYongZhenShu.stream().collect(Collectors.groupingBy(item -> item.getExecUnit() + item.getChargeCodeMx() + item.getChargeAmount() + item.getChargeFee() + item.getLedgerSn()));
             // 开始二次匹配
             for (ZyDetailCharge zyDetailCharge : erCiPiPei) {
-                String key = zyDetailCharge.getExecUnit() + zyDetailCharge.getChargeCodeMx() + zyDetailCharge.getChargeAmount().negate()
-                        + zyDetailCharge.getChargeFee().negate() + zyDetailCharge.getLedgerSn();
+                String key = zyDetailCharge.getExecUnit() + zyDetailCharge.getChargeCodeMx() + zyDetailCharge.getChargeAmount().negate() + zyDetailCharge.getChargeFee().negate() + zyDetailCharge.getLedgerSn();
                 if (erCiPiPeiZhenShu.containsKey(key)) {
                     for (ZyDetailCharge detailCharge : erCiPiPeiZhenShu.get(key)) {
                         if (detailCharge.getTuiFeiFlag() == null && detailCharge.getOriDetailSn() == null) {
@@ -542,8 +531,7 @@ public class XiangMuLuRuService {
             }
             publicServer.genXingYuanLiuShuiBiaoZhi(inpatientNo, admissTimes, ledgerSn);
             log.info("医嘱退费匹配 ==》 操作人:{},住院号:{},住院次数:{}", TokenUtil.getTokenUserId(), inpatientNo, admissTimes);
-            return ResultVoUtil.success(ExceptionEnum.SUCCESS_AND_NOTIFICATION,
-                    String.format("匹配成功共:{%d}条,匹配成功:{%s}条", getYiZhuFeiYongFuShu.size(), piPei.size()));
+            return ResultVoUtil.success(ExceptionEnum.SUCCESS_AND_NOTIFICATION, String.format("匹配成功共:{%d}条,匹配成功:{%s}条", getYiZhuFeiYongFuShu.size(), piPei.size()));
         }
         publicServer.genXingYuanLiuShuiBiaoZhi(inpatientNo, admissTimes, ledgerSn);
         return ResultVoUtil.fail(ExceptionEnum.NO_DATA_EXIST, String.format("该患者有【%d】条,未能匹配 |д・)っ", getYiZhuFeiYongFuShu.size()));
@@ -638,20 +626,15 @@ public class XiangMuLuRuService {
     }
 
 
-    public ResultVo<List<ZyDetailCharge>> huoQuZhenShuKePiPei(String inpatientNo, Integer admissTimes, Integer ledgerSn,
-                                                              String chargeCodeMx, String execUnit, String orderNo, String startTime,
-                                                              String endTime, String riQiPaiXu) {
+    public ResultVo<List<ZyDetailCharge>> huoQuZhenShuKePiPei(String inpatientNo, Integer admissTimes, Integer ledgerSn, String chargeCodeMx, String execUnit, String orderNo, String startTime, String endTime, String riQiPaiXu) {
         execUnit = StringUtil.isBlank(execUnit) ? null : execUnit;
-        List<ZyDetailCharge> zhenShuFeiYong = dao.weiGuiZhenShuPiPei(publicServer.getInpatientNo(inpatientNo), admissTimes, ledgerSn, publicServer.getInfantFlag(inpatientNo),
-                chargeCodeMx, execUnit, orderNo, startTime, endTime, riQiPaiXu);
+        List<ZyDetailCharge> zhenShuFeiYong = dao.weiGuiZhenShuPiPei(publicServer.getInpatientNo(inpatientNo), admissTimes, ledgerSn, publicServer.getInfantFlag(inpatientNo), chargeCodeMx, execUnit, orderNo, startTime, endTime, riQiPaiXu);
 
         if (ListUtil.isBlank(zhenShuFeiYong)) {
-            zhenShuFeiYong.addAll(dao.weiGuiZhenShuPiPei(publicServer.getInpatientNo(inpatientNo), admissTimes, ledgerSn, publicServer.getInfantFlag(inpatientNo),
-                    chargeCodeMx, null, orderNo, startTime, endTime, riQiPaiXu));
+            zhenShuFeiYong.addAll(dao.weiGuiZhenShuPiPei(publicServer.getInpatientNo(inpatientNo), admissTimes, ledgerSn, publicServer.getInfantFlag(inpatientNo), chargeCodeMx, null, orderNo, startTime, endTime, riQiPaiXu));
         }
         if (ListUtil.isBlank(zhenShuFeiYong)) {
-            return ResultVoUtil.fail(ExceptionEnum.NO_DATA_EXIST, "没有查询到该负数费用的对应正数。", dao.genJuBianMaChaZhaoZhenShuFeiYong(publicServer.getInpatientNo(inpatientNo), admissTimes, ledgerSn,
-                    publicServer.getInfantFlag(inpatientNo), chargeCodeMx, startTime, endTime, riQiPaiXu));
+            return ResultVoUtil.fail(ExceptionEnum.NO_DATA_EXIST, "没有查询到该负数费用的对应正数。", dao.genJuBianMaChaZhaoZhenShuFeiYong(publicServer.getInpatientNo(inpatientNo), admissTimes, ledgerSn, publicServer.getInfantFlag(inpatientNo), chargeCodeMx, startTime, endTime, riQiPaiXu));
         }
         List<ZyDetailCharge> yuEr = dao.tuiFeiYuEr1(publicServer.getInpatientNo(inpatientNo), admissTimes, ledgerSn, chargeCodeMx, execUnit);
         Map<String, ZyDetailCharge> yuErPiPei = new HashMap<>();
@@ -696,8 +679,7 @@ public class XiangMuLuRuService {
         }
         List<ZyDetailCharge> zhenShuShuJu = dao.piPeiXinXi(inpatientNo, zyDetailCharge.getAdmissTimes(), zyDetailCharge.getLedgerSn(), infantFlag, detailSnList);
 
-        Map<Integer, ZyDetailCharge> tuiFeiYuErPiPei = dao.tuiFeiYuEr2(inpatientNo, zyDetailCharge.getAdmissTimes(), zyDetailCharge.getLedgerSn(), infantFlag, detailSnList).stream().collect(
-                Collectors.toMap(ZyDetailCharge::getOriDetailSn, a -> a, (k1, k2) -> k1));
+        Map<Integer, ZyDetailCharge> tuiFeiYuErPiPei = dao.tuiFeiYuEr2(inpatientNo, zyDetailCharge.getAdmissTimes(), zyDetailCharge.getLedgerSn(), infantFlag, detailSnList).stream().collect(Collectors.toMap(ZyDetailCharge::getOriDetailSn, a -> a, (k1, k2) -> k1));
         BigDecimal chargeFeeSum = new BigDecimal(0);
         BigDecimal chargeAmountSum = new BigDecimal(0);