| | |
| | | if (userProportions.size()>0){ |
| | | for (UserProportion userProportion : userProportions) { |
| | | if (org.apache.commons.lang3.ObjectUtils.isNotEmpty(userProportion)){ |
| | | log.info("统计数据"+userProportion); |
| | | UserRateAnalysisVO vo=new UserRateAnalysisVO(); |
| | | if (monthRange){ |
| | | if (userProportion.getCommunityId().equals("11")){ |
| | |
| | | } |
| | | vo.setName(typeToName(type,userProportion )); |
| | | vo.setCount(userProportion.getUser()); |
| | | log.info("统计后数据+"+vo); |
| | | userRateAnalysisVOList.add(vo); |
| | | } |
| | | } |
| | | } |
| | | if (ObjectUtils.isEmpty(range)){ |
| | | //查看累计数据时才计算其他用户的比例 |
| | | final Boolean flag=(type.equals(ALLSTREET) || type.equals(ALLCOMMUNITY) || type.equals(BYSTREET) || type.equals(BYAREA)); |
| | | //查看累计数据时才计算其他用户的比例 || type.equals(BYSTREET) || type.equals(BYAREA)) |
| | | final Boolean flag=(type.equals(ALLSTREET) || type.equals(ALLCOMMUNITY)); |
| | | if (flag){ |
| | | UserRateAnalysisVO vo=new UserRateAnalysisVO(); |
| | | vo.setName(OTHERUSER); |
| | |
| | | realUserVO.setRealUserRate(rate.doubleValue()); |
| | | } |
| | | for (RealUser realUser : realUsers) { |
| | | if (!(type.equals(ALLCOUNTY))){ |
| | | if (org.apache.commons.lang3.ObjectUtils.isNotEmpty(realUser)){ |
| | | if (realUser.getCommunityId().equals("11")){ |
| | | continue; |
| | | } |
| | | } |
| | | } |
| | | RealUserAnalysisVO vo=new RealUserAnalysisVO(); |
| | |
| | | break; |
| | | case "510402": |
| | | name="东区"; |
| | | break; |
| | | case "510411": |
| | | name="仁和区"; |
| | | break; |
| | |
| | | *根据type选择要设置的名称 |
| | | * */ |
| | | private String typeToName(Integer type,UserProportion proportion){ |
| | | log.info("当前code"+proportion.getAreaCode()); |
| | | String name=""; |
| | | if (type.equals(ALLCOUNTY)){ |
| | | name=areaCodeToName(proportion.getAreaCode()); |