Browse Source

分配转移健管师

wujunjie 7 years ago
parent
commit
2f425bef09

+ 13 - 17
patient-co-wlyy/src/main/java/com/yihu/wlyy/web/wx/OnePayController.java

@ -54,8 +54,8 @@ public class OnePayController extends WeixinBaseController {
    public String expensesStatus() throws Exception {
        try {
            //            获取居民个人信息  要根据签约code去查找签约扣费状态
//            String userCode = getUID();
            String userCode = "915cc456-5b1d-11e6-8344-fa163e8aee56";
            String userCode = getUID();
//            String userCode = "915cc456-5b1d-11e6-8344-fa163e8aee56";
            SignFamily signFamily = signFamilyDao.findPatientExpensesStatus(userCode);
            String expensesStatus = signFamily.getExpensesStatus();
            if ("0".equals(expensesStatus)){
@ -78,18 +78,17 @@ public class OnePayController extends WeixinBaseController {
    public String bindCard() throws Exception {
        try {
            //            获取居民个人信息
           /* String userCode = getUID();
            Patient patient = patientDao.findByCode(userCode);
            String openId = patient.getOpenid();
            String userCode = getUID();
            String openId = getOpenid();
            if (StringUtils.isNotEmpty(openId)) {
                BindCard bindCard = pay.bindCard(userCode, openId);
                return write(200, "查询绑卡信息成功!", "data", bindCard);
            } else {
                return write(-1, "openId为空!");
            }*/
            BindCard bindCard = pay.bindCard("915cc456-5b1d-11e6-8344-fa163e8aee56","o4Ma2t5665rS7uNfA9EF-VnOJx30");         //ohNH9sh4uwuJCxIwcLJtGTX-BaSk  //o4Ma2t5665rS7uNfA9EF-VnOJx30      getUID()getOpenid()
            }
//            BindCard bindCard = pay.bindCard("915cc456-5b1d-11e6-8344-fa163e8aee56","o4Ma2t5665rS7uNfA9EF-VnOJx30");         //ohNH9sh4uwuJCxIwcLJtGTX-BaSk  //o4Ma2t5665rS7uNfA9EF-VnOJx30      getUID()getOpenid()
//            BindCard bindCard = pay.bindCard("915cc456-5b1d-11e6-8344-fa163e8aee56","ohNH9sh4uwuJCxIwcLJtGTX-BaSk");         //ohNH9sh4uwuJCxIwcLJtGTX-BaSk  //o4Ma2t5665rS7uNfA9EF-VnOJx30      getUID()getOpenid()
            return write(200, "查询绑卡信息成功!","data",bindCard);
//            return write(200, "查询绑卡信息成功!","data",bindCard);
        } catch (Exception e) {
            return error(-1, e.getMessage());
@ -116,9 +115,8 @@ public class OnePayController extends WeixinBaseController {
            @RequestParam String feeDetail) throws Exception {
        try {
            //            获取居民个人信息
            /*String userCode = getUID();
            Patient patient = patientDao.findByCode(userCode);
            String openId = patient.getOpenid();
            String userCode = getUID();
            String openId = getOpenid();
            if (StringUtils.isNotEmpty(openId)) {
                String settleNo = pay.charge(orgCode, chargeType, chargeRelation, totalAmount, selfpayAmount, insuranceAmount, feeDetail, userCode, openId);  //ohNH9sh4uwuJCxIwcLJtGTX-BaSk    getUID(),getOpenid()
//            更新签约表的缴费状态(begin字段),表示签约正式开始
@ -126,10 +124,10 @@ public class OnePayController extends WeixinBaseController {
                return write(200, "家庭医生签约支付成功!", "data", settleNo);
            } else {
                return write(-1, "openId为空!");
            }*/
            String settleNo = pay.charge(orgCode, chargeType, chargeRelation, totalAmount, selfpayAmount, insuranceAmount, feeDetail, "915cc456-5b1d-11e6-8344-fa163e8aee56", "o4Ma2t5665rS7uNfA9EF-VnOJx30");  //ohNH9sh4uwuJCxIwcLJtGTX-BaSk    getUID(),getOpenid()
            }
//            String settleNo = pay.charge(orgCode, chargeType, chargeRelation, totalAmount, selfpayAmount, insuranceAmount, feeDetail, "915cc456-5b1d-11e6-8344-fa163e8aee56", "o4Ma2t5665rS7uNfA9EF-VnOJx30");  //ohNH9sh4uwuJCxIwcLJtGTX-BaSk    getUID(),getOpenid()
//            String settleNo = pay.charge(orgCode, chargeType, chargeRelation, totalAmount, selfpayAmount, insuranceAmount, feeDetail, "915cc456-5b1d-11e6-8344-fa163e8aee56", "ohNH9sh4uwuJCxIwcLJtGTX-BaSk");  //ohNH9sh4uwuJCxIwcLJtGTX-BaSk    getUID(),getOpenid()
            return write(200, "家庭医生签约支付成功!", "data", settleNo);
//            return write(200, "家庭医生签约支付成功!", "data", settleNo);
        } catch (Exception e) {
            return error(-1, e.getMessage());
        }
@ -156,8 +154,7 @@ public class OnePayController extends WeixinBaseController {
        try {
            //            获取居民个人信息
            String userCode = getUID();
            Patient patient = patientDao.findByCode(userCode);
            String openId = patient.getOpenid();
            String openId = getOpenid();
            if (StringUtils.isNotEmpty(openId)) {
                String sicardUrl = pay.createSicard(userCode, openId);         //ohNH9sh4uwuJCxIwcLJtGTX-BaSk  //o4Ma2t5665rS7uNfA9EF-VnOJx30  getUID(),getOpenid()
                return write(200, "生成电子社保卡成功!", "data", sicardUrl);
@ -242,7 +239,6 @@ public class OnePayController extends WeixinBaseController {
        if (StringUtil.isEmpty(reqQueryString)) {
            throw new PayException("跳转参数为空");
        }
        Map<String, String> targetMap = null;
        try {