Browse Source

医保结算单添加票据号码。

xiaochan 3 years ago
parent
commit
fe835a6178

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

@@ -159,6 +159,11 @@ public interface UpIdCollectionDao {
     List<OprninfoUpld> oprninfoUplds(@Param("patNo") String patNo,
                                      @Param("times") Integer times);
 
+    @Select("select receipt_no from zy_receipt where inpatient_no=#{patNo} and admiss_times=#{times} and ledger_sn=#{ledgerSn} and receipt_no<>'0000000'" +
+            "and receipt_sn = 1")
+    String billNo(@Param("patNo") String patNo,
+                  @Param("times") Integer times,
+                  @Param("ledgerSn") Integer ledgerSn);
 
     // 基金支付信息
     @Select("select fund_pay_type,fund_payamt=cast(fund_payamt as decimal(16,2)) from t_si_setldetail " +

+ 1 - 0
src/main/java/thyyxxk/webserver/service/medicalinsurance/SiManageService.java

@@ -343,6 +343,7 @@ public class SiManageService {
         setlinfoUpld.setMedinsFillDept(getDropdownBox.getDeptName());
         // 医保机构经办人
         setlinfoUpld.setHsorgOpter("未知");
+        setlinfoUpld.setBillNo(upIdCollectionDao.billNo(patNo, times, ledgerSn));
         List<OprninfoUpld> oprninfoUpld = upIdCollectionDao.oprninfoUplds(patNo, times);
 
         if (ListUtil.notBlank(oprninfoUpld)) {