|
@@ -2,17 +2,15 @@ package org.springblade.gateway.common_gateway.controller;
|
|
|
|
|
|
|
|
import io.swagger.annotations.Api;
|
|
import io.swagger.annotations.Api;
|
|
|
import io.swagger.annotations.ApiOperation;
|
|
import io.swagger.annotations.ApiOperation;
|
|
|
-import org.springblade.common.enums.PaymentScene;
|
|
|
|
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
import org.springblade.common.enums.PaymentType;
|
|
import org.springblade.common.enums.PaymentType;
|
|
|
import org.springblade.common.enums.ResCode;
|
|
import org.springblade.common.enums.ResCode;
|
|
|
import org.springblade.common.enums.WithdrawType;
|
|
import org.springblade.common.enums.WithdrawType;
|
|
|
import org.springblade.core.log.exception.ServiceException;
|
|
import org.springblade.core.log.exception.ServiceException;
|
|
|
import org.springblade.core.tool.api.R;
|
|
import org.springblade.core.tool.api.R;
|
|
|
import org.springblade.payment.entity.PayParam;
|
|
import org.springblade.payment.entity.PayParam;
|
|
|
-import org.springblade.payment.plugin.Payment;
|
|
|
|
|
import org.springblade.payment.plugin.PaymentBuilder;
|
|
import org.springblade.payment.plugin.PaymentBuilder;
|
|
|
import org.springblade.payment.plugin.Withdraw;
|
|
import org.springblade.payment.plugin.Withdraw;
|
|
|
-import org.springblade.payment.plugin.WithdrawPlugin;
|
|
|
|
|
import org.springblade.yeePay.service.YeePayService;
|
|
import org.springblade.yeePay.service.YeePayService;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.validation.annotation.Validated;
|
|
import org.springframework.validation.annotation.Validated;
|
|
@@ -26,6 +24,7 @@ import java.util.Optional;
|
|
|
* @Description 提现模式
|
|
* @Description 提现模式
|
|
|
* @Date 2021/10/22 16:23
|
|
* @Date 2021/10/22 16:23
|
|
|
*/
|
|
*/
|
|
|
|
|
+@Slf4j
|
|
|
@Api(tags = "提现模块")
|
|
@Api(tags = "提现模块")
|
|
|
@RestController
|
|
@RestController
|
|
|
@RequestMapping("/withdraw")
|
|
@RequestMapping("/withdraw")
|
|
@@ -66,6 +65,7 @@ public class WithdrawController {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
private Withdraw pluginBuild(String paymentType) {
|
|
private Withdraw pluginBuild(String paymentType) {
|
|
|
|
|
+ log.info("PaymentType枚举值:{}", PaymentType.values());
|
|
|
return paymentBuilder.fetchWithdrawPlugin(
|
|
return paymentBuilder.fetchWithdrawPlugin(
|
|
|
Optional.of(PaymentType.valueOf(paymentType))
|
|
Optional.of(PaymentType.valueOf(paymentType))
|
|
|
.orElseThrow(() -> new ServiceException(ResCode.PAY_TYPE_ERROR))
|
|
.orElseThrow(() -> new ServiceException(ResCode.PAY_TYPE_ERROR))
|