|
@ -328,11 +328,11 @@ public class GroupInvitationServiceImpl extends BaseServiceImpl<GroupInvitationD |
|
|
GroupInvitationDTO groupInvitationDTO = this.get(invitationId); |
|
|
GroupInvitationDTO groupInvitationDTO = this.get(invitationId); |
|
|
//Date1.after(Date2),当Date1大于Date2时,返回TRUE,当小于等于时,返回false;
|
|
|
//Date1.after(Date2),当Date1大于Date2时,返回TRUE,当小于等于时,返回false;
|
|
|
if (null == groupInvitationDTO) { |
|
|
if (null == groupInvitationDTO) { |
|
|
logger.error(String.format("根据链接【%s】查看群邀请信息异常,错误码:%s,错误提示:%s",invitationId,EpmetErrorCode.LOSE_EFFICACY.getCode(), EpmetErrorCode.LOSE_EFFICACY.getMsg())); |
|
|
logger.warn(String.format("根据链接【%s】查看群邀请信息异常,错误码:%s,错误提示:%s",invitationId,EpmetErrorCode.LOSE_EFFICACY.getCode(), EpmetErrorCode.LOSE_EFFICACY.getMsg())); |
|
|
throw new RenException(EpmetErrorCode.LOSE_EFFICACY.getCode()); |
|
|
throw new RenException(EpmetErrorCode.LOSE_EFFICACY.getCode()); |
|
|
} |
|
|
} |
|
|
if (null != groupInvitationDTO && !groupInvitationDTO.getValidEndTime().after(new Date())) { |
|
|
if (null != groupInvitationDTO && !groupInvitationDTO.getValidEndTime().after(new Date())) { |
|
|
logger.error(String.format("根据链接【%s】查看群邀请信息异常,错误码:%s,错误提示:%s",invitationId,EpmetErrorCode.LOSE_EFFICACY.getCode(), EpmetErrorCode.LOSE_EFFICACY.getMsg())); |
|
|
logger.warn(String.format("根据链接【%s】查看群邀请信息异常,错误码:%s,错误提示:%s",invitationId,EpmetErrorCode.LOSE_EFFICACY.getCode(), EpmetErrorCode.LOSE_EFFICACY.getMsg())); |
|
|
throw new RenException(EpmetErrorCode.LOSE_EFFICACY.getCode()); |
|
|
throw new RenException(EpmetErrorCode.LOSE_EFFICACY.getCode()); |
|
|
} |
|
|
} |
|
|
/*ResiGroupEntity resiGroupEntity = resiGroupDao.selectById(groupInvitationDTO.getResiGroupId()); |
|
|
/*ResiGroupEntity resiGroupEntity = resiGroupDao.selectById(groupInvitationDTO.getResiGroupId()); |
|
@ -369,7 +369,7 @@ public class GroupInvitationServiceImpl extends BaseServiceImpl<GroupInvitationD |
|
|
//3、进入小组所在的网格
|
|
|
//3、进入小组所在的网格
|
|
|
ResiGroupDTO resiGroupDTO = resiGroupService.get(groupInvitationDTO.getResiGroupId()); |
|
|
ResiGroupDTO resiGroupDTO = resiGroupService.get(groupInvitationDTO.getResiGroupId()); |
|
|
if(null==resiGroupDTO){ |
|
|
if(null==resiGroupDTO){ |
|
|
logger.error(String.format("用户同意邀请进组,查询组信息失败。入参:userId【%s】、invitationId【%s】、groupId【%s】。",formDTO.getUserId(),formDTO.getInvitationId(),groupInvitationDTO.getResiGroupId())); |
|
|
logger.warn(String.format("用户同意邀请进组,查询组信息失败。入参:userId【%s】、invitationId【%s】、groupId【%s】。",formDTO.getUserId(),formDTO.getInvitationId(),groupInvitationDTO.getResiGroupId())); |
|
|
throw new RenException(EpmetErrorCode.LOSE_EFFICACY.getCode()); |
|
|
throw new RenException(EpmetErrorCode.LOSE_EFFICACY.getCode()); |
|
|
} |
|
|
} |
|
|
UserEnterGridFormDTO userEnterGridFormDTO=new UserEnterGridFormDTO(); |
|
|
UserEnterGridFormDTO userEnterGridFormDTO=new UserEnterGridFormDTO(); |
|
@ -377,11 +377,11 @@ public class GroupInvitationServiceImpl extends BaseServiceImpl<GroupInvitationD |
|
|
userEnterGridFormDTO.setGridId(resiGroupDTO.getGridId()); |
|
|
userEnterGridFormDTO.setGridId(resiGroupDTO.getGridId()); |
|
|
Result<UserInfoOnEnterGridResultDTO> result=resiGuideFeignClient.enterGrid(userEnterGridFormDTO); |
|
|
Result<UserInfoOnEnterGridResultDTO> result=resiGuideFeignClient.enterGrid(userEnterGridFormDTO); |
|
|
if (!result.success() || null == result.getData()) { |
|
|
if (!result.success() || null == result.getData()) { |
|
|
logger.error(String.format("用户同意邀请进组,进入网格失败。入参:userId【%s】、invitationId【%s】、groupId【%s】、customerId【%s】、gridId【%s】", |
|
|
logger.warn(String.format("用户同意邀请进组,进入网格失败。入参:userId【%s】、invitationId【%s】、groupId【%s】、customerId【%s】、gridId【%s】", |
|
|
formDTO.getUserId(), formDTO.getInvitationId(), |
|
|
formDTO.getUserId(), formDTO.getInvitationId(), |
|
|
groupInvitationDTO.getResiGroupId()), |
|
|
groupInvitationDTO.getResiGroupId()), |
|
|
resiGroupDTO.getCustomerId(), resiGroupDTO.getGridId()); |
|
|
resiGroupDTO.getCustomerId(), resiGroupDTO.getGridId()); |
|
|
logger.error(String.format("用户同意邀请进组,进入网格失败。当前接口返回8000,调用enterGrid接口返回", result.toString())); |
|
|
logger.warn(String.format("用户同意邀请进组,进入网格失败。当前接口返回8000,调用enterGrid接口返回", result.toString())); |
|
|
throw new RenException(EpmetErrorCode.SERVER_ERROR.getCode()); |
|
|
throw new RenException(EpmetErrorCode.SERVER_ERROR.getCode()); |
|
|
} |
|
|
} |
|
|
//4、校验是否已经注册居民
|
|
|
//4、校验是否已经注册居民
|
|
@ -463,7 +463,7 @@ public class GroupInvitationServiceImpl extends BaseServiceImpl<GroupInvitationD |
|
|
//3、进入小组所在的网格
|
|
|
//3、进入小组所在的网格
|
|
|
ResiGroupDTO resiGroupDTO = resiGroupService.get(groupInvitationDTO.getResiGroupId()); |
|
|
ResiGroupDTO resiGroupDTO = resiGroupService.get(groupInvitationDTO.getResiGroupId()); |
|
|
if(null==resiGroupDTO){ |
|
|
if(null==resiGroupDTO){ |
|
|
logger.error(String.format("用户同意邀请进组,查询组信息失败。入参:userId【%s】、invitationId【%s】、groupId【%s】。",formDTO.getUserId(),formDTO.getInvitationId(),groupInvitationDTO.getResiGroupId())); |
|
|
logger.warn(String.format("用户同意邀请进组,查询组信息失败。入参:userId【%s】、invitationId【%s】、groupId【%s】。",formDTO.getUserId(),formDTO.getInvitationId(),groupInvitationDTO.getResiGroupId())); |
|
|
throw new RenException(EpmetErrorCode.LOSE_EFFICACY.getCode()); |
|
|
throw new RenException(EpmetErrorCode.LOSE_EFFICACY.getCode()); |
|
|
} |
|
|
} |
|
|
UserEnterGridFormDTO userEnterGridFormDTO=new UserEnterGridFormDTO(); |
|
|
UserEnterGridFormDTO userEnterGridFormDTO=new UserEnterGridFormDTO(); |
|
@ -471,11 +471,11 @@ public class GroupInvitationServiceImpl extends BaseServiceImpl<GroupInvitationD |
|
|
userEnterGridFormDTO.setGridId(resiGroupDTO.getGridId()); |
|
|
userEnterGridFormDTO.setGridId(resiGroupDTO.getGridId()); |
|
|
Result<UserInfoOnEnterGridResultDTO> result=resiGuideFeignClient.enterGrid(userEnterGridFormDTO); |
|
|
Result<UserInfoOnEnterGridResultDTO> result=resiGuideFeignClient.enterGrid(userEnterGridFormDTO); |
|
|
if (!result.success() || null == result.getData()) { |
|
|
if (!result.success() || null == result.getData()) { |
|
|
logger.error(String.format("用户同意邀请进组,进入网格失败。入参:userId【%s】、invitationId【%s】、groupId【%s】、customerId【%s】、gridId【%s】", |
|
|
logger.warn(String.format("用户同意邀请进组,进入网格失败。入参:userId【%s】、invitationId【%s】、groupId【%s】、customerId【%s】、gridId【%s】", |
|
|
formDTO.getUserId(), formDTO.getInvitationId(), |
|
|
formDTO.getUserId(), formDTO.getInvitationId(), |
|
|
groupInvitationDTO.getResiGroupId()), |
|
|
groupInvitationDTO.getResiGroupId()), |
|
|
resiGroupDTO.getCustomerId(), resiGroupDTO.getGridId()); |
|
|
resiGroupDTO.getCustomerId(), resiGroupDTO.getGridId()); |
|
|
logger.error(String.format("用户同意邀请进组,进入网格失败。当前接口返回8000,调用enterGrid接口返回", result.toString())); |
|
|
logger.warn(String.format("用户同意邀请进组,进入网格失败。当前接口返回8000,调用enterGrid接口返回", result.toString())); |
|
|
throw new RenException(EpmetErrorCode.SERVER_ERROR.getCode()); |
|
|
throw new RenException(EpmetErrorCode.SERVER_ERROR.getCode()); |
|
|
} |
|
|
} |
|
|
//4、校验是否已经注册居民
|
|
|
//4、校验是否已经注册居民
|
|
@ -629,7 +629,7 @@ public class GroupInvitationServiceImpl extends BaseServiceImpl<GroupInvitationD |
|
|
if (result.success()) { |
|
|
if (result.success()) { |
|
|
logger.info("通知群主有新成员入群成功"); |
|
|
logger.info("通知群主有新成员入群成功"); |
|
|
} else { |
|
|
} else { |
|
|
logger.error("通知群主有新成员入群失败" + result.getMsg()); |
|
|
logger.warn("通知群主有新成员入群失败" + result.getMsg()); |
|
|
} |
|
|
} |
|
|
return result; |
|
|
return result; |
|
|
} |
|
|
} |
|
|