|
|
@ -4,20 +4,34 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; |
|
|
|
import com.baomidou.mybatisplus.core.metadata.IPage; |
|
|
|
import com.epmet.commons.mybatis.service.impl.BaseServiceImpl; |
|
|
|
import com.epmet.commons.tools.constant.FieldConstant; |
|
|
|
import com.epmet.commons.tools.dto.result.CustomerStaffInfoCacheResult; |
|
|
|
import com.epmet.commons.tools.enums.DictTypeEnum; |
|
|
|
import com.epmet.commons.tools.exception.EpmetException; |
|
|
|
import com.epmet.commons.tools.page.PageData; |
|
|
|
import com.epmet.commons.tools.redis.common.CustomerStaffRedis; |
|
|
|
import com.epmet.commons.tools.utils.ConvertUtils; |
|
|
|
import com.epmet.commons.tools.utils.Result; |
|
|
|
import com.epmet.dao.IcMessageDao; |
|
|
|
import com.epmet.dto.IcMessageDTO; |
|
|
|
import com.epmet.dto.form.IcMessageFormDTO; |
|
|
|
import com.epmet.dto.form.IcMessageListFormDTO; |
|
|
|
import com.epmet.dto.form.IcMoveInListFormDTO; |
|
|
|
import com.epmet.dto.result.AllGridsByUserIdResultDTO; |
|
|
|
import com.epmet.dto.result.HouseInfoDTO; |
|
|
|
import com.epmet.dto.result.IcMoveInListResultDTO; |
|
|
|
import com.epmet.entity.IcMessageEntity; |
|
|
|
import com.epmet.service.IcMessageService; |
|
|
|
import com.github.pagehelper.PageHelper; |
|
|
|
import com.github.pagehelper.PageInfo; |
|
|
|
import org.apache.commons.collections4.MapUtils; |
|
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
|
import org.springframework.stereotype.Service; |
|
|
|
import org.springframework.transaction.annotation.Transactional; |
|
|
|
import org.springframework.util.CollectionUtils; |
|
|
|
|
|
|
|
import java.util.Arrays; |
|
|
|
import java.util.List; |
|
|
|
import java.util.Map; |
|
|
|
import java.util.*; |
|
|
|
import java.util.function.Function; |
|
|
|
import java.util.stream.Collectors; |
|
|
|
|
|
|
|
/** |
|
|
|
* 用户消息表(党建小助手) |
|
|
@ -30,19 +44,11 @@ public class IcMessageServiceImpl extends BaseServiceImpl<IcMessageDao, IcMessag |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
public PageData<IcMessageDTO> page(Map<String, Object> params) { |
|
|
|
IPage<IcMessageEntity> page = baseDao.selectPage( |
|
|
|
getPage(params, FieldConstant.CREATED_TIME, false), |
|
|
|
getWrapper(params) |
|
|
|
); |
|
|
|
return getPageData(page, IcMessageDTO.class); |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
public List<IcMessageDTO> list(Map<String, Object> params) { |
|
|
|
List<IcMessageEntity> entityList = baseDao.selectList(getWrapper(params)); |
|
|
|
|
|
|
|
return ConvertUtils.sourceToTarget(entityList, IcMessageDTO.class); |
|
|
|
public PageData<IcMessageDTO> list(IcMessageListFormDTO formDTO) { |
|
|
|
PageHelper.startPage(formDTO.getPageNo(), formDTO.getPageSize(), formDTO.getIsPage()); |
|
|
|
List<IcMessageDTO> list = baseDao.selectMessageList(formDTO); |
|
|
|
PageInfo<IcMessageDTO> pageInfo = new PageInfo<>(list); |
|
|
|
return new PageData<>(list, pageInfo.getTotal()); |
|
|
|
} |
|
|
|
|
|
|
|
private QueryWrapper<IcMessageEntity> getWrapper(Map<String, Object> params){ |
|
|
|