|
@@ -550,9 +550,17 @@ public class MedicalViewApiController {
|
|
|
map.put("medInsAmt", BigDecimal.ZERO);
|
|
|
map.put("selfAmt", totalAmount);
|
|
|
map.put("priceTime", DateUtil.fomart(mzChargeDetail.getPriceTime(), "yyyy-MM-dd HH:mm:ss"));
|
|
|
- map.put("patientId", mzChargeDetail.getPatientId());
|
|
|
- map.put("times", mzChargeDetail.getTimes());
|
|
|
- map.put("receiptNo", mzChargeDetail.getReceiptNo());
|
|
|
+ //不是医保查询的时候调用,需要查询是否有医保报销信息
|
|
|
+ if(haicipat.getYbRequest()==null || !YesNoEnum.YES.code.equals(haicipat.getYbRequest())){
|
|
|
+ PayInfo payInfo = tsmzService.uploadFees(whiteList.getOpId(), mzChargeDetail.getPatientId(), mzChargeDetail.getTimes(), mzChargeDetail.getReceiptNo());
|
|
|
+ if (payInfo != null && payInfo.getCode() == 0) {
|
|
|
+ //个人医保账户支付
|
|
|
+ map.put("acctPay", payInfo.getAcctPay());
|
|
|
+ //医保统筹报销
|
|
|
+ map.put("fundPay", payInfo.getFundPay());
|
|
|
+ map.put("selfAmt", mzChargeDetail.getAmount().subtract(payInfo.getAcctPay()).subtract(payInfo.getFundPay()).multiply(BigDecimal.valueOf(100)));
|
|
|
+ }
|
|
|
+ }
|
|
|
returnList.add(map);
|
|
|
}
|
|
|
results.put("resultCode", 0);
|
|
@@ -569,41 +577,6 @@ public class MedicalViewApiController {
|
|
|
}
|
|
|
|
|
|
|
|
|
- /**
|
|
|
- * 门诊待缴费记录查询(支持门诊统筹报销)
|
|
|
- *
|
|
|
- * @param haicipat
|
|
|
- * @return
|
|
|
- */
|
|
|
- @RequestMapping(value = "/getMzChargeDetailForUnPaidForMztc", method = {RequestMethod.POST})
|
|
|
- public Map<String, Object> getMzChargeDetailForUnPaidForMztc(@RequestBody Haicipat haicipat, HttpServletRequest httpServletRequest) {
|
|
|
- Map<String, Object> results = getMzChargeDetailForUnPaid(haicipat, httpServletRequest);
|
|
|
- String ip = HttpUtil.getIPAddress(httpServletRequest);
|
|
|
- WhiteList whiteList = whiteListService.queryByIpAddress(ip);
|
|
|
- if (whiteList == null) {
|
|
|
- results.put("resultCode", -1);
|
|
|
- results.put("resultMessage", "当前请求来源未在白名单中【" + ip + "】");
|
|
|
- return results;
|
|
|
- }
|
|
|
- if ((Integer) results.get("resultCode") == 0) {
|
|
|
- List<Map<String, Object>> returnList = (List<Map<String, Object>>) results.get("data");
|
|
|
- if (returnList != null && returnList.size() > 0) {
|
|
|
- for (Map<String, Object> map : returnList) {
|
|
|
- PayInfo payInfo = tsmzService.uploadFees(whiteList.getOpId(), (String) map.get("patientId"), (Integer) map.get("times"), (Integer) map.get("receiptNo"));
|
|
|
- if (payInfo != null && payInfo.getCode() == 0) {
|
|
|
- BigDecimal totalAmt = (BigDecimal) map.get("totalAmt");
|
|
|
- //个人医保账户支付
|
|
|
- map.put("acctPay", payInfo.getAcctPay());
|
|
|
- //医保统筹报销
|
|
|
- map.put("fundPay", payInfo.getFundPay());
|
|
|
- map.put("selfAmt", totalAmt.divide(BigDecimal.valueOf(100)).subtract(payInfo.getAcctPay()).subtract(payInfo.getFundPay()).multiply(BigDecimal.valueOf(100)));
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- return results;
|
|
|
- }
|
|
|
-
|
|
|
|
|
|
/**
|
|
|
* 门诊待缴费记录明细查询
|