‘linchangsheng’ 4 weeks ago
parent
commit
a2885a0fa9
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/main/java/com/gree/mall/manager/logic/goods/GoodsLogic.java

+ 1 - 1
src/main/java/com/gree/mall/manager/logic/goods/GoodsLogic.java

@@ -333,7 +333,7 @@ public class GoodsLogic {
         goodsBean.setImages(commonLogic.queryFileByObjId(goods.getGoodsId(), Constant.Img.GOODS_IMG));
 
         goodsBean.setGoodsCompanies(goodsCompanyService.lambdaQuery()
-        .in(GoodsCompany::getCompanyId,adminUser.getAdminCompanyIds())
+        .in(CollectionUtils.isNotEmpty(adminUser.getAdminCompanyIds()),GoodsCompany::getCompanyId,adminUser.getAdminCompanyIds())
                 .eq(GoodsCompany::getGoodsId,goods.getGoodsId()).list()
         );
         goodsBean.setStock(goodsStock);