From 57fd465068d99fffd31c03806de3d5691e8048ee Mon Sep 17 00:00:00 2001
From: 44323 <443237572@qq.com>
Date: 星期五, 15 三月 2024 22:13:45 +0800
Subject: [PATCH] 部分bug修改

---
 cloud-server-other/src/main/java/com/dsh/other/util/PayMoneyUtil.java                                   |    2 +-
 cloud-server-competition/src/main/java/com/dsh/competition/service/impl/CompetitionServiceImpl.java     |    6 ++++--
 cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/BallController.java |   12 ++++++------
 cloud-server-other/src/main/java/com/dsh/other/controller/GameController.java                           |    6 ++++--
 cloud-server-competition/src/main/java/com/dsh/competition/controller/CompetitionController.java        |    5 ++---
 5 files changed, 17 insertions(+), 14 deletions(-)

diff --git a/cloud-server-competition/src/main/java/com/dsh/competition/controller/CompetitionController.java b/cloud-server-competition/src/main/java/com/dsh/competition/controller/CompetitionController.java
index 01fbc2a..ef8af3e 100644
--- a/cloud-server-competition/src/main/java/com/dsh/competition/controller/CompetitionController.java
+++ b/cloud-server-competition/src/main/java/com/dsh/competition/controller/CompetitionController.java
@@ -435,19 +435,18 @@
                 String transaction_id = map.get("transaction_id");
                 String result = map.get("result");
 
-                PaymentCompetition paymentCompetition = paymentCompetitionService.getOne(new QueryWrapper<PaymentCompetition>().eq("code", code).eq("payType", 1));
+                PaymentCompetition paymentCompetition = paymentCompetitionService.getOne(new QueryWrapper<PaymentCompetition>().eq("code", code)
+                        .eq("payType", 1));
                 if (paymentCompetition.getPayStatus() == 1) {
                     paymentCompetition.setAppUserId(null);
                     paymentCompetition.setPayStatus(2);
                     paymentCompetition.setPayTime(new Date());
                     paymentCompetition.setPayOrderNo(transaction_id);
                     paymentCompetitionService.updateById(paymentCompetition);
-
                     Competition competition = cttService.getById(paymentCompetition.getCompetitionId());
                     competition.setApplicantsNumber(competition.getApplicantsNumber() + 1);
                     cttService.updateById(competition);
                 }
-
                 PrintWriter out = response.getWriter();
                 out.write(result);
                 out.flush();
diff --git a/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/CompetitionServiceImpl.java b/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/CompetitionServiceImpl.java
index 42600b9..10ed3c8 100644
--- a/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/CompetitionServiceImpl.java
+++ b/cloud-server-competition/src/main/java/com/dsh/competition/service/impl/CompetitionServiceImpl.java
@@ -232,7 +232,8 @@
         JSONArray jsonArray = JSON.parseArray(paymentCompetitionVo.getIds());
         Competition competition = this.getById(paymentCompetitionVo.getId());
 
-        List<PaymentCompetition> list = paymentCompetitionService.list(new QueryWrapper<PaymentCompetition>().eq("competitionId", paymentCompetitionVo.getId()).ne("payStatus", 3));
+        List<PaymentCompetition> list = paymentCompetitionService.list(new QueryWrapper<PaymentCompetition>()
+                .eq("competitionId", paymentCompetitionVo.getId()).ne("payStatus", 3));
         List<Long> pays = new ArrayList<>();
         for (PaymentCompetition paymentCompetition : list) {
             pays.add(paymentCompetition.getId());
@@ -373,7 +374,8 @@
                             int min = 5000;
                             wait += (min * num);
                             Thread.sleep(wait);
-                            PaymentCompetition paymentCompetition = paymentCompetitionService.getOne(new QueryWrapper<PaymentCompetition>().eq("code", code).eq("payType", 1));
+                            PaymentCompetition paymentCompetition = paymentCompetitionService.getOne(new QueryWrapper<PaymentCompetition>()
+                                    .eq("code", code).eq("payType", 1));
                             if (paymentCompetition.getPayStatus() == 2) {
                                 break;
                             }
diff --git a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/BallController.java b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/BallController.java
index ac910e3..b5d45cb 100644
--- a/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/BallController.java
+++ b/cloud-server-management/src/main/java/com/dsh/guns/modular/system/controller/system/BallController.java
@@ -334,8 +334,8 @@
         TStore st = storeService.getById(store);
         map3.put("sign", "0DB011836143EEE2C2E072967C9F4E4B");
         map4.put("sign", "0DB011836143EEE2C2E072967C9F4E4B");
-        map3.put("space_id", st.getId() + "");
-        map4.put("space_id", st.getId() + "");
+        map3.put("space_id", si.getId() + "");
+        map4.put("space_id", si.getId() + "");
         map3.put("name", blue);
         map4.put("name", red);
         map3.put("city_code", city);
@@ -360,13 +360,13 @@
         HashMap<String, String> blueCode = new HashMap<>();
         blueCode.put("scan_type", "1000");
         blueCode.put("sutu_id", ""+sutuId);
-        blueCode.put("space_id", st.getId() + "");
+        blueCode.put("space_id", si.getId() + "");
         HashMap<String, String> redCode = new HashMap<>();
         redCode.put("scan_type", "1000");
         redCode.put("sutu_id", sutuId1+"");
-        redCode.put("space_id", st.getId() + "");
-        String blueS= "{\"scan_type\": 1000, \"space_id\": "+st.getId()+", \"sutu_id\": "+sutuId+"}";
-        String redS= "{\"scan_type\": 1000, \"space_id\": "+st.getId()+", \"sutu_id\": "+sutuId1+"}";
+        redCode.put("space_id", si.getId() + "");
+        String blueS= "{\"scan_type\": 1000, \"space_id\": "+si.getId()+", \"sutu_id\": "+sutuId+"}";
+        String redS= "{\"scan_type\": 1000, \"space_id\": "+si.getId()+", \"sutu_id\": "+sutuId1+"}";
         MyQrCodeUtil.createCodeToFile(blueS);
         MyQrCodeUtil.createCodeToFile(redS);
         BufferedImage blueImage = QRCodeUtil.createImage(blueS);
diff --git a/cloud-server-other/src/main/java/com/dsh/other/controller/GameController.java b/cloud-server-other/src/main/java/com/dsh/other/controller/GameController.java
index 73b6c4e..fa5e993 100644
--- a/cloud-server-other/src/main/java/com/dsh/other/controller/GameController.java
+++ b/cloud-server-other/src/main/java/com/dsh/other/controller/GameController.java
@@ -205,11 +205,12 @@
                             try {
                                 int num = 1;
                                 int wait = 0;
-                                while (num <= 10) {
+                                while (num <= 15) {
                                     int min = 5000;
                                     wait += (min * num);
                                     Thread.sleep(wait);
-                                    List<TGameRecord> list = gameRecordService.list(new QueryWrapper<TGameRecord>().eq("code", code).eq("payType", 2));
+                                    List<TGameRecord> list = gameRecordService
+                                            .list(new QueryWrapper<TGameRecord>().eq("number", code).eq("payType", 1));
                                     TGameRecord one = list.get(0);
 
                                     if (one.getStatus() == 1) {
@@ -237,6 +238,7 @@
                                                 coursePackagePayment.setStatus(1);
                                                 coursePackagePayment.setMoney(config.getCash());
                                                 coursePackagePayment.setOrderNo(transaction_id);
+
                                             }
                                             gameRecordService.updateBatchById(list);
                                             Integer integer = startGame(uid, gameId, spaceId, sutuId);
diff --git a/cloud-server-other/src/main/java/com/dsh/other/util/PayMoneyUtil.java b/cloud-server-other/src/main/java/com/dsh/other/util/PayMoneyUtil.java
index 9117768..c2aa6dd 100644
--- a/cloud-server-other/src/main/java/com/dsh/other/util/PayMoneyUtil.java
+++ b/cloud-server-other/src/main/java/com/dsh/other/util/PayMoneyUtil.java
@@ -481,7 +481,7 @@
                         String s1 = this.weixinSignature(map3);
                         map3.put("sign", s1);
                         System.err.println(map3);
-                        map3.put("siteBookingId", attach);
+                        map3.put("siteBooking", attach);
                         return ResultUtil.success(map3);
                 }
                 return null;

--
Gitblit v1.7.1