|
@@ -3,6 +3,7 @@ package com.github.binarywang.wxpay.service.impl; |
|
|
import com.github.binarywang.wxpay.bean.entpay.*; |
|
|
import com.github.binarywang.wxpay.bean.entpay.*; |
|
|
import com.github.binarywang.wxpay.bean.request.WxPayDefaultRequest; |
|
|
import com.github.binarywang.wxpay.bean.request.WxPayDefaultRequest; |
|
|
import com.github.binarywang.wxpay.bean.result.BaseWxPayResult; |
|
|
import com.github.binarywang.wxpay.bean.result.BaseWxPayResult; |
|
|
|
|
|
import com.github.binarywang.wxpay.constant.WxPayConstants; |
|
|
import com.github.binarywang.wxpay.exception.WxPayException; |
|
|
import com.github.binarywang.wxpay.exception.WxPayException; |
|
|
import com.github.binarywang.wxpay.service.EntPayService; |
|
|
import com.github.binarywang.wxpay.service.EntPayService; |
|
|
import com.github.binarywang.wxpay.service.WxPayService; |
|
|
import com.github.binarywang.wxpay.service.WxPayService; |
|
@@ -135,7 +136,7 @@ public class EntPayServiceImpl implements EntPayService { |
|
|
public EntPayRedpackResult sendEnterpriseRedpack(EntPayRedpackRequest request) throws WxPayException { |
|
|
public EntPayRedpackResult sendEnterpriseRedpack(EntPayRedpackRequest request) throws WxPayException { |
|
|
//企业微信签名,需要在请求签名之前 |
|
|
//企业微信签名,需要在请求签名之前 |
|
|
request.setNonceStr(String.valueOf(System.currentTimeMillis())); |
|
|
request.setNonceStr(String.valueOf(System.currentTimeMillis())); |
|
|
request.setWorkWxSign(SignUtils.createEntSign(request.getActName(),request.getMchBillNo(),request.getMchId(),request.getNonceStr(),request.getReOpenid(),request.getTotalAmount(),request.getWxAppId(),"Hcf-X_dzLeaTIyK33okGmODK8sLzc7kLrgkWXOAoMbE","MD5")); |
|
|
|
|
|
|
|
|
request.setWorkWxSign(SignUtils.createEntSign(request.getActName(), request.getMchBillNo(), request.getMchId(), request.getNonceStr(), request.getReOpenid(), request.getTotalAmount(), request.getWxAppId(), payService.getConfig().getEntPayKey(), WxPayConstants.SignType.MD5)); |
|
|
|
|
|
|
|
|
request.checkAndSign(this.payService.getConfig()); |
|
|
request.checkAndSign(this.payService.getConfig()); |
|
|
|
|
|
|
|
|