瀏覽代碼

Merge branch 'fusion-v1.4.0' into test

lyhzzz 1 年之前
父節點
當前提交
5a8d6e9e34
共有 1 個文件被更改,包括 6 次插入4 次删除
  1. 6 4
      src/main/java/com/fdkankan/ucenter/service/impl/ScenePlusVoidServiceImpl.java

+ 6 - 4
src/main/java/com/fdkankan/ucenter/service/impl/ScenePlusVoidServiceImpl.java

@@ -114,11 +114,13 @@ public class ScenePlusVoidServiceImpl extends ServiceImpl<IScenePlusVoidMapper,
 
 
     @Override
     @Override
     public HashMap<Long, ScenePlusVoid> getByPlusIds(List<Long> plusIds) {
     public HashMap<Long, ScenePlusVoid> getByPlusIds(List<Long> plusIds) {
-        LambdaQueryWrapper<ScenePlusVoid> wrapper = new LambdaQueryWrapper<>();
-        wrapper.in(ScenePlusVoid::getPlusId,plusIds);
-        List<ScenePlusVoid> list = this.list(wrapper);
         HashMap<Long,ScenePlusVoid> map = new HashMap<>();
         HashMap<Long,ScenePlusVoid> map = new HashMap<>();
-        list.forEach(entity -> map.put(entity.getPlusId(),entity));
+        LambdaQueryWrapper<ScenePlusVoid> wrapper = new LambdaQueryWrapper<>();
+        if(plusIds.size()>0){
+            wrapper.in(ScenePlusVoid::getPlusId,plusIds);
+            List<ScenePlusVoid> list = this.list(wrapper);
+            list.forEach(entity -> map.put(entity.getPlusId(),entity));
+        }
         return map;
         return map;
     }
     }
 }
 }