mirror of
https://gitee.com/egzosn/pay-java-parent.git
synced 2026-06-08 10:24:03 +08:00
#I95DKC 商家转账到零钱 提示 HTTP header缺少微信支付平台证书序列号(Wechatpay-Serial)
#I95DSJ 微信支付:添加分账接收方, 提示 输入源“/body/relation_type”映射到字段“与分账方的关系类型”必填性规则校验失败,此字段为必填项"}
This commit is contained in:
@@ -15,6 +15,7 @@ import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import org.apache.http.HttpEntity;
|
||||
import org.apache.http.message.BasicHeader;
|
||||
|
||||
import static com.egzosn.pay.wx.api.WxConst.OUT_TRADE_NO;
|
||||
import static com.egzosn.pay.wx.api.WxConst.SANDBOXNEW;
|
||||
@@ -41,6 +42,7 @@ import com.egzosn.pay.common.bean.TransferOrder;
|
||||
import com.egzosn.pay.common.bean.result.PayException;
|
||||
import com.egzosn.pay.common.exception.PayErrorException;
|
||||
import com.egzosn.pay.common.http.HttpConfigStorage;
|
||||
import com.egzosn.pay.common.http.HttpStringEntity;
|
||||
import com.egzosn.pay.common.http.ResponseEntity;
|
||||
import com.egzosn.pay.common.http.UriVariables;
|
||||
import com.egzosn.pay.common.util.DateUtils;
|
||||
@@ -334,6 +336,18 @@ public class WxPayService extends BasePayService<WxPayConfigStorage> implements
|
||||
return RSA2.sign(content, privateKey, characterEncoding);
|
||||
}
|
||||
|
||||
/**
|
||||
* http 实体 钩子
|
||||
*
|
||||
* @param entity 实体
|
||||
* @return 返回处理后的实体
|
||||
*/
|
||||
@Override
|
||||
public HttpStringEntity hookHttpEntity(HttpStringEntity entity) {
|
||||
entity.addHeader(new BasicHeader(WxConst.WECHATPAY_SERIAL, payConfigStorage.getCertEnvironment().getPlatformSerialNumber()));
|
||||
return entity;
|
||||
}
|
||||
|
||||
/**
|
||||
* 将请求参数或者请求流转化为 Map
|
||||
*
|
||||
|
||||
@@ -120,17 +120,7 @@ public class WxProfitSharingService extends WxPayService implements ProfitSharin
|
||||
return getAssistService().doExecute(parameters, order);
|
||||
}
|
||||
|
||||
/**
|
||||
* http 实体 钩子
|
||||
*
|
||||
* @param entity 实体
|
||||
* @return 返回处理后的实体
|
||||
*/
|
||||
@Override
|
||||
public HttpStringEntity hookHttpEntity(HttpStringEntity entity) {
|
||||
entity.addHeader(new BasicHeader(WxConst.WECHATPAY_SERIAL, payConfigStorage.getCertEnvironment().getPlatformSerialNumber()));
|
||||
return entity;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 返回创建的订单信息
|
||||
|
||||
@@ -39,7 +39,7 @@ public final class WxConst {
|
||||
public static final String TYPE = "type";
|
||||
public static final String ACCOUNT = "account";
|
||||
public static final String NAME = "name";
|
||||
public static final String RELATION_TYPE = "relationType";
|
||||
public static final String RELATION_TYPE = "relation_type";
|
||||
public static final String CUSTOM_RELATION = "customRelation";
|
||||
public static final String DESCRIPTION = "description";
|
||||
public static final String BILL_DATE = "bill_date";
|
||||
|
||||
Reference in New Issue
Block a user