diff --git a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/IcResiUserConfirmDTO.java b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/IcResiUserConfirmDTO.java index 39ee709284..db8f88ff7e 100644 --- a/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/IcResiUserConfirmDTO.java +++ b/epmet-user/epmet-user-client/src/main/java/com/epmet/dto/IcResiUserConfirmDTO.java @@ -187,4 +187,8 @@ public class IcResiUserConfirmDTO implements Serializable { */ private String operationDescribe; + /** + * 迁出申请状态 0未审核 1已通过 2未通过 3没有迁出申请 + */ + private String moveOutStatus; } diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserConfirmServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserConfirmServiceImpl.java index bb3fa9ab2c..08ccc28774 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserConfirmServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserConfirmServiceImpl.java @@ -1,5 +1,6 @@ package com.epmet.service.impl; +import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.metadata.IPage; import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; @@ -159,8 +160,20 @@ public class IcResiUserConfirmServiceImpl extends BaseServiceImpl getMemberDetail(IcResiUserConfirmGetDTO dto) { IcResiUserConfirmDTO result = icResiUserDao.selectMemberDetail(dto.getIcResiUserId()); - if (null != result && StringUtils.isBlank(result.getGender())) { - result.setGender(""); + if (null != result) { + LambdaQueryWrapper wrapper = new LambdaQueryWrapper<>(); + wrapper.eq(IcResiUserConfirmEntity::getIcResiUserId, dto.getIcResiUserId()); + wrapper.in(IcResiUserConfirmEntity::getSubmitType, Arrays.asList("in", "out")); + wrapper.orderByDesc(IcResiUserConfirmEntity::getCreatedTime); + List list = baseDao.selectList(wrapper); + if (CollectionUtils.isNotEmpty(list)) { + result.setMoveOutStatus(list.get(NumConstant.ZERO).getConfirmResult()); + } else { + result.setMoveOutStatus(NumConstant.THREE_STR); + } + if(StringUtils.isBlank(result.getGender())) { + result.setGender(""); + } } return new Result().ok(result); }