feat 适配支付宝支付

This commit is contained in:
damonyuan 2024-10-22 00:53:10 +08:00
parent 56f0b88c7c
commit d319816a17
2 changed files with 3 additions and 5 deletions

View File

@ -172,7 +172,7 @@ public class ConfigUtils {
DevPayConfigMapper model = SpringUtils.getBean(DevPayConfigMapper.class); DevPayConfigMapper model = SpringUtils.getBean(DevPayConfigMapper.class);
DevPayConfig devPay = model.selectOne( DevPayConfig devPay = model.selectOne(
new QueryWrapper<DevPayConfig>() new QueryWrapper<DevPayConfig>()
.eq("way", PaymentEnum.ALI_PAY.getCode())); .eq("pay_way", PaymentEnum.ALI_PAY.getCode()));
if (StringUtils.isNull(devPay)) { if (StringUtils.isNull(devPay)) {
return ""; return "";
} else { } else {

View File

@ -202,7 +202,7 @@ public class PayServiceImpl implements IPayService {
return this.createAliH5Order(params); return this.createAliH5Order(params);
} }
} catch (Exception e) { } catch (Exception e) {
throw new PaymentException(e.getMessage()); throw new OperateException(e.toString());
} }
throw new PaymentException("支付发起异常"); throw new PaymentException("支付发起异常");
@ -290,8 +290,6 @@ public class PayServiceImpl implements IPayService {
return ret; return ret;
} catch (Exception e) { } catch (Exception e) {
throw new PaymentException(e.getMessage()); throw new PaymentException(e.getMessage());
//throw new OperateException(e.getMessage());
} }
} else { } else {
AlipayTradePagePayRequest alipayRequest = new AlipayTradePagePayRequest(); AlipayTradePagePayRequest alipayRequest = new AlipayTradePagePayRequest();
@ -306,7 +304,7 @@ public class PayServiceImpl implements IPayService {
ret.put("pay_way", params.getPayWay()); ret.put("pay_way", params.getPayWay());
return ret; return ret;
} catch (Exception e) { } catch (Exception e) {
throw new PaymentException(e.getMessage()); throw new OperateException(e.getMessage());
} }
} }
} }