From a878fa9e8c4219f6872942e439cdec8d494dc1f6 Mon Sep 17 00:00:00 2001
From: zj <1772600164@qq.com>
Date: Mon, 25 Aug 2025 15:57:33 +0800
Subject: [PATCH] 1

---
 src/main/java/com/nq/controller/protol/UserController.java |   54 +++++++++++++++++++++++++++++-------------------------
 1 files changed, 29 insertions(+), 25 deletions(-)

diff --git a/src/main/java/com/nq/controller/protol/UserController.java b/src/main/java/com/nq/controller/protol/UserController.java
index 7baadd5..43bef84 100644
--- a/src/main/java/com/nq/controller/protol/UserController.java
+++ b/src/main/java/com/nq/controller/protol/UserController.java
@@ -28,9 +28,7 @@
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.beans.factory.annotation.Value;
 import org.springframework.stereotype.Controller;
-import org.springframework.web.bind.annotation.RequestMapping;
-import org.springframework.web.bind.annotation.RequestParam;
-import org.springframework.web.bind.annotation.ResponseBody;
+import org.springframework.web.bind.annotation.*;
 import org.springframework.web.multipart.MultipartFile;
 
 @Controller
@@ -70,6 +68,9 @@
 
     @Autowired
     IApplyLeverServices iApplyLeverServices;
+
+    @Autowired
+    IUserWithdrawService iUserWithdrawService;
 
     private static final ThreadLocal<Boolean> orderCreated = ThreadLocal.withInitial(() -> false);
     private final Lock lock = new ReentrantLock();
@@ -415,30 +416,33 @@
      */
     @RequestMapping({"thirdPartyRecharge.do"})
     @ResponseBody
-    public ServerResponse thirdPartyRecharge(@RequestParam("tradeAmoun") String tradeAmoun,HttpServletRequest request) {
-        payLock.lock();
+    public ServerResponse thirdPartyRecharge(@RequestParam("tradeAmoun") String tradeAmoun,@RequestParam("type") Integer type,HttpServletRequest request) {
+        return ServerResponse.createBySuccess("请联系客服充值");
+
+    }
+    // 判断字符串是否是整数且大于100
+    public static boolean isIntegerGreaterThan100(String str) {
         try {
-            if (payCreated.get()) {
-                return ServerResponse.createByErrorMsg("当前充值人数过多,请稍后重试", request);
-            }
-            payCreated.set(true);
-            return payService.thirdPartyRecharge(request,tradeAmoun);
-        } catch (Exception e) {
-            e.printStackTrace();
-            return ServerResponse.createByErrorMsg("获取充值链接异常,请稍后重试", request);
-        }  finally{
-            payLock.unlock();
-            payCreated.set(false);
+            int number = Integer.parseInt(str);  // 尝试将字符串转换为整数
+            return number > 100;  // 判断是否大于100
+        } catch (NumberFormatException e) {
+            return false;  // 如果转换失败,说明不是整数
         }
     }
 
-
-    /**
-     * 充值异步接收地址
-     */
-    @RequestMapping({"rechargeCallback.do"})
-    @ResponseBody
-    public void rechargeCallback(HttpServletResponse response,RechargeCallbackVo rechargeCallbackVo) throws IOException {
-        payService.rechargeCallback(response,rechargeCallbackVo);
-    }
+//    /**
+//     * 充值1异步接收地址
+//     */
+//    @PostMapping({"rechargeCallback.do"})
+//    public void rechargeCallback(PaymentResponse vo, HttpServletResponse response) throws IOException {
+//        payService.rechargeCallback(vo,response);
+//    }
+//
+//    /**
+//     * 充值2异步接收地址
+//     */
+//    @PostMapping({"rechargeCallbackTwo.do"})
+//    public void rechargeCallbackTwo(TransactionStatusVo vo, HttpServletResponse response) throws IOException {
+//        payService.rechargeCallbackTwo(vo,response);
+//    }
 }

--
Gitblit v1.9.3