| 
						
						
							
								
							
						
						
					 | 
					@ -96,6 +96,10 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							String dateString = DateUtils.format(date); | 
					 | 
					 | 
							String dateString = DateUtils.format(date); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							DimAgencyDTO dimAgencyDTO = new DimAgencyDTO(); | 
					 | 
					 | 
							DimAgencyDTO dimAgencyDTO = new DimAgencyDTO(); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							dimAgencyDTO.setCustomerId(customerId); | 
					 | 
					 | 
							dimAgencyDTO.setCustomerId(customerId); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							//获取日期相关维度
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							//清空数据
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							factIssueAgencyDailyService.deleteByCustomerId(customerId, dimId.getDateId()); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取当前客户下所有机关
 | 
					 | 
					 | 
							//获取当前客户下所有机关
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<DimAgencyDTO> agencyList = dimAgencyService.getDimAgencyList(dimAgencyDTO); | 
					 | 
					 | 
							List<DimAgencyDTO> agencyList = dimAgencyService.getDimAgencyList(dimAgencyDTO); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取机关下议题各种状态的数目统计
 | 
					 | 
					 | 
							//获取机关下议题各种状态的数目统计
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
					@ -110,8 +114,6 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<ProjectAgencyDTO> projectAgencyClosedTotalList = projectService.getAgencyClosedProjectTotal(customerId, dateString); | 
					 | 
					 | 
							List<ProjectAgencyDTO> projectAgencyClosedTotalList = projectService.getAgencyClosedProjectTotal(customerId, dateString); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//已结案项目增量
 | 
					 | 
					 | 
							//已结案项目增量
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<ProjectAgencyDTO> projectAgencyClosedIncList = projectService.getAgencyClosedProjectInc(customerId, dateString); | 
					 | 
					 | 
							List<ProjectAgencyDTO> projectAgencyClosedIncList = projectService.getAgencyClosedProjectInc(customerId, dateString); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取日期相关维度
 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<FactIssueAgencyDailyEntity> list = new ArrayList<>(); | 
					 | 
					 | 
							List<FactIssueAgencyDailyEntity> list = new ArrayList<>(); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							for (DimAgencyDTO agency : agencyList) { | 
					 | 
					 | 
							for (DimAgencyDTO agency : agencyList) { | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -149,7 +151,7 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								list.add(entity); | 
					 | 
					 | 
								list.add(entity); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//批量插入
 | 
					 | 
					 | 
							//批量插入
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
							factIssueAgencyDailyService.insertBatch(list); | 
					 | 
					 | 
							factIssueAgencyDailyService.saveList(list); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						@Override | 
					 | 
					 | 
						@Override | 
				
			
			
		
	
	
		
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
					@ -157,6 +159,10 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							String dateString = DateUtils.format(date); | 
					 | 
					 | 
							String dateString = DateUtils.format(date); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							DimAgencyDTO dimAgencyDTO = new DimAgencyDTO(); | 
					 | 
					 | 
							DimAgencyDTO dimAgencyDTO = new DimAgencyDTO(); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							dimAgencyDTO.setCustomerId(customerId); | 
					 | 
					 | 
							dimAgencyDTO.setCustomerId(customerId); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							//获取日期相关维度
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							//清空数据
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							factIssueAgencyMonthlyService.deleteByCustomerId(customerId, dimId.getMonthId()); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取当前客户下所有机关
 | 
					 | 
					 | 
							//获取当前客户下所有机关
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<DimAgencyDTO> agencyList = dimAgencyService.getDimAgencyList(dimAgencyDTO); | 
					 | 
					 | 
							List<DimAgencyDTO> agencyList = dimAgencyService.getDimAgencyList(dimAgencyDTO); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取机关下议题各种状态的数目统计
 | 
					 | 
					 | 
							//获取机关下议题各种状态的数目统计
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
					@ -165,11 +171,8 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<IssueAgencyDTO> issueAgencyClosedTotalList = issueService.getAgencyClosedIssueTotal(customerId, dateString); | 
					 | 
					 | 
							List<IssueAgencyDTO> issueAgencyClosedTotalList = issueService.getAgencyClosedIssueTotal(customerId, dateString); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//已结案项目统计
 | 
					 | 
					 | 
							//已结案项目统计
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<ProjectAgencyDTO> projectAgencyClosedTotalList = projectService.getAgencyClosedProjectTotal(customerId, dateString); | 
					 | 
					 | 
							List<ProjectAgencyDTO> projectAgencyClosedTotalList = projectService.getAgencyClosedProjectTotal(customerId, dateString); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取日期相关维度
 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//统计机关下议题各个指标月度增量
 | 
					 | 
					 | 
							//统计机关下议题各个指标月度增量
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<FactIssueAgencyMonthlyDTO> issueAgencyMonthlyIncList = factIssueAgencyMonthlyService.getAgencyMonthlyInc(customerId, dimId.getMonthId()); | 
					 | 
					 | 
							List<FactIssueAgencyMonthlyDTO> issueAgencyMonthlyIncList = factIssueAgencyMonthlyService.getAgencyMonthlyInc(customerId, dimId.getMonthId()); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<FactIssueAgencyMonthlyEntity> list = new ArrayList<>(); | 
					 | 
					 | 
							List<FactIssueAgencyMonthlyEntity> list = new ArrayList<>(); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							for (DimAgencyDTO agency : agencyList) { | 
					 | 
					 | 
							for (DimAgencyDTO agency : agencyList) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								FactIssueAgencyDailyEntity daily = initIssueAgencyDaily(dimId); | 
					 | 
					 | 
								FactIssueAgencyDailyEntity daily = initIssueAgencyDaily(dimId); | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -215,7 +218,7 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								list.add(monthly); | 
					 | 
					 | 
								list.add(monthly); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//批量插入
 | 
					 | 
					 | 
							//批量插入
 | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
							factIssueAgencyMonthlyService.insertBatch(list); | 
					 | 
					 | 
							factIssueAgencyMonthlyService.saveList(list); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						@Override | 
					 | 
					 | 
						@Override | 
				
			
			
		
	
	
		
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
					@ -225,6 +228,8 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							dimAgencyDTO.setCustomerId(customerId); | 
					 | 
					 | 
							dimAgencyDTO.setCustomerId(customerId); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取日期相关维度
 | 
					 | 
					 | 
							//获取日期相关维度
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date); | 
					 | 
					 | 
							DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							//清空数据
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							factIssueGridDailyService.deleteByCustomerId(customerId, dimId.getDateId()); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取客户下所有网格数据
 | 
					 | 
					 | 
							//获取客户下所有网格数据
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<DimGridEntity> gridList = dimGridService.getGridListByCustomerId(customerId); | 
					 | 
					 | 
							List<DimGridEntity> gridList = dimGridService.getGridListByCustomerId(customerId); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取网格下议题各种状态的数目统计
 | 
					 | 
					 | 
							//获取网格下议题各种状态的数目统计
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
					@ -241,6 +246,7 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<ProjectGridDTO> closedProjectTotalList = projectService.getGridClosedProjectTotal(customerId, dateString); | 
					 | 
					 | 
							List<ProjectGridDTO> closedProjectTotalList = projectService.getGridClosedProjectTotal(customerId, dateString); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//已结案项目增量
 | 
					 | 
					 | 
							//已结案项目增量
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<ProjectGridDTO> closedProjectIncList = projectService.getGridClosedProjectTotal(customerId, dateString); | 
					 | 
					 | 
							List<ProjectGridDTO> closedProjectIncList = projectService.getGridClosedProjectTotal(customerId, dateString); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							Map<String, Long> resolveMap= new HashMap<>(); | 
					 | 
					 | 
							Map<String, Long> resolveMap= new HashMap<>(); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							Map<String, Long> unResolveMap = new HashMap<>(); | 
					 | 
					 | 
							Map<String, Long> unResolveMap = new HashMap<>(); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							Map<String, Long> resolveIncMap = new HashMap<>(); | 
					 | 
					 | 
							Map<String, Long> resolveIncMap = new HashMap<>(); | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -313,7 +319,7 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								saveClosedProject(resolveMap, unResolveMap, resolveIncMap, unResolveIncMap, grid, entity); | 
					 | 
					 | 
								saveClosedProject(resolveMap, unResolveMap, resolveIncMap, unResolveIncMap, grid, entity); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								list.add(entity); | 
					 | 
					 | 
								list.add(entity); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
							factIssueGridDailyService.insertBatch(list); | 
					 | 
					 | 
							factIssueGridDailyService.saveList(list); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						@Override | 
					 | 
					 | 
						@Override | 
				
			
			
		
	
	
		
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
					@ -323,6 +329,8 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							dimAgencyDTO.setCustomerId(customerId); | 
					 | 
					 | 
							dimAgencyDTO.setCustomerId(customerId); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取日期相关维度
 | 
					 | 
					 | 
							//获取日期相关维度
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date); | 
					 | 
					 | 
							DimIdGenerator.DimIdBean dimId = DimIdGenerator.getDimIdBean(date); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							//清空数据
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
							factIssueGridMonthlyService.deleteByCustomerId(customerId, dimId.getMonthId()); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取客户下所有网格数据
 | 
					 | 
					 | 
							//获取客户下所有网格数据
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							List<DimGridEntity> gridList = dimGridService.getGridListByCustomerId(customerId); | 
					 | 
					 | 
							List<DimGridEntity> gridList = dimGridService.getGridListByCustomerId(customerId); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							//获取网格下议题各种状态的数目统计
 | 
					 | 
					 | 
							//获取网格下议题各种状态的数目统计
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -383,12 +391,11 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								monthly.setClosedCaseResolvedTotal(resolve); | 
					 | 
					 | 
								monthly.setClosedCaseResolvedTotal(resolve); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								monthly.setClosedCaseUnresolvedTotal(unResolve); | 
					 | 
					 | 
								monthly.setClosedCaseUnresolvedTotal(unResolve); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								if(total > NumConstant.ZERO) { | 
					 | 
					 | 
								if(total > NumConstant.ZERO) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
									BigDecimal hundred = new BigDecimal(NumConstant.ONE_HUNDRED); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
									BigDecimal resolved = new BigDecimal(resolve); | 
					 | 
					 | 
									BigDecimal resolved = new BigDecimal(resolve); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
									BigDecimal unresolved = new BigDecimal(unResolve); | 
					 | 
					 | 
									BigDecimal unresolved = new BigDecimal(unResolve); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
									BigDecimal closed = new BigDecimal(total); | 
					 | 
					 | 
									BigDecimal closed = new BigDecimal(total); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
									monthly.setClosedCaseResolvedPercent(resolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
									monthly.setClosedCaseResolvedPercent(resolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
									monthly.setClosedCaseUnresolvedPercent(unresolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
									monthly.setClosedCaseUnresolvedPercent(unresolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					 | 
					 | 
								} | 
					 | 
					 | 
								} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								//各指标增量统计
 | 
					 | 
					 | 
								//各指标增量统计
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
					@ -413,7 +420,7 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								monthly.setGridId(grid.getId()); | 
					 | 
					 | 
								monthly.setGridId(grid.getId()); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								list.add(monthly); | 
					 | 
					 | 
								list.add(monthly); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
							factIssueGridMonthlyService.insertBatch(list); | 
					 | 
					 | 
							factIssueGridMonthlyService.saveList(list); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						/** | 
					 | 
					 | 
						/** | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -443,12 +450,11 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedCaseResolvedIncr(resolveInc); | 
					 | 
					 | 
							entity.setClosedCaseResolvedIncr(resolveInc); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedCaseUnresolvedIncr(unResolveInc); | 
					 | 
					 | 
							entity.setClosedCaseUnresolvedIncr(unResolveInc); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							if(total != NumConstant.ZERO) { | 
					 | 
					 | 
							if(total != NumConstant.ZERO) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal hundred = new BigDecimal(NumConstant.ONE_HUNDRED); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal resolved = new BigDecimal(resolve); | 
					 | 
					 | 
								BigDecimal resolved = new BigDecimal(resolve); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal unresolved = new BigDecimal(unResolve); | 
					 | 
					 | 
								BigDecimal unresolved = new BigDecimal(unResolve); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal closed = new BigDecimal(total); | 
					 | 
					 | 
								BigDecimal closed = new BigDecimal(total); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedCaseResolvedPercent(resolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedCaseResolvedPercent(resolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedCaseUnresolvedPercent(unresolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedCaseUnresolvedPercent(unresolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -513,12 +519,11 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedResolvedTotal(resolvedCount); | 
					 | 
					 | 
							entity.setClosedResolvedTotal(resolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedUnresolvedTotal(unresolvedCount); | 
					 | 
					 | 
							entity.setClosedUnresolvedTotal(unresolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							if(entity.getClosedTotal() > NumConstant.ZERO) { | 
					 | 
					 | 
							if(entity.getClosedTotal() > NumConstant.ZERO) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal hundred = new BigDecimal(NumConstant.ONE_HUNDRED); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal resolved = new BigDecimal(resolvedCount); | 
					 | 
					 | 
								BigDecimal resolved = new BigDecimal(resolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal unresolved = new BigDecimal(unresolvedCount); | 
					 | 
					 | 
								BigDecimal unresolved = new BigDecimal(unresolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal closed = new BigDecimal(entity.getClosedTotal()); | 
					 | 
					 | 
								BigDecimal closed = new BigDecimal(entity.getClosedTotal()); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedResolvedPercent(resolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedResolvedPercent(resolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedUnresolvedPercent(unresolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedUnresolvedPercent(unresolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -597,14 +602,13 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedTotal(closedCount); | 
					 | 
					 | 
							entity.setClosedTotal(closedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setIssueTotal(issueTotal); | 
					 | 
					 | 
							entity.setIssueTotal(issueTotal); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							if (NumConstant.ZERO != issueTotal) { | 
					 | 
					 | 
							if (NumConstant.ZERO != issueTotal) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal hundred = new BigDecimal(NumConstant.ONE_HUNDRED); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal voting = new BigDecimal(votingCount); | 
					 | 
					 | 
								BigDecimal voting = new BigDecimal(votingCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal shift = new BigDecimal(shiftCount); | 
					 | 
					 | 
								BigDecimal shift = new BigDecimal(shiftCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal closed = new BigDecimal(closedCount); | 
					 | 
					 | 
								BigDecimal closed = new BigDecimal(closedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal total = new BigDecimal(issueTotal); | 
					 | 
					 | 
								BigDecimal total = new BigDecimal(issueTotal); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setVotingPercent(voting.multiply(hundred).divide(total, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setVotingPercent(voting.divide(total, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setShiftProjectPercent(shift.multiply(hundred).divide(total, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setShiftProjectPercent(shift.divide(total, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedPercent(closed.multiply(hundred).divide(total, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedPercent(closed.divide(total, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -676,12 +680,11 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedCaseUnresolvedTotal(unresolvedCount); | 
					 | 
					 | 
							entity.setClosedCaseUnresolvedTotal(unresolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedCaseTotal(total); | 
					 | 
					 | 
							entity.setClosedCaseTotal(total); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							if (total > NumConstant.ZERO) { | 
					 | 
					 | 
							if (total > NumConstant.ZERO) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal hundred = new BigDecimal(NumConstant.ONE_HUNDRED); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal resolved = new BigDecimal(resolvedCount); | 
					 | 
					 | 
								BigDecimal resolved = new BigDecimal(resolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal unresolved = new BigDecimal(unresolvedCount); | 
					 | 
					 | 
								BigDecimal unresolved = new BigDecimal(unresolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal closed = new BigDecimal(total); | 
					 | 
					 | 
								BigDecimal closed = new BigDecimal(total); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedCaseResolvedPercent(resolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedCaseResolvedPercent(resolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedCaseUnresolvedPercent(unresolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedCaseUnresolvedPercent(unresolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -763,14 +766,13 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedTotal(closedCount); | 
					 | 
					 | 
							entity.setClosedTotal(closedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setIssueTotal(issueTotal); | 
					 | 
					 | 
							entity.setIssueTotal(issueTotal); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							if (NumConstant.ZERO != issueTotal) { | 
					 | 
					 | 
							if (NumConstant.ZERO != issueTotal) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal hundred = new BigDecimal(NumConstant.ONE_HUNDRED); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal voting = new BigDecimal(votingCount); | 
					 | 
					 | 
								BigDecimal voting = new BigDecimal(votingCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal shift = new BigDecimal(shiftCount); | 
					 | 
					 | 
								BigDecimal shift = new BigDecimal(shiftCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal closed = new BigDecimal(closedCount); | 
					 | 
					 | 
								BigDecimal closed = new BigDecimal(closedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal total = new BigDecimal(issueTotal); | 
					 | 
					 | 
								BigDecimal total = new BigDecimal(issueTotal); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setVotingPercent(voting.multiply(hundred).divide(total, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setVotingPercent(voting.divide(total, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setShiftProjectPercent(shift.multiply(hundred).divide(total, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setShiftProjectPercent(shift.divide(total, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedPercent(closed.multiply(hundred).divide(total, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedPercent(closed.divide(total, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
	
		
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -806,12 +808,11 @@ public class StatsIssueServiceImpl implements StatsIssueService { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedResolvedTotal(resolvedCount); | 
					 | 
					 | 
							entity.setClosedResolvedTotal(resolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							entity.setClosedUnresolvedTotal(unresolvedCount); | 
					 | 
					 | 
							entity.setClosedUnresolvedTotal(unresolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
							if (entity.getClosedTotal() > NumConstant.ZERO) { | 
					 | 
					 | 
							if (entity.getClosedTotal() > NumConstant.ZERO) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal hundred = new BigDecimal(NumConstant.ONE_HUNDRED); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal resolved = new BigDecimal(resolvedCount); | 
					 | 
					 | 
								BigDecimal resolved = new BigDecimal(resolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal unresolved = new BigDecimal(unresolvedCount); | 
					 | 
					 | 
								BigDecimal unresolved = new BigDecimal(unresolvedCount); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
								BigDecimal closed = new BigDecimal(entity.getClosedTotal()); | 
					 | 
					 | 
								BigDecimal closed = new BigDecimal(entity.getClosedTotal()); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedResolvedPercent(resolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedResolvedPercent(resolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
								entity.setClosedUnresolvedPercent(unresolved.multiply(hundred).divide(closed, NumConstant.TWO, RoundingMode.HALF_UP)); | 
					 | 
					 | 
								entity.setClosedUnresolvedPercent(unresolved.divide(closed, NumConstant.SIX, RoundingMode.HALF_UP)); | 
				
			
			
				
				
			
		
	
		
		
	
		
		
	
		
		
			
				
					 | 
					 | 
							} | 
					 | 
					 | 
							} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
						} | 
					 | 
					 | 
						} | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					
 | 
					 | 
					 | 
					
 | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
					
  |