| 
						
						
							
								
							
						
						
					 | 
					@ -41,7 +41,6 @@ import com.epmet.dto.result.*; | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					import com.epmet.entity.*; | 
					 | 
					 | 
					import com.epmet.entity.*; | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					import com.epmet.feign.EpmetUserOpenFeignClient; | 
					 | 
					 | 
					import com.epmet.feign.EpmetUserOpenFeignClient; | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					import com.epmet.feign.GovOrgOpenFeignClient; | 
					 | 
					 | 
					import com.epmet.feign.GovOrgOpenFeignClient; | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					import com.epmet.feign.GovProjectOpenFeignClient; | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					import com.epmet.service.ResiEventService; | 
					 | 
					 | 
					import com.epmet.service.ResiEventService; | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					import com.github.pagehelper.PageHelper; | 
					 | 
					 | 
					import com.github.pagehelper.PageHelper; | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					import com.github.pagehelper.PageInfo; | 
					 | 
					 | 
					import com.github.pagehelper.PageInfo; | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
							
								
							
						
						
					 | 
					@ -114,17 +113,25 @@ public class ResiEventServiceImpl extends BaseServiceImpl<ResiEventDao, ResiEven | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					    @Override | 
					 | 
					 | 
					    @Override | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					    public void updateViewTime(UpdateViewTimeFormDTO formDTO) { | 
					 | 
					 | 
					    public void updateViewTime(UpdateViewTimeFormDTO formDTO) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					        ResiEventEntity eventEntity=baseDao.selectById(formDTO.getEventId()); | 
					 | 
					 | 
					        ResiEventEntity eventEntity=baseDao.selectById(formDTO.getEventId()); | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					        if(null!=eventEntity){ | 
					 | 
					 | 
					        if (null == eventEntity) { | 
				
			
			
				
				
			
		
	
		
		
			
				
					
					 | 
					 | 
					            eventEntity.setReadFlag(true); | 
					 | 
					 | 
					            throw new RenException(String.format("没有找到事件记录,eventId:%s",formDTO.getEventId())); | 
				
			
			
				
				
			
		
	
		
		
			
				
					 | 
					 | 
					            baseDao.updateById(eventEntity); | 
					 | 
					 | 
					 | 
				
			
			
		
	
		
		
	
		
		
	
		
		
			
				
					 | 
					 | 
					        } | 
					 | 
					 | 
					        } | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					        if(formDTO.getUserId().equals(eventEntity.getReportUserId())){ | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					            log.warn("报事人查看详情不需要调用此接口"); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					            return; | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					        } | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					        // 这个事件已经被查看了
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					        eventEntity.setReadFlag(true); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					        baseDao.updateById(eventEntity); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					        // 居民端:resi_user;工作端:staff
 | 
					 | 
					 | 
					        // 居民端:resi_user;工作端:staff
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					        if(EventConstant.RESI_USER.equals(formDTO.getViewType())){ | 
					 | 
					 | 
					        if(EventConstant.RESI_USER.equals(formDTO.getViewType())){ | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					            //被@的人置为已读
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					            resiEventMentionDao.updateReadFlag(formDTO.getEventId(),formDTO.getUserId()); | 
					 | 
					 | 
					            resiEventMentionDao.updateReadFlag(formDTO.getEventId(),formDTO.getUserId()); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					        }else if(EventConstant.STAFF.equals(formDTO.getViewType())){ | 
					 | 
					 | 
					        }else if(EventConstant.STAFF.equals(formDTO.getViewType())){ | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					 | 
					 | 
					 | 
					            // 当前组织置为已读
 | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					            resiEventReportOrgDao.updateReadFlag(formDTO.getEventId(),formDTO.getOrgId(),formDTO.getUserId()); | 
					 | 
					 | 
					            resiEventReportOrgDao.updateReadFlag(formDTO.getEventId(),formDTO.getOrgId(),formDTO.getUserId()); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					        } | 
					 | 
					 | 
					        } | 
				
			
			
		
	
		
		
			
				
					
					 | 
					 | 
					        // 插入查看日志
 | 
					 | 
					 | 
					        // 插入首次查看日志
 | 
				
			
			
				
				
			
		
	
		
		
	
		
		
			
				
					 | 
					 | 
					        List<ResiEventOperationLogEntity> logEntityList = resiEventOperationLogDao.selectByUserAction(formDTO.getEventId(), formDTO.getUserId(), ResiEventAction.READ_FIRST.getCode()); | 
					 | 
					 | 
					        List<ResiEventOperationLogEntity> logEntityList = resiEventOperationLogDao.selectByUserAction(formDTO.getEventId(), formDTO.getUserId(), ResiEventAction.READ_FIRST.getCode()); | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					        if (CollectionUtils.isEmpty(logEntityList)) { | 
					 | 
					 | 
					        if (CollectionUtils.isEmpty(logEntityList)) { | 
				
			
			
		
	
		
		
			
				
					 | 
					 | 
					            ResiEventOperationLogEntity publishLog=new ResiEventOperationLogEntity(); | 
					 | 
					 | 
					            ResiEventOperationLogEntity publishLog=new ResiEventOperationLogEntity(); | 
				
			
			
		
	
	
		
		
			
				
					| 
						
							
								
							
						
						
						
					 | 
					
  |