zhoushihao
2024-07-05 b3fb30576c30a3009a8342772591d9e3a5b69980
hangzhoumesParent/moduleService/CacheVerticalGlassModule/src/main/java/com/mes/bigstorage/service/impl/BigStorageCageServiceImpl.java
@@ -264,15 +264,15 @@
    //查询大理片信息,前端展示用
    @Override
    public List<BigStorageCage> querybigStorageCageDetail() {
    public Map<Integer, List<BigStorageCage>> querybigStorageCageDetail() {
        MPJLambdaWrapper<BigStorageCage> wrapper = new MPJLambdaWrapper<>();
        wrapper.selectAll(BigStorageCage.class).selectCollection(BigStorageCageDetails.class, BigStorageCage::getBigStorageCageDetails)
                .leftJoin(BigStorageCageDetails.class, on -> on.eq(BigStorageCageDetails::getSlot, BigStorageCage::getSlot)
                        .in(BigStorageCageDetails::getState, Const.GLASS_STATE_IN, Const.GLASS_STATE_ARTIFICIAL))
                .eq(BigStorageCage::getEnableState, Const.SLOT_ON);
        return bigStorageCageMapper.selectJoinList(BigStorageCage.class, wrapper);
                        .in(BigStorageCageDetails::getState, Const.GLASS_STATE_IN, Const.GLASS_STATE_ARTIFICIAL));
        List<BigStorageCage> bigStorageCages = bigStorageCageMapper.selectJoinList(BigStorageCage.class, wrapper);
        Map<Integer, List<BigStorageCage>> listMap = bigStorageCages.stream().collect(Collectors.groupingBy(item -> item.getDeviceId()));
        return listMap;
    }
    //笼子使用情况,界面展示用