‘linchangsheng’ 1 周之前
父節點
當前提交
7e3b3d4fd7
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      src/main/java/com/gree/mall/manager/logic/goods/GoodsLogic.java

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

@@ -787,6 +787,8 @@ public class GoodsLogic {
         List<String> companyWechatIds = adminUser.getAdminCompanyIds();
 
         GoodsTypeCount goodsTypeCount = customGoodsMapper.countByType(companyWechatIds);
+        if (goodsTypeCount == null)
+            return new GoodsTypeCount();
         //查询已售罄的商品数量
         goodsTypeCount.setYsq(customGoodsMapper.ysq(companyWechatIds));
         goodsTypeCount.setHdz(customGoodsMapper.countByFlag(companyWechatIds));