This commit is contained in:
鲨鱼
2024-12-07 17:17:00 +08:00
parent e5d2638162
commit 4bcf4321e5
5 changed files with 30 additions and 9 deletions

View File

@@ -55,14 +55,14 @@ public class PayTrdConfigServiceImpl extends ServiceImpl<PayTrdConfigMapper, Pay
}
if(typeEnum == TrdPayTypeEnum.V1){ // V1
if(!"SUCCESS".equals(jsonObject.getString("retCode"))){
log.info("第三方支付失败 V1统一支付失败失败 dto={}, payTrdConfig={}, typeEnum={}", JSON.toJSONString(dto), JSON.toJSONString(payTrdConfig),JSON.toJSONString(typeEnum));
log.info("第三方支付失败 V1统一支付失败失败 dto={}, payTrdConfig={}, typeEnum={}", JSON.toJSONString(dto), JSON.toJSONString(payTrdConfig),JSON.toJSONString(jsonObject));
throw new ServiceException("调用支付失败");
}
String payUrl = jsonObject.getJSONObject("payParams").getString("payUrl");
return PayReturnResp.createH5(payUrl);
}else if(typeEnum == TrdPayTypeEnum.V2){
if(!"0".equals(jsonObject.getString("retCode"))){
log.info("第三方支付失败 V2统一支付失败失败 dto={}, payTrdConfig={}, typeEnum={}", JSON.toJSONString(dto), JSON.toJSONString(payTrdConfig),JSON.toJSONString(typeEnum));
log.info("第三方支付失败 V2统一支付失败失败 dto={}, payTrdConfig={}, typeEnum={}", JSON.toJSONString(dto), JSON.toJSONString(payTrdConfig),JSON.toJSONString(jsonObject));
throw new ServiceException("调用支付失败");
}
String payMethod = jsonObject.getString("payMethod");