Sfoglia il codice sorgente

2206A和取消费用上传

lighter 3 giorni fa
parent
commit
893504c755

+ 3 - 3
src/main/java/thyyxxk/simzfeeoprnsystm/dao/SiMzDao.java

@@ -169,9 +169,6 @@ public interface SiMzDao {
             "and b.si_caty=c.code")
     MzVisit selectMzVisitInfo(String patNo, int times);
 
-    @Select("select rtrim(dept_code) from a_employee_mi where code=#{code} and isnull(del_flag, '0')!='1'")
-    String selectStaffDepartment(String code);
-
     @Select("select his_item_code from t_mt_receipt where patient_id=#{patNo} and times=#{times}")
     List<String> selectHisChargeCodes(String patNo, int times);
 
@@ -193,4 +190,7 @@ public interface SiMzDao {
 
     @Select("select count(1) from mz_order_lock where his_order_num=#{id} and lock_flag=1 and ybzf=1")
     int getLockedCount(String id);
+
+    @Select("select count(1) from t_mt_receipt where patient_id=#{patNo} and times=#{times}")
+    int getUpldfCnt(String patNo, int times);
 }

+ 1 - 1
src/main/java/thyyxxk/simzfeeoprnsystm/dicts/SiFunction.java

@@ -41,7 +41,7 @@ public enum SiFunction {
     /**
      * 通过此交易进行门诊结算的预结算(门诊预结算)
      */
-    OUTPATIENT_PRE_SETTLEMENT("2206"),
+    OUTPATIENT_PRE_SETTLEMENT("2206A"),
 
     /**
      * 通过此交易进行门诊结算的正式结算(门诊结算)

+ 4 - 0
src/main/java/thyyxxk/simzfeeoprnsystm/pojo/MzPatientInfo.java

@@ -79,4 +79,8 @@ public class MzPatientInfo {
     public String getBalc() {
         return StringUtil.isBlank(balc) ? "0" : balc;
     }
+
+    public String getExpContent() {
+        return StringUtil.isBlank(expContent) ? "{}" : expContent;
+    }
 }

+ 9 - 0
src/main/java/thyyxxk/simzfeeoprnsystm/service/SiMzFeeService.java

@@ -196,6 +196,15 @@ public class SiMzFeeService {
     }
 
     public ResultVo<String> executeOutpatientRegRevoke(RevokeRegRequest request) {
+        int upldfCnt = mzDao.getUpldfCnt(request.getPatNo(), request.getTimes());
+        if (upldfCnt > 0) {
+            MzPatientInfo ptnt = new MzPatientInfo();
+            ptnt.setPatNo(request.getPatNo());
+            ptnt.setTimes(request.getTimes());
+            ptnt.setStaffId(request.getStaffId());
+            revokeOutpatientFeeDetails(ptnt);
+        }
+
         JSONObject input = exec.makeTradeHeaderWithInsureArea(SiFunction.REVOKE_OUTPATIENT_REGISTRATION,
                 request.getInsuplcAdmdvs(), request.getStaffId());
         JSONObject data = new JSONObject();