| 
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -162,22 +162,11 @@ public class CpcIndexCalculateServiceImpl implements CpcIndexCalculateService { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        do { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            list = factIndexPartyAblityCpcMonthlyDao.getCountByMonthId(formDTO.getCustomerId(), formDTO.getMonthId(), (pageNo - 1) * pageSize, pageSize); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            if (!CollectionUtils.isEmpty(list)) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                //如果是第一页且仅有一条数据 则直接给50分
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                if (pageNo == NumConstant.ONE && list.size() == NumConstant.ONE) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    List<CpcScoreEntity> insertList = new ArrayList<>(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    for (String indexCode : groupIndexDetailsMap.keySet()) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                        insertList.add(handleOneGridScene(formDTO, indexCode, list.get(0))); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    if (CollectionUtils.isEmpty(insertList)) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                        deleteAndInsertBatch(formDTO, insertList, null); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                } else { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    //遍历指标分组 计算分数
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    for (Map.Entry<String, List<IndexGroupDetailEntity>> entry : groupIndexDetailsMap.entrySet()) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                        String indexCode = entry.getKey(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                        List<IndexGroupDetailEntity> details = entry.getValue(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                        calculateScore(formDTO, details, list, minAndMaxMap, indexCode); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                //遍历指标分组 计算分数
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                for (Map.Entry<String, List<IndexGroupDetailEntity>> entry : groupIndexDetailsMap.entrySet()) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    String indexCode = entry.getKey(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    List<IndexGroupDetailEntity> details = entry.getValue(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    calculateScore(formDTO, details, list, minAndMaxMap, indexCode); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            pageNo++; | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
				
				 | 
				
					
  |