Эх сурвалжийг харах

Merge remote-tracking branch 'origin/master'

dos 1 сар өмнө
parent
commit
4e90f263a6

+ 5 - 6
game-business/src/main/java/com/game/business/controller/AppGameBettingController.java

@@ -200,7 +200,6 @@ public class AppGameBettingController extends BaseController{
                         }
 
                         if(checkItemList.size() == 4){
-                            return HttpRet.fail("当前期投注选项已超过限额,无法下单!");
                         }
 
                         // 当前投注是否已经满足3个投注选项了
@@ -216,7 +215,7 @@ public class AppGameBettingController extends BaseController{
 
                 List<String> itemSmallList = Arrays.asList(Common.GAME_BETTING_ITEM_SMALL_LIMIT);
 
-                List<String> itemBigList = Arrays.asList(Common.GAME_BETTING_ITEM_SMALL_LIMIT);
+                List<String> itemBigList = Arrays.asList(Common.GAME_BETTING_ITEM_BIG_LIMIT);
 
                 List<String> bettingItemList = appGameBettingService.getBettingItem(gameBetting.getUserId(), gameBetting.getGameId(), appGame.getGameDate());
 
@@ -250,19 +249,19 @@ public class AppGameBettingController extends BaseController{
 
                         List<String> checkItemList = new ArrayList<>();
 
-                        for (int i = 0; i < itemSmallList.size(); i++) {
-                            String itemStr = itemSmallList.get(i);
+                        for (int i = 0; i < itemBigList.size(); i++) {
+                            String itemStr = itemBigList.get(i);
                             if (bettingItemList.contains(itemStr)) {
                                 checkItemList.add(itemStr);
                             }
                         }
 
-                        if(checkItemList.size() >= 3){
+                        if(checkItemList.size() >= 4){
                             return HttpRet.fail("当前期投注选项已超过限额,无法下单!");
                         }
 
                         // 当前投注是否已经满足3个投注选项了
-                        if (checkItemList.size() == 2) {
+                        if (checkItemList.size() == 3) {
                             // 当前投注的是否属于特殊选项重复投注
                             if (!checkItemList.contains(gameBetting.getBettingItem())) {
                                 return HttpRet.fail("当前期投注选项已超过限额,无法下单!");

+ 5 - 0
game-business/src/main/java/com/game/business/vo/AppUserGameBettingCountVO.java

@@ -1,5 +1,7 @@
 package com.game.business.vo;
 
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.game.common.annotation.Excel;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 import lombok.Data;
@@ -29,6 +31,9 @@ public class AppUserGameBettingCountVO {
     @ApiModelProperty(value = "当前开奖项")
     private String gameLotterySucc;
 
+    @ApiModelProperty(value = "是否开奖:0 否;1是")
+    private Integer isLottery;
+
     @ApiModelProperty(value = "当前开奖时间")
     private Date gameRecordDate;
 

+ 3 - 1
game-business/src/main/resources/mapper/business/AppGameBettingMapper.xml

@@ -38,7 +38,9 @@
     </select>
 
     <select id="getUserCount" resultType="com.game.business.vo.AppUserGameBettingCountVO">
-        select tmp.*,agl.game_lottery_succ as gameLotterySucc,agl.game_record_date as gameRecordDate from (
+        select tmp.*,
+               agl.game_lottery_succ as gameLotterySucc,agl.game_record_date as gameRecordDate,agl.is_lottery as isLottery
+        from (
           select
               game_date as gameDate,
               count(id) as bettingCount,