feat 去除支付发起时的NotReturn属性,SQL脚本更新,部署调试

This commit is contained in:
bootx
2024-02-13 20:51:19 +08:00
parent 5ff2c5c389
commit ed03a55811
26 changed files with 3076 additions and 5652 deletions

View File

@@ -3,9 +3,7 @@ package cn.bootx.platform.daxpay.sdk.net;
import cn.bootx.platform.daxpay.sdk.code.SignTypeEnum;
import cn.bootx.platform.daxpay.sdk.response.DaxPayResult;
import cn.bootx.platform.daxpay.sdk.util.PaySignUtil;
import cn.hutool.http.ContentType;
import cn.hutool.http.HttpResponse;
import cn.hutool.http.HttpUtil;
import cn.hutool.http.*;
import cn.hutool.json.JSONUtil;
import lombok.experimental.UtilityClass;
import lombok.extern.slf4j.Slf4j;
@@ -63,7 +61,13 @@ public class DaxPayKit {
.body(data, ContentType.JSON.getValue())
.timeout(config.getReqTimeout())
.execute();
// 响应码只有200 才可以进行支付
if (execute.getStatus() != HttpStatus.HTTP_OK){
throw new HttpException("请求失败,请排查配置的支付网关地址是否正常");
}
String body = execute.body();
log.debug("响应参数:{}", body);
return request.toModel(body);
}

View File

@@ -42,10 +42,10 @@ public class PayParam extends DaxPayRequest<PayOrderModel> {
/** 商户扩展参数,回调时会原样返回 */
private String attach;
/** 是否不进行同步通知的跳转 */
private boolean notReturn;
/** 同步跳转URL, 部分接口不支持该配置,传输了也不会生效 */
/**
* 同步跳转URL, 不传输跳转到默认地址.
* 部分接口不支持该配置,传输了也不会生效
*/
private String returnUrl;
/** 是否不启用异步通知 */

View File

@@ -74,9 +74,6 @@ public class SimplePayParam extends DaxPayRequest<PayOrderModel> {
/** 商户扩展参数,回调时会原样返回 */
private String attach;
/** 是否不进行同步通知的跳转 */
private boolean notReturn;
/** 同步跳转URL, 部分接口不支持该配置,传输了也不会生效 */
private String returnUrl;

View File

@@ -26,9 +26,6 @@ public class QueryRefundOrderParam extends DaxPayRequest<QueryRefundOrderModel>
/** 商户扩展参数,回调时会原样返回 */
private String attach;
/** 是否不进行同步通知的跳转 */
private boolean notReturn;
/** 同步跳转URL, 部分接口不支持该配置,传输了也不会生效 */
private String returnUrl;

View File

@@ -40,7 +40,6 @@ public class PayOrderTest {
PayParam param = new PayParam();
param.setClientIp("127.0.0.1");
param.setNotNotify(true);
param.setNotReturn(true);
param.setBusinessNo("P0001");
param.setTitle("测试接口支付");

View File

@@ -38,7 +38,6 @@ public class SimplePayOrderTest {
param.setPayWay(PayWayEnum.QRCODE.getCode());
param.setClientIp("127.0.0.1");
param.setNotNotify(true);
param.setNotReturn(true);
DaxPayResult<PayOrderModel> execute = DaxPayKit.execute(param);
System.out.println(execute);

View File

@@ -29,7 +29,6 @@ public class PayParamSignTest {
PayParam param = new PayParam();
param.setClientIp("127.0.0.1");
param.setNotNotify(true);
param.setNotReturn(true);
param.setBusinessNo("P0001");
param.setTitle("测试接口支付");