| 
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -51,7 +51,6 @@ import org.springframework.beans.factory.annotation.Autowired; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import org.springframework.stereotype.Service; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import org.springframework.transaction.annotation.Transactional; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import org.springframework.util.CollectionUtils; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import org.springframework.web.bind.annotation.RequestBody; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import java.util.ArrayList; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import java.util.Date; | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -107,10 +106,11 @@ public class DepartmentServiceImpl implements DepartmentService { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        Result<AddDepartmentResultDTO> result = new Result<AddDepartmentResultDTO>(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        AddDepartmentResultDTO addDepartmentResultDTO = new AddDepartmentResultDTO(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        CustomerDepartmentEntity entity = ConvertUtils.sourceToTarget(formDTO, CustomerDepartmentEntity.class); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        if (formDTO.getTotalUser() > NumConstant.ZERO) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        if (null != formDTO.getTotalUser() && formDTO.getTotalUser() > NumConstant.ZERO) { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            entity.setTotalUser(formDTO.getTotalUser()); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        }else{ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            entity.setTotalUser(NumConstant.ZERO); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        entity.setTotalUser(NumConstant.ZERO); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        //1:查询当前组织机构信息,获取客户Id
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        CustomerAgencyEntity parentEntity = customerAgencyDao.selectById(formDTO.getAgencyId()); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        entity.setCustomerId(parentEntity.getCustomerId()); | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
				
				 | 
				
					
  |