|
@@ -31,6 +31,7 @@ import org.redisson.api.RedissonClient;
|
|
|
import org.slf4j.Logger;
|
|
|
import org.slf4j.LoggerFactory;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.beans.factory.annotation.Value;
|
|
|
import org.springframework.http.HttpStatus;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
|
@@ -68,6 +69,9 @@ public class PaymentController extends BaseController {
|
|
|
@Autowired
|
|
|
private RedissonClient redissonClient;
|
|
|
|
|
|
+ @Value("${message.debugMode}")
|
|
|
+ private boolean debugMode;
|
|
|
+
|
|
|
@ApiOperation(value = "订单付款")
|
|
|
@PostMapping("/orderPay")
|
|
|
public HttpResponseResult<OrderPayRes> orderPay(@Valid @RequestBody OrderPayReq payReq, HttpServletRequest request) {
|
|
@@ -144,6 +148,9 @@ public class PaymentController extends BaseController {
|
|
|
@PathVariable("payMethod") String payMethod,
|
|
|
HttpServletRequest request
|
|
|
) {
|
|
|
+ if (debugMode) {
|
|
|
+ return null;
|
|
|
+ }
|
|
|
BaseResult<PaymentCallBack> res = paymentClient.analysisNotice(
|
|
|
OpenEnum.valueOf(openType), PaymentClientEnum.valueOf(client),
|
|
|
PayChannelEnum.valueOf(payChannel), MethodNameEnum.valueOf(payMethod), request);
|