MerchantStaffWithdrawalController.java
3.61 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
package cn.com.glsx.merchants.controller;
import cn.com.glsx.framework.core.exception.RpcServiceException;
import cn.com.glsx.framework.rop.response.RopResponse;
import cn.com.glsx.merchants.request.withdrawal.MerchantStaffWithdrawalSearchRopRequest;
import cn.com.glsx.merchants.request.withdrawal.MerchantStaffWithdrawalUpdateRopRequest;
import cn.com.glsx.merchants.response.withdrawal.MerchantStaffWithdrawalListRopResponse;
import cn.com.glsx.merchants.service.MerchantStaffWithdrawalService;
import cn.com.glsx.merchants.util.WithdrawalPagination;
import com.rop.annotation.NeedInSessionType;
import com.rop.annotation.ServiceMethod;
import com.rop.annotation.ServiceMethodBean;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
/**
* @ClassName MerchantStaffWithdrawalController
* @Description
* @Author lichongyuan
* @Date 2022/10/14
*/
@Slf4j
@Api("提现管理接口")
@ServiceMethodBean(version = "1.0.0", needInSession = NeedInSessionType.NO)
public class MerchantStaffWithdrawalController {
@Autowired
private MerchantStaffWithdrawalService merchantStaffWithdrawalService;
/**
* 提现列表
*/
/**
* 提现列表
*
* @param request 入参
* @return
*/
@ServiceMethod(method = "merchants.api.staff.withdrawal.page", needInSession = NeedInSessionType.NO)
@ApiOperation("提现列表")
public RopResponse<WithdrawalPagination<MerchantStaffWithdrawalListRopResponse>> getWithdrawalPage(MerchantStaffWithdrawalSearchRopRequest request) {
try {
WithdrawalPagination<MerchantStaffWithdrawalListRopResponse> withdrawalPage = merchantStaffWithdrawalService.getWithdrawalPage(request);
return RopResponse.success(withdrawalPage);
} catch (RpcServiceException e) {
log.info("=======MerchantStaffWithdrawalController__invoke__getWithdrawalPage__exception:{}", e.getMessage());
return RopResponse.error(e.getErrId(), e.getMessage());
}
}
/**
* 提现列表导出
*
* @param request 入参
* @return
*/
@ServiceMethod(method = "merchants.api.staff.withdrawal.exportList", needInSession = NeedInSessionType.NO)
@ApiOperation("提现列表导出")
public RopResponse<String> exportList(MerchantStaffWithdrawalSearchRopRequest request) {
try {
String url = merchantStaffWithdrawalService.exportList(request);
return RopResponse.success(url);
} catch (RpcServiceException e) {
log.info("=======MerchantStaffWithdrawalController__invoke__exportList__exception:{}", e.getMessage());
return RopResponse.error(e.getErrId(), e.getMessage());
}
}
/**
* 批量提现审核
*/
/**
* 批量提现审核
*
* @param request 入参
* @return
*/
@ServiceMethod(method = "merchants.api.staff.withdrawal.batchWithdrawal", needInSession = NeedInSessionType.NO)
@ApiOperation("批量提现审核")
public RopResponse<Boolean> batchWithdrawal(MerchantStaffWithdrawalUpdateRopRequest request) {
try {
merchantStaffWithdrawalService.batchWithdrawal(request);
return RopResponse.success(true);
} catch (RpcServiceException e) {
log.info("=======MerchantStaffWithdrawalController__invoke__batchWithdrawal__exception:{}", e.getMessage());
return RopResponse.error(e.getErrId(), e.getMessage());
}
}
}