From 353cf91d3679e68d9b8c07652e4f7791d606dbd4 Mon Sep 17 00:00:00 2001
From: 无关风月 <443237572@qq.com>
Date: 星期五, 15 十一月 2024 15:14:39 +0800
Subject: [PATCH] 代码提交

---
 xinquan-modules/xinquan-user/src/main/java/com/xinquan/user/controller/client/ClientAppUserWithdrawController.java |   22 +++++++++++++++++-----
 1 files changed, 17 insertions(+), 5 deletions(-)

diff --git a/xinquan-modules/xinquan-user/src/main/java/com/xinquan/user/controller/client/ClientAppUserWithdrawController.java b/xinquan-modules/xinquan-user/src/main/java/com/xinquan/user/controller/client/ClientAppUserWithdrawController.java
index 939a292..85dd362 100644
--- a/xinquan-modules/xinquan-user/src/main/java/com/xinquan/user/controller/client/ClientAppUserWithdrawController.java
+++ b/xinquan-modules/xinquan-user/src/main/java/com/xinquan/user/controller/client/ClientAppUserWithdrawController.java
@@ -6,11 +6,13 @@
 import com.alibaba.nacos.common.utils.UuidUtils;
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.xinquan.common.core.constant.CacheConstants;
 import com.xinquan.common.core.domain.R;
 import com.xinquan.common.core.utils.WebUtils;
 import com.xinquan.common.core.utils.page.CollUtils;
 import com.xinquan.common.core.utils.page.PageDTO;
 import com.xinquan.common.log.enums.BusinessType;
+import com.xinquan.common.redis.service.RedisService;
 import com.xinquan.common.security.service.TokenService;
 import com.xinquan.course.api.domain.Course;
 import com.xinquan.order.api.domain.Order;
@@ -67,6 +69,8 @@
     private TokenService tokenService;
     @Resource
     private AppUserWalletRecordService appUserWalletRecordService;
+    @Autowired
+    private RedisService redisService;
 
     @PostMapping("/withdrawList")
     @ApiOperation(value = "提现列表-分页", tags = {"管理后台-提现管理"})
@@ -87,7 +91,7 @@
             wrapper.in(AppUserWithdraw::getAppUserId,collect);
         }
         if (courseDTO.getPaymentStatus()!=null && courseDTO.getPaymentStatus()==1){
-            wrapper.eq(AppUserWithdraw::getId,0);
+            wrapper.eq(AppUserWithdraw::getWithdrawStatus,0);
         }else if (courseDTO.getPaymentStatus()!=null &&(courseDTO.getPaymentStatus()==2 || courseDTO.getPaymentStatus()==3)){
             List<Integer> integers = new ArrayList<>();
             integers.add(1);
@@ -147,8 +151,8 @@
             String startTime =null;
             String endTime =null;
             String[] split = courseDTO.getTime().split(" - ");
-            startTime = split[0]+"00:00:00";
-            endTime = split[1]+"23:59:59";
+            startTime = split[0]+" 00:00:00";
+            endTime = split[1]+" 23:59:59";
             wrapper.between(AppUserWithdraw::getWithdrawTime,startTime,endTime);
         }
         List<AppUserWithdraw> list = withdrawService.list(wrapper);
@@ -237,8 +241,8 @@
             String startTime =null;
             String endTime =null;
             String[] split = courseDTO.getTime().split(" - ");
-            startTime = split[0]+"00:00:00";
-            endTime = split[1]+"23:59:59";
+            startTime = split[0]+" 00:00:00";
+            endTime = split[1]+" 23:59:59";
             wrapper.between(AppUserWithdraw::getWithdrawTime,startTime,endTime);
         }
         List<AppUserWithdraw> list = withdrawService.list(wrapper);
@@ -297,6 +301,14 @@
         Long userId = loginUser.getUserid();
 
         appUserWithdraw.setAppUserId(userId);
+//        Boolean flag = redisService.hasKey(CacheConstants.ADD_CARD_PHONE_CODE_PREFIX + appUserWithdraw.getCellPhone());
+//        if(!flag){
+//            return R.fail("验证码已失效,请重新获取");
+//        }
+//        String code = redisService.getCacheObject(CacheConstants.ADD_CARD_PHONE_CODE_PREFIX + appUserWithdraw.getCellPhone());
+//        if (!appUserWithdraw.getCode().equals(code)) {
+//            return R.fail("验证码不正确");
+//        }
         appUserBankService.save(appUserWithdraw);
         return R.ok();
     }

--
Gitblit v1.7.1