|  | @ -112,7 +112,7 @@ public class PublicPartExtractServiceImpl implements PublicPartExtractService { | 
			
		
	
		
		
			
				
					|  |  |             log.error("抽取【公众参与-人均议题】,获取注册用户数为空"); |  |  |             log.error("抽取【公众参与-人均议题】,获取注册用户数为空"); | 
			
		
	
		
		
			
				
					|  |  |             return; |  |  |             return; | 
			
		
	
		
		
			
				
					|  |  |         } |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |         Map<String, GridUserCountResultDTO> userCountMap = userCountList.stream().collect(Collectors.toMap(GridUserCountResultDTO::getGridId, o -> o)); |  |  |         Map<String, GridUserCountResultDTO> userCountMap = userCountList.stream().collect(Collectors.toMap(GridUserCountResultDTO::getOrgId, o -> o)); | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |         issueTotal.forEach(issue -> { |  |  |         issueTotal.forEach(issue -> { | 
			
		
	
		
		
			
				
					|  |  |             String gridId = issue.getGridId(); |  |  |             String gridId = issue.getGridId(); | 
			
		
	
		
		
			
				
					|  |  |             ScreenUserJoinEntity entity = insertMap.get(gridId); |  |  |             ScreenUserJoinEntity entity = insertMap.get(gridId); | 
			
		
	
	
		
		
			
				
					|  | @ -122,7 +122,8 @@ public class PublicPartExtractServiceImpl implements PublicPartExtractService { | 
			
		
	
		
		
			
				
					|  |  |             log.debug("issue:{}", JSON.toJSONString(issue)); |  |  |             log.debug("issue:{}", JSON.toJSONString(issue)); | 
			
		
	
		
		
			
				
					|  |  |             log.debug("user:{}", JSON.toJSONString(user)); |  |  |             log.debug("user:{}", JSON.toJSONString(user)); | 
			
		
	
		
		
			
				
					|  |  |             if (!user.getRegTotal().equals(0)) { |  |  |             if (!user.getRegTotal().equals(0)) { | 
			
		
	
		
		
			
				
					
					|  |  |                 BigDecimal avgIssueCount = new BigDecimal(issue.getIssueIncr()).divide(new BigDecimal(user.getRegTotal()).divide(new BigDecimal(NumConstant.ONE_HUNDRED))); |  |  |                 BigDecimal avgIssueCount = new BigDecimal(issue.getIssueIncr()).divide(new BigDecimal(user.getRegTotal()) | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |                         .divide(new BigDecimal(NumConstant.ONE_HUNDRED)), 4, BigDecimal.ROUND_HALF_UP); | 
			
		
	
		
		
			
				
					|  |  |                 entity.setAvgIssue(avgIssueCount); |  |  |                 entity.setAvgIssue(avgIssueCount); | 
			
		
	
		
		
			
				
					|  |  |             } |  |  |             } | 
			
		
	
		
		
			
				
					|  |  |         }); |  |  |         }); | 
			
		
	
	
		
		
			
				
					|  | @ -156,9 +157,13 @@ public class PublicPartExtractServiceImpl implements PublicPartExtractService { | 
			
		
	
		
		
			
				
					|  |  |                 if (memberCount == null) { |  |  |                 if (memberCount == null) { | 
			
		
	
		
		
			
				
					|  |  |                     memberCount = 0; |  |  |                     memberCount = 0; | 
			
		
	
		
		
			
				
					|  |  |                 } |  |  |                 } | 
			
		
	
		
		
			
				
					
					|  |  |                 bigDecimal = bigDecimal.add(new BigDecimal(vote.getVoteCount() / memberCount)); |  |  |                 if (memberCount != 0) { | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |                     bigDecimal = bigDecimal.add(new BigDecimal(vote.getVoteCount() / memberCount)); | 
			
		
	
		
		
			
				
					|  |  |  |  |  |                 } | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             } | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             if (votedByIssueCount.intValue() != 0) { | 
			
		
	
		
		
			
				
					|  |  |  |  |  |                 entity.setAvgJoin(bigDecimal.divide(votedByIssueCount, 4, BigDecimal.ROUND_HALF_UP).multiply(new BigDecimal(NumConstant.ONE_HUNDRED))); | 
			
		
	
		
		
			
				
					|  |  |             } |  |  |             } | 
			
		
	
		
		
			
				
					|  |  |             entity.setAvgJoin(bigDecimal.divide(votedByIssueCount).multiply(new BigDecimal(NumConstant.ONE_HUNDRED))); |  |  |  | 
			
		
	
		
		
			
				
					|  |  |         } |  |  |         } | 
			
		
	
		
		
			
				
					|  |  |         screenUserJoinService.deleteAndInsertBatch(formDTO, new ArrayList<>(insertMap.values())); |  |  |         screenUserJoinService.deleteAndInsertBatch(formDTO, new ArrayList<>(insertMap.values())); | 
			
		
	
		
		
			
				
					|  |  |     } |  |  |     } | 
			
		
	
	
		
		
			
				
					|  | @ -179,7 +184,7 @@ public class PublicPartExtractServiceImpl implements PublicPartExtractService { | 
			
		
	
		
		
			
				
					|  |  |             log.error("抽取【公众参与-人均议题】,获取注册用户数为空"); |  |  |             log.error("抽取【公众参与-人均议题】,获取注册用户数为空"); | 
			
		
	
		
		
			
				
					|  |  |             return; |  |  |             return; | 
			
		
	
		
		
			
				
					|  |  |         } |  |  |         } | 
			
		
	
		
		
			
				
					
					|  |  |         Map<String, GridUserCountResultDTO> userCountMap = userCountList.stream().collect(Collectors.toMap(GridUserCountResultDTO::getGridId, o -> o)); |  |  |         Map<String, GridUserCountResultDTO> userCountMap = userCountList.stream().collect(Collectors.toMap(GridUserCountResultDTO::getOrgId, o -> o)); | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |         Set<String> agencyIdSet = new HashSet<>(); |  |  |         Set<String> agencyIdSet = new HashSet<>(); | 
			
		
	
		
		
			
				
					|  |  |         issueTotal.forEach(issue -> { |  |  |         issueTotal.forEach(issue -> { | 
			
		
	
		
		
			
				
					|  |  |             String agencyId = issue.getAgencyId(); |  |  |             String agencyId = issue.getAgencyId(); | 
			
		
	
	
		
		
			
				
					|  | @ -188,8 +193,11 @@ public class PublicPartExtractServiceImpl implements PublicPartExtractService { | 
			
		
	
		
		
			
				
					|  |  |             entity.setJoinTotal(issue.getIssueIncr()); |  |  |             entity.setJoinTotal(issue.getIssueIncr()); | 
			
		
	
		
		
			
				
					|  |  |             GridUserCountResultDTO user = userCountMap.get(agencyId); |  |  |             GridUserCountResultDTO user = userCountMap.get(agencyId); | 
			
		
	
		
		
			
				
					|  |  |             //百人人均议题:统计周期内总的议题数/(注册用户数/100)
 |  |  |             //百人人均议题:统计周期内总的议题数/(注册用户数/100)
 | 
			
		
	
		
		
			
				
					
					|  |  |             BigDecimal avgIssueCount = new BigDecimal(issue.getIssueIncr()).divide(new BigDecimal(user.getRegTotal()).divide(new BigDecimal(NumConstant.ONE_HUNDRED))); |  |  |             if (!user.getRegTotal().equals(0)) { | 
			
				
				
			
		
	
		
		
			
				
					
					|  |  |             entity.setAvgIssue(avgIssueCount); |  |  |                 BigDecimal avgIssueCount = new BigDecimal(issue.getIssueIncr()).divide(new BigDecimal(user.getRegTotal()) | 
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |                         .divide(new BigDecimal(NumConstant.ONE_HUNDRED)), 4, BigDecimal.ROUND_HALF_UP); | 
			
		
	
		
		
			
				
					|  |  |  |  |  |                 entity.setAvgIssue(avgIssueCount); | 
			
		
	
		
		
			
				
					|  |  |  |  |  |             } | 
			
		
	
		
		
			
				
					|  |  |         }); |  |  |         }); | 
			
		
	
		
		
			
				
					|  |  | 
 |  |  | 
 | 
			
		
	
		
		
			
				
					|  |  |         List<List<String>> partition = ListUtils.partition(new ArrayList<>(agencyIdSet), NumConstant.THIRTY); |  |  |         List<List<String>> partition = ListUtils.partition(new ArrayList<>(agencyIdSet), NumConstant.THIRTY); | 
			
		
	
	
		
		
			
				
					|  | @ -224,7 +232,9 @@ public class PublicPartExtractServiceImpl implements PublicPartExtractService { | 
			
		
	
		
		
			
				
					|  |  |                     } |  |  |                     } | 
			
		
	
		
		
			
				
					|  |  |                     bigDecimal = bigDecimal.add(new BigDecimal(vote.getVoteCount() / memberCount)); |  |  |                     bigDecimal = bigDecimal.add(new BigDecimal(vote.getVoteCount() / memberCount)); | 
			
		
	
		
		
			
				
					|  |  |                 } |  |  |                 } | 
			
		
	
		
		
			
				
					
					|  |  |                 entity.setAvgJoin(bigDecimal.divide(votedByIssueCount).multiply(new BigDecimal(NumConstant.ONE_HUNDRED))); |  |  |                 if (votedByIssueCount.intValue() != 0) { | 
			
				
				
			
		
	
		
		
	
		
		
			
				
					|  |  |  |  |  |                     entity.setAvgJoin(bigDecimal.divide(votedByIssueCount).multiply(new BigDecimal(NumConstant.ONE_HUNDRED))); | 
			
		
	
		
		
			
				
					|  |  |  |  |  |                 } | 
			
		
	
		
		
			
				
					|  |  |             } |  |  |             } | 
			
		
	
		
		
			
				
					|  |  |         }); |  |  |         }); | 
			
		
	
		
		
			
				
					|  |  |         screenUserJoinService.deleteAndInsertBatch(formDTO, new ArrayList<>(insertMap.values())); |  |  |         screenUserJoinService.deleteAndInsertBatch(formDTO, new ArrayList<>(insertMap.values())); | 
			
		
	
	
		
		
			
				
					|  | 
 |