Quellcode durchsuchen

云箭大屏生产资源

laoyao vor 3 Jahren
Ursprung
Commit
64091a1f01

+ 2 - 2
imcs-admin-boot/imcs-business-biz/src/main/java/com/github/zuihou/business/edgeLibrary/service/impl/StockInfoServiceImpl.java

@@ -133,11 +133,11 @@ public class StockInfoServiceImpl extends SuperServiceImpl<StockInfoMapper, Stoc
         Map<Long,Integer>storgeStockCountMap = new HashMap<Long,Integer>();
         //存放到map中
         for(Map m:shelvesStockCountlist){
-            shelvesStockCountMap.put(Long.valueOf(m.get("id").toString()),m);
+            shelvesStockCountMap.put(Long.valueOf(m.get("id")==null?"0":m.get("id").toString()),m);
         }
 
         for(Map m:storgeStockCountlist){
-            storgeStockCountMap.put(Long.valueOf(m.get("id").toString()),Integer.parseInt(m.get("count").toString()));
+            storgeStockCountMap.put(Long.valueOf(m.get("id")==null?"0":m.get("id").toString()),Integer.parseInt(m.get("count").toString()));
         }
 
         //查询出所有货架