From c20baabe480137a7dabfbe804a4fb72d95b46724 Mon Sep 17 00:00:00 2001
From: zhoushihao <zsh19950802@163.com>
Date: 星期四, 05 十二月 2024 16:36:43 +0800
Subject: [PATCH] 1、修改推送数据格式类型,便于前端展示

---
 hangzhoumesParent/moduleService/howllowGlassModule/src/main/java/com/mes/hollow/service/impl/HollowGlassRelationInfoServiceImpl.java |   19 +++++++------------
 1 files changed, 7 insertions(+), 12 deletions(-)

diff --git a/hangzhoumesParent/moduleService/howllowGlassModule/src/main/java/com/mes/hollow/service/impl/HollowGlassRelationInfoServiceImpl.java b/hangzhoumesParent/moduleService/howllowGlassModule/src/main/java/com/mes/hollow/service/impl/HollowGlassRelationInfoServiceImpl.java
index d699497..f7c5a54 100644
--- a/hangzhoumesParent/moduleService/howllowGlassModule/src/main/java/com/mes/hollow/service/impl/HollowGlassRelationInfoServiceImpl.java
+++ b/hangzhoumesParent/moduleService/howllowGlassModule/src/main/java/com/mes/hollow/service/impl/HollowGlassRelationInfoServiceImpl.java
@@ -85,7 +85,7 @@
             );
         }
         HollowBigStorageCageDetails hollowDetails = hollowBigStorageCageDetailsService.getOne(new LambdaQueryWrapper<HollowBigStorageCageDetails>()
-                .eq(HollowBigStorageCageDetails::getSlot, relationInfoOne.getVirtualSlot()).in(HollowBigStorageCageDetails::getState, Const.GLASS_STATE_IN_ALL_ZERO)
+                .eq(HollowBigStorageCageDetails::getVirtualSlot, relationInfoOne.getVirtualSlot()).in(HollowBigStorageCageDetails::getState, Const.GLASS_STATE_IN_ALL_ZERO)
                 .orderByDesc(HollowBigStorageCageDetails::getSequence).last("limit 1"));
         HollowBigStorageCage storageCage = null;
         if (null == hollowDetails) {
@@ -97,8 +97,8 @@
             return storageDTO;
         }
         HollowGlassRelationInfo relationInfoBefore = hollowGlassRelationInfoService.getOne(new LambdaQueryWrapper<HollowGlassRelationInfo>()
-                .eq(HollowGlassRelationInfo::getEngineerId, relationInfoOne.getEngineerId())
-                .eq(HollowGlassRelationInfo::getTemperingLayoutId, relationInfoOne.getTemperingLayoutId())
+                .eq(HollowGlassRelationInfo::getFlowCardId, relationInfoOne.getFlowCardId())
+                .eq(HollowGlassRelationInfo::getLayer, relationInfoOne.getLayer())
                 .eq(HollowGlassRelationInfo::getVirtualSlot, relationInfoOne.getVirtualSlot())
                 .eq(HollowGlassRelationInfo::getSlotSequence, relationInfoOne.getSlotSequence() - 1));
         if (null == relationInfoBefore) {
@@ -243,15 +243,10 @@
     }
 
     @Override
-    public List<LackDetailsDTO> queryLackByFlowCard(String flowCardId, int layer) {
-
-        return this.baseMapper.queryLackByFlowCard(flowCardId, layer);
-//        return this.list(new LambdaQueryWrapper<HollowGlassRelationInfo>()
-//                .eq(HollowGlassRelationInfo::getFlowCardId,flowCardId)
-//                .eq(HollowGlassRelationInfo::getLayer,layer)
-//                .isNull(HollowGlassRelationInfo::getTemperingLayoutId)
-//                .isNull(HollowGlassRelationInfo::getTemperingFeedSequence)
-//        );
+    public Map<Integer, List<LackDetailsDTO>>  queryLackByFlowCard(String flowCardId) {
+        List<LackDetailsDTO> lackDetailsList = this.baseMapper.queryLackByFlowCard(flowCardId);
+        Map<Integer, List<LackDetailsDTO>> listMap = lackDetailsList.stream().collect(Collectors.groupingBy(LackDetailsDTO::getLayer));
+        return listMap;
     }
 
 }

--
Gitblit v1.8.0