zyp 4 dagen geleden
bovenliggende
commit
6f8ccb03d2

+ 6 - 0
fs-service/src/main/java/com/fs/his/service/impl/FsIntegralGoodsServiceImpl.java

@@ -190,6 +190,12 @@ public class FsIntegralGoodsServiceImpl implements IFsIntegralGoodsService
         param.setMaxPoints(stageMaxPoints);
         List<FsIntegralGoods> stageGoods = selectRandomStageGoods(param);
 
+        if (stageGoods.size()<3){
+            param.setMinPoints(currentStage);
+            param.setMaxPoints(stageMaxPoints);
+            stageGoods = selectRandomStageGoods(param);
+        }
+
         // 5. 转换为奖励商品列表
         List<FsCourseAnswerReward.RewardProduct> products = new ArrayList<>();
         int minRequiredPoints = stageMaxPoints; // 用于计算进度的最小积分要求

+ 1 - 1
fs-service/src/main/resources/application-druid-myhk-test.yml

@@ -1,7 +1,7 @@
 # 数据源配置
 spring:
     profiles:
-        include: config-druid-myhk,common
+        include: config-myhk,common
     # redis 配置
     redis:
 #        host: 172.27.0.6

+ 1 - 1
fs-service/src/main/resources/application-druid-myhk.yml

@@ -1,7 +1,7 @@
 # 数据源配置
 spring:
     profiles:
-        include: config-druid-myhk,common
+        include: config-myhk,common
     # redis 配置
     redis:
         host: 172.27.0.6