新版仿ok交易所-后端
1
zj
2025-07-10 f15406ac788fb4e17a630c4d48129943af89fb9c
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
package com.yami.trading.admin.controller.user;
 
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yami.trading.admin.model.UserSafewordApplyExamineModel;
import com.yami.trading.admin.model.UserSafewordApplyModel;
import com.yami.trading.bean.user.dto.UserSafewordApplyDto;
import com.yami.trading.common.constants.Constants;
import com.yami.trading.common.domain.Result;
import com.yami.trading.service.AwsS3OSSFileService;
import com.yami.trading.service.RealNameAuthRecordService;
import com.yami.trading.service.user.UserSafewordApplyService;
import com.yami.trading.sys.service.SysUserService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
 
import javax.validation.Valid;
 
@RestController
@RequestMapping("userSafewordApply")
@Api(tags = "资金密码人工重置")
public class UserSafewordApplyController {
 
 
 
 
    @Autowired
    UserSafewordApplyService userSafewordApplyService;
 
    @Autowired
    RealNameAuthRecordService realNameAuthRecordService;
 
 
    @Autowired
    SysUserService sysUserService;
 
    @Autowired
    AwsS3OSSFileService awsS3OSSFileService;
 
 
 
    @ApiOperation(value = "列表")
    @PostMapping("list")
    public Result<Page<UserSafewordApplyDto>> list(@RequestBody @Valid UserSafewordApplyModel request){
        Page<UserSafewordApplyDto> page=new Page(request.getCurrent(),request.getSize());
        userSafewordApplyService.listRecord(page,request.getRoleName(),
                request.getStatus(),request.getUserCode(),request.getUserName(),request.getOperate());
 
        for(UserSafewordApplyDto safewordApplyDto:page.getRecords()){
            safewordApplyDto.setIdcardPathFront(
                    Constants.IMAGES_HTTP+safewordApplyDto.getIdcardPathBack());
            safewordApplyDto.setIdcardPathBack(
                    Constants.IMAGES_HTTP+safewordApplyDto.getIdcardPathBack());
            safewordApplyDto.setIdcardPathHold(
                    Constants.IMAGES_HTTP+safewordApplyDto.getIdcardPathHold());
        }
        return  Result.ok(page);
    }
 
    @ApiOperation(value = "审核")
    @PostMapping("examine")
 
    public Result<?> examine(@RequestBody @Valid UserSafewordApplyExamineModel model){
        if (model.getType()==1){
            sysUserService.checkSafeWord(model.getLoginSafeword());
        }
        userSafewordApplyService.examine(model.getId(),model.getContent(),model.getType());
        return  Result.ok(null);
    }
}