33333333333

This commit is contained in:
777
2025-01-13 20:41:15 +08:00
parent d270c49bce
commit 7db1c286a6
4 changed files with 51 additions and 10 deletions

View File

@@ -304,12 +304,33 @@ public class PayController {
}
}
@GetMapping(value = "/trd/notify/v8")
@Operation(hidden = true)
@Log(title = "第三方支付回调V8", businessType = BusinessType.OTHER, isSaveDb = false)
@SaIgnore
public String trdNotifyUrlV8(HttpServletRequest request) {
try {
TrdPayTypeEnum trdPayTypeEnum = TrdPayTypeEnum.V8;
Map<String, String> params = AliPayApi.toMap(request);
log.info("收到第三方支付回调 {}:{}",trdPayTypeEnum.name(), JSON.toJSONString(params));
NotifyResp notifyResp = trdPayManager.getNotifyResp(params, trdPayTypeEnum);
if(!notifyResp.isSuccess()){
return "failure";
}
payManager.callBack(notifyResp.getOrderNo(),notifyResp.getTrdOrderNo(),params,notifyResp.getPayTypeEnum().name(), PayTypeEnum.TRD);
return trdPayTypeEnum.getNotifyResp();
} catch (Exception e) {
log.error("第三方支付回调失败! V8", e);
return "failure";
}
}
@PostMapping(value = "/trd/notify/{type}")
@Operation(hidden = true)
@Log(title = "第三方支付回调", businessType = BusinessType.OTHER, isSaveDb = false)
@SaIgnore
public String trdNotifyUrlV1(HttpServletRequest request,@PathVariable("type") String type) {
public String trdNotifyUrl(HttpServletRequest request,@PathVariable("type") String type) {
try {
if(type == null){
log.error("收到第三方支付回调,支付类型为空");