| 
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -22,12 +22,17 @@ import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.constant.DataSourceConstant; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.dao.project.ProjectProcessDao; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.dto.project.ProcessInfoDTO; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.dto.project.result.ProjectOrgPeriodResultDTO; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.dto.project.result.ProjectOrgRelationWhenResponseResultDTO; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.entity.project.ProjectEntity; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.entity.project.ProjectProcessEntity; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.service.project.ProjectProcessService; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import org.springframework.stereotype.Service; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import org.springframework.util.CollectionUtils; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import java.util.List; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import java.util.Map; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import java.util.stream.Collectors; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					/** | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					 * 项目处理进展表 | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -68,4 +73,39 @@ public class ProjectProcessServiceImpl extends BaseServiceImpl<ProjectProcessDao | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    public List<ProjectProcessEntity> getClosedProjectList(String customerId, String date) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        return baseDao.selectClosedProjectList(customerId, date); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    /** | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					     * @Description 查询各机关项目节点历时 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					     * @param isFirst    是否首次 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					     * @param customerId | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					     * @param date | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					     * @return | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					     * @author wangc | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					     * @date 2020.09.18 13:38 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					     **/ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    @Override | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    public List<ProjectOrgPeriodResultDTO> getProjectPeriod(Boolean isFirst,String customerId, String date) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        List<ProjectOrgPeriodResultDTO> projectNodePeriodPerOrgList; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        if(isFirst){ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            projectNodePeriodPerOrgList = baseDao.selectProjectOrgPeriod(customerId,null,null); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        }else{ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            projectNodePeriodPerOrgList = baseDao.selectProjectOrgPeriod(customerId,null,date); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        if(!CollectionUtils.isEmpty(projectNodePeriodPerOrgList)){ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            List<String> projects = | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    projectNodePeriodPerOrgList.stream().map(ProjectOrgPeriodResultDTO::getProjectId).distinct().collect(Collectors.toList()); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            if(!projects.isEmpty()){ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                List<ProjectOrgRelationWhenResponseResultDTO> responseList = baseDao.selectResponseTrace(projects); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                Map<String,List<ProjectOrgRelationWhenResponseResultDTO>> sorted = | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                    responseList.stream().collect(Collectors.groupingBy(ProjectOrgRelationWhenResponseResultDTO::getProjectId)); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        return null; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					} |