#936 修复微信支付沙箱环境退款接口的请求地址

This commit is contained in:
Binary Wang 2019-03-03 10:29:17 +08:00
parent 5d7f69a984
commit 2887c1e47e

View File

@ -141,6 +141,10 @@ public abstract class BaseWxPayServiceImpl implements WxPayService {
request.checkAndSign(this.getConfig());
String url = this.getPayBaseUrl() + "/secapi/pay/refund";
if (this.getConfig().isUseSandboxEnv()) {
url = PAY_BASE_URL + "/sandboxnew/pay/refund";
}
String responseContent = this.post(url, request.toXML(), true);
WxPayRefundResult result = WxPayRefundResult.fromXML(responseContent);
result.checkResult(this, request.getSignType(), true);