| | |
| | | /** |
| | | * 按设备类型汇总设备信息,供新版设备报告使用。 |
| | | */ |
| | | private List<Object> buildDeviceGroupInfo() { |
| | | protected List<Object> buildDeviceGroupInfo() { |
| | | Map<String, List<Device>> groupedDevices = devices.stream() |
| | | .sorted(Comparator.comparing(device -> device.getType() != null ? device.getType().ordinal() : Integer.MAX_VALUE)) |
| | | .collect(java.util.stream.Collectors.groupingBy( |
| | |
| | | } |
| | | |
| | | JSONObject summary = new JSONObject(); |
| | | summary.put("分项名称", "管理行为得分"); |
| | | summary.put("分项名称", "综合得分"); |
| | | summary.put("分项得分", formatFloat(totalScore / totalDevices)); |
| | | details.add(summary); |
| | | |