| | |
| | | continue; |
| | | } |
| | | gxList = gxList.stream().sorted(Comparator.comparing(SgProjectInfoVO::getPrice)).collect(Collectors.toList()); |
| | | SgTypeVO typeVO = SgTypeVO.builder().typeName(gxList.get(0).getTypeName()).build(); |
| | | SgTypeVO typeVO = SgTypeVO.builder().typeName(gxList.get(0).getTypeName()).sort(gxList.get(0).getDSort()).build(); |
| | | List<SgDeviceDO> deviceDOS = new ArrayList<>(); |
| | | //设备分组 |
| | | Map<Long, List<SgProjectInfoVO>> dMap = gxList.stream().filter(s->s.getDId()!=null).collect(Collectors.groupingBy(SgProjectInfoVO::getDId)); |
| | |
| | | BigDecimal sgGxOver = BigDecimal.valueOf(sum); |
| | | BigDecimal divideSgGx = sgGxOver.divide(sgGxSize, 2, RoundingMode.HALF_UP); |
| | | ptypeVO.setPTypeProgress(getBigDecimalPercent(divideSgGx)); |
| | | sgGxDOS = sgGxDOS.stream().sorted(Comparator.comparing(SgTypeVO::getSort)).collect(Collectors.toList()); |
| | | ptypeVO.setSgTypeVOS(sgGxDOS); |
| | | pTypes.add(ptypeVO); |
| | | } |