java110
2020-05-19 56d92d296d37ebb53f89566270d2368cb620ef29
处理未分配位置设备
1个文件已修改
20 ■■■■■ 已修改文件
Api/src/main/java/com/java110/api/listener/machine/ListMachinesListener.java 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
Api/src/main/java/com/java110/api/listener/machine/ListMachinesListener.java
@@ -125,6 +125,9 @@
        //批量处理 房屋信息
        refreshRooms(machines);
        //位置未分配时
        refreshOther(machines);
    }
    /**
@@ -140,6 +143,7 @@
            if (!"2000".equals(machineDto.getLocationTypeCd())
                    && !"3000".equals(machineDto.getLocationTypeCd())
                            && !"4000".equals(machineDto.getLocationTypeCd())
            ) {
                communityIds.add(machineDto.getLocationObjId());
                tmpMachineDtos.add(machineDto);
@@ -240,6 +244,22 @@
        }
    }
    /**
     * 获取批量单元
     *
     * @param machines 设备信息
     * @return 批量userIds 信息
     */
    private void refreshOther(List<MachineDto> machines) {
        for (MachineDto machineDto : machines) {
            if ("4000".equals(machineDto.getLocationTypeCd())) {
               machineDto.setLocationObjName("未分配");
            }
        }
    }
    public ICommunityInnerServiceSMO getCommunityInnerServiceSMOImpl() {
        return communityInnerServiceSMOImpl;
    }