|
|
|
@@ -1,5 +1,6 @@ |
|
|
|
package com.iformall.service.pay.service.cashout.wx; |
|
|
|
|
|
|
|
import java.io.UnsupportedEncodingException; |
|
|
|
import java.util.ArrayList; |
|
|
|
import java.util.List; |
|
|
|
import java.util.Map; |
|
|
|
@@ -223,7 +224,7 @@ public class WxCashOutAdapterService implements CashOutAdapterService{ |
|
|
|
response = WxPay.merchantTranferChange(payService,generateWxCashOutPV3(payAccount, appInfo, cashOut)); |
|
|
|
} catch (Exception e) { |
|
|
|
log.error("零钱支付异常: " + e.getMessage(),e); |
|
|
|
return new CashOutAdapterResult(false, EnumCashOutStatus.FAIL.getCode(), "微信零钱支付接口调用异常."+e.getMessage(), null); |
|
|
|
return new CashOutAdapterResult(false, EnumCashOutStatus.FAIL.getCode(), "微信零钱支付接口调用异常:"+e.getMessage(), null); |
|
|
|
} |
|
|
|
log.info("微信零钱支付:, response: " + response.toString()); |
|
|
|
return generateResult(response,cashOut); |
|
|
|
@@ -237,8 +238,14 @@ public class WxCashOutAdapterService implements CashOutAdapterService{ |
|
|
|
WxCashOutPV3 wxCashOutPv3 = new WxCashOutPV3(); |
|
|
|
wxCashOutPv3.setAppid(appInfo.getAppId()); |
|
|
|
wxCashOutPv3.setOut_batch_no(String.valueOf(cashOut.getId())); |
|
|
|
wxCashOutPv3.setBatch_name(cashOut.getMerchantName()+"提现"); |
|
|
|
wxCashOutPv3.setBatch_remark("提现编号:"+cashOut.getId()); |
|
|
|
|
|
|
|
StringBuffer bn = new StringBuffer(cashOut.getMerchantName()).append("提现"); |
|
|
|
try { |
|
|
|
wxCashOutPv3.setBatch_name(new String(bn.toString().getBytes("ISO-8859-1"), "UTF-8")); |
|
|
|
} catch (UnsupportedEncodingException e) { |
|
|
|
wxCashOutPv3.setBatch_name("tixian"); |
|
|
|
} |
|
|
|
wxCashOutPv3.setBatch_remark("From FM WxMiniApp"); |
|
|
|
wxCashOutPv3.setTotal_amount(cashOut.getTotalFee()); |
|
|
|
wxCashOutPv3.setTotal_num(1); |
|
|
|
List<WxCashOutPV3Item> itemList = new ArrayList<WxCashOutPV3Item>(); |
|
|
|
@@ -246,7 +253,7 @@ public class WxCashOutAdapterService implements CashOutAdapterService{ |
|
|
|
item.setOut_detail_no(Utility.generate32UUID()); |
|
|
|
item.setOpenid(cashOut.getReciveOpenId()); |
|
|
|
item.setTransfer_amount(cashOut.getTotalFee()); |
|
|
|
item.setTransfer_remark(cashOut.getMerchantName()+"提现"); |
|
|
|
item.setTransfer_remark("From FM WxMiniApp Tranfer."); |
|
|
|
item.setUser_name(cashOut.getRealName()); |
|
|
|
itemList.add(item); |
|
|
|
wxCashOutPv3.setTransfer_detail_list(itemList); |
|
|
|
|