mirror of
https://codeup.aliyun.com/67c68d4e484ca2f0a13ac3c1/ydc/jsowell-charger-web.git
synced 2026-04-20 11:05:18 +08:00
汇付支付订单
This commit is contained in:
@@ -127,7 +127,7 @@ public class PayController extends BaseController {
|
||||
*/
|
||||
@PostMapping("/payOrder")
|
||||
public RestApiResponse<?> payOrder(HttpServletRequest request, @RequestBody PayOrderDTO dto) {
|
||||
logger.info("支付订单 param:{}", dto.toString());
|
||||
logger.info("wechatpay支付订单 param:{}", dto.toString());
|
||||
RestApiResponse<?> response;
|
||||
|
||||
// 支付订单加锁
|
||||
@@ -151,10 +151,10 @@ public class PayController extends BaseController {
|
||||
}
|
||||
response = new RestApiResponse<>(map);
|
||||
} catch (BusinessException e) {
|
||||
logger.warn("支付订单 warn param:{}", dto.toString(), e);
|
||||
logger.warn("wechatpay支付订单 warn param:{}", dto.toString(), e);
|
||||
response = new RestApiResponse<>(e.getCode(), e.getMessage());
|
||||
} catch (Exception e) {
|
||||
logger.error("支付订单 error param:{}", dto.toString(), e);
|
||||
logger.error("wechatpay支付订单 error param:{}", dto.toString(), e);
|
||||
response = new RestApiResponse<>(ReturnCodeEnum.CODE_ORDER_PAY_ERROR);
|
||||
} finally {
|
||||
// 支付订单解锁
|
||||
@@ -162,10 +162,17 @@ public class PayController extends BaseController {
|
||||
redisCache.unLock(lockKey);
|
||||
}
|
||||
}
|
||||
logger.info("支付订单 result:{}", JSONObject.toJSONString(response));
|
||||
logger.info("wechatpay支付订单 result:{}", JSONObject.toJSONString(response));
|
||||
return response;
|
||||
}
|
||||
|
||||
/**
|
||||
* 使用adapay支付订单
|
||||
* http://localhost:8080/uniapp/pay/payOrderWithAdapay
|
||||
* @param request
|
||||
* @param dto
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/payOrderWithAdapay")
|
||||
public RestApiResponse<?> payOrderWithAdapay(HttpServletRequest request, @RequestBody PayOrderDTO dto) {
|
||||
logger.info("adapay支付订单 param:{}", dto.toString());
|
||||
|
||||
Reference in New Issue
Block a user