| 
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -40,6 +40,7 @@ import com.epmet.commons.tools.redis.common.CustomerOrgRedis; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.commons.tools.redis.common.CustomerStaffRedis; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.commons.tools.redis.common.bean.GridInfoCache; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.commons.tools.security.dto.TokenDto; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.commons.tools.security.user.LoginUserUtil; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.commons.tools.utils.ConvertUtils; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.commons.tools.utils.Result; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					import com.epmet.constant.CustomerGridConstant; | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -98,6 +99,8 @@ public class CustomerGridServiceImpl extends BaseServiceImpl<CustomerGridDao, Cu | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    private RedisUtils redisUtils; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    @Autowired | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    private EpmetAdminOpenFeignClient adminOpenFeignClient; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    @Autowired | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    private LoginUserUtil loginUserUtil; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					    //迁移网格
 | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
				
				 | 
				
					@ -990,9 +993,8 @@ public class CustomerGridServiceImpl extends BaseServiceImpl<CustomerGridDao, Cu | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					        try { | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            //根据网格id 获取网格内工作人员及其添加关系
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            List<StaffOrgRelationDTO> staffList = customerStaffGridDao.getGridStaffList(gridId); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            if (CollectionUtils.isEmpty(staffList)){ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                log.info("abandonGridForDealBizData gridId:{} have any staff", gridId); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                return; | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            if (staffList == null){ | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                staffList = new ArrayList<>(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            } | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            logger.debug("abandonGridForDealBizData staffList:{}", JSON.toJSONString(staffList)); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            List<StaffOrgRelationEntity> updateList = new ArrayList<>(); | 
				
			
			
		
	
	
		
			
				
					| 
						
						
						
							
								
							
						
					 | 
				
				 | 
				
					@ -1013,8 +1015,8 @@ public class CustomerGridServiceImpl extends BaseServiceImpl<CustomerGridDao, Cu | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                entity.setOrgId(gridInfo.getPid()); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					                updateList.add(entity); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            }); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            String customerId = loginUserUtil.getLoginUserCustomerId(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            //更新工作人员组织关系
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            String customerId = staffList.get(NumConstant.ZERO).getCustomerId(); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            dealBizDataForAbandon(customerId,gridId, staffList, updateList); | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            //清空工作人员缓存
 | 
				
			
			
		
	
		
			
				
					 | 
					 | 
				
				 | 
				
					            staffList.forEach(staff->CustomerStaffRedis.delStaffInfoFormCache(customerId,staff.getStaffId())); | 
				
			
			
		
	
	
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
				
				 | 
				
					
  |