Sfoglia il codice sorgente

结算单上传发票号获取优化

lihong 3 mesi fa
parent
commit
a577963d25

+ 1 - 1
src/main/java/thyyxxk/webserver/dao/his/medicalinsurance/UpIdCollectionDao.java

@@ -261,7 +261,7 @@ public interface UpIdCollectionDao extends BaseMapper<SetlinfoUpld> {
             "where zyh = #{patNo} and zycs = #{times} " + "order by ssxh")
     List<OprninfoUpld> oprninfoUplds(@Param("patNo") String patNo, @Param("times") Integer times, @Param("tableName") String tableName);
 
-    @Select("select  case when isnull(dzfp_receipt_no,'') !='' then dzfp_receipt_no else  rtrim(receipt_no) end receipt_no  from zy_receipt where inpatient_no=#{patNo} and admiss_times=#{times} and ledger_sn=#{ledgerSn} and receipt_no<>'00000000'" + "and receipt_sn = 1")
+    @Select("select  case when isnull(dzfp_receipt_no,'') !='' then dzfp_receipt_no else  rtrim(receipt_no) end receipt_no  from zy_receipt where inpatient_no=#{patNo} and admiss_times=#{times} and ledger_sn=#{ledgerSn}  and receipt_sn = 1")
     String billNo(@Param("patNo") String patNo, @Param("times") Integer times, @Param("ledgerSn") Integer ledgerSn);
 
     @Select("select top 1  receipt_bill " +

+ 3 - 0
src/main/java/thyyxxk/webserver/service/medicalinsurance/SetlListUpldService.java

@@ -2357,6 +2357,9 @@ public class SetlListUpldService {
         setlinfoUpld.setHiSetlLv("3");
         // 票据代码
         String billNo = dao.billNo(patNo, times, ledgerSn);
+        if("00000000".equals(billNo)){
+            billNo = "";
+        }
         setlinfoUpld.setBillNo(billNo);
         setlinfoUpld.setBillCode("143001913350");
         setlinfoUpld.setBizSn(SnowFlakeId.instance().nextId());