|
|
@ -1,6 +1,7 @@ |
|
|
|
package org.jeecg.modules.userCode.controller; |
|
|
|
|
|
|
|
import com.alibaba.fastjson.JSONObject; |
|
|
|
import io.swagger.annotations.Api; |
|
|
|
import io.swagger.annotations.ApiOperation; |
|
|
|
import lombok.extern.slf4j.Slf4j; |
|
|
|
import org.jeecg.common.api.vo.Result; |
|
|
@ -32,6 +33,7 @@ import java.util.concurrent.TimeUnit; |
|
|
|
@Slf4j |
|
|
|
@RestController |
|
|
|
@RequestMapping("/pay") |
|
|
|
@Api(tags = "付款相关接口") |
|
|
|
public class PayController { |
|
|
|
|
|
|
|
@Resource |
|
|
@ -55,6 +57,7 @@ public class PayController { |
|
|
|
* @param token |
|
|
|
* @return |
|
|
|
*/ |
|
|
|
@ApiOperation("订单支付") |
|
|
|
@PostMapping("/order") |
|
|
|
public Result<?> orderPay(@RequestBody OrderPayReq req, @RequestHeader("X-Access-Token") String token) { |
|
|
|
Result<?> result = payService.orderPay(req, token); |
|
|
@ -64,6 +67,22 @@ public class PayController { |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** |
|
|
|
* 订单支付 |
|
|
|
* |
|
|
|
* @param req |
|
|
|
* @param token |
|
|
|
* @return |
|
|
|
*/ |
|
|
|
@ApiOperation("订单保险支付") |
|
|
|
@PostMapping("/orderPremiumPay") |
|
|
|
public Result<?> orderPremiumPay(@RequestBody OrderPayReq req, @RequestHeader("X-Access-Token") String token) { |
|
|
|
Result<?> result = payService.orderPremiumPay(req, token); |
|
|
|
log.warn("支付结果{}", JSONObject.toJSONString(result)); |
|
|
|
return result; |
|
|
|
} |
|
|
|
|
|
|
|
/** |
|
|
|
* 支付回调 |
|
|
|
* |
|
|
@ -89,6 +108,7 @@ public class PayController { |
|
|
|
* @param token |
|
|
|
* @return |
|
|
|
*/ |
|
|
|
@ApiOperation("充值支付") |
|
|
|
@PostMapping("/payRecharge") |
|
|
|
public Result<?> payRecharge(@RequestBody RechargeReq rechargeReq, @RequestHeader("X-Access-Token") String token) { |
|
|
|
|
|
|
|