|
@@ -41,6 +41,8 @@ public class DismissService {
|
|
|
private String siZyFeeUrl;
|
|
|
@Value("${si-injury-fee-url}")
|
|
|
private String siInjuryFeeUrl;
|
|
|
+ @Value("${rmHkUserApi}")
|
|
|
+ private String rmHkUserApi;
|
|
|
|
|
|
@Autowired
|
|
|
public DismissService(DismissDao dao, SiZySrvc zySrvc, SiInjuryFeeUpld injuryFeeUpld) {
|
|
@@ -428,9 +430,21 @@ public class DismissService {
|
|
|
exception.setMessage("更新住院状态失败。" + code);
|
|
|
throw new BizException(exception);
|
|
|
}
|
|
|
+ destructionUser(settleFee);
|
|
|
return "OK";
|
|
|
}
|
|
|
|
|
|
+ private void destructionUser(MedinsSettleFee settle) {
|
|
|
+ try {
|
|
|
+ JSONObject obj = new JSONObject();
|
|
|
+ obj.put("patNo", settle.getInpatientNo());
|
|
|
+ obj.put("times", settle.getAdmissTimes());
|
|
|
+ new RestTemplate().postForObject(rmHkUserApi, obj, String.class);
|
|
|
+ } catch (Exception e) {
|
|
|
+ log.error("删除患者门禁出错", e);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
private int writeReceiptTable(MedinsSettleFee indata) {
|
|
|
if (dao.beforeWriteReceiptTable(indata.getInpatientNo(), indata.getAdmissTimes(),
|
|
|
indata.getLedgerSn()) < 1) {
|