mitao
7 天以前 21488a55ba76ae4f1296b608fbcdf1f06036db64
springcloud_k8s_panzhihuazhihuishequ/service_sangeshenbian/src/main/java/com/panzhihua/sangeshenbian/service/impl/ComplaintServiceImpl.java
@@ -1617,7 +1617,7 @@
    }
    @Override
    public List<AnalyticStatisticsThreeVo> analyticStatisticsThree(AnalyticStatisticsQuery query, List<Complaint> complaints) {
    public List<AnalyticStatisticsThreeVo> analyticStatisticsThree(Integer rank, List<Complaint> complaints) {
        Map<String, List<Complaint>> groupedByProblemType = complaints.stream()
                .collect(Collectors.groupingBy(Complaint::getProblemType));
        List<AnalyticStatisticsThreeVo> analyticStatisticsThreeVos = groupedByProblemType.entrySet().stream()
@@ -1629,11 +1629,11 @@
                })
                .collect(Collectors.toList());
        analyticStatisticsThreeVos = analyticStatisticsThreeVos.stream().sorted(Comparator.comparing(AnalyticStatisticsThreeVo::getAllTotal).reversed()).collect(Collectors.toList());
        if (query.getRank() == null) {
        if (rank == null) {
            return analyticStatisticsThreeVos;
        } else if (query.getRank() == 5) {
        } else if (rank == 5) {
            return analyticStatisticsThreeVos.stream().limit(5).collect(Collectors.toList());
        } else if (query.getRank() == 10) {
        } else if (rank == 10) {
            return analyticStatisticsThreeVos.stream().limit(10).collect(Collectors.toList());
        }
        return Collections.emptyList();