Commit 1835b5d9 authored by jiaorz's avatar jiaorz

支付宝预授权转支付退款接口

parent e70f0191
...@@ -647,7 +647,7 @@ public class OrderPayBiz extends BaseBiz<OrderPayMapper, OrderPay>{ ...@@ -647,7 +647,7 @@ public class OrderPayBiz extends BaseBiz<OrderPayMapper, OrderPay>{
* @param refundReason 退款原因 * @param refundReason 退款原因
* @param outRequestNo 退款标志号 * @param outRequestNo 退款标志号
*/ */
public void testTradeRefund(String tradNo, Integer refundAmount, String refundReason, String outRequestNo) { public AlipayTradeRefundResponse testTradeRefund(String tradNo, Integer refundAmount, String refundReason, String outRequestNo) {
AlipayClient alipayClient = getAlipayClient(); AlipayClient alipayClient = getAlipayClient();
AlipayTradeRefundModel model = new AlipayTradeRefundModel(); AlipayTradeRefundModel model = new AlipayTradeRefundModel();
BigDecimal realAmount = new BigDecimal(refundAmount.toString()).divide(new BigDecimal("100"), 2, BigDecimal.ROUND_UP); BigDecimal realAmount = new BigDecimal(refundAmount.toString()).divide(new BigDecimal("100"), 2, BigDecimal.ROUND_UP);
...@@ -664,6 +664,7 @@ public class OrderPayBiz extends BaseBiz<OrderPayMapper, OrderPay>{ ...@@ -664,6 +664,7 @@ public class OrderPayBiz extends BaseBiz<OrderPayMapper, OrderPay>{
e.printStackTrace(); e.printStackTrace();
} }
log.info("response: {}"+response.getBody()); log.info("response: {}"+response.getBody());
return response;
} }
public static void main(String[] args) throws AlipayApiException { public static void main(String[] args) throws AlipayApiException {
OrderPayBiz orderPayBiz = new OrderPayBiz(); OrderPayBiz orderPayBiz = new OrderPayBiz();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment