wzy
2020-05-18 f2b9c03ba8c733a183e3568d85038e9a87f84e82
src/main/java/com/xcong/excoin/modules/test/mapper/TestUserEntityMapper.java
@@ -1,10 +1,17 @@
package com.xcong.excoin.modules.test.mapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.xcong.excoin.modules.test.dto.TestUserDto;
import com.xcong.excoin.modules.test.entity.TestUserEntity;
import com.xcong.excoin.modules.test.vo.TestUserVo;
import com.xcong.excoin.modules.test.vo.TestVo;
import org.mapstruct.InheritInverseConfiguration;
import org.mapstruct.Mapper;
import org.mapstruct.Mapping;
import org.mapstruct.factory.Mappers;
import java.util.List;
/**
 * @author wzy
@@ -16,5 +23,14 @@
    public abstract TestUserEntity dtoToEntity(TestUserDto testUserDto);
    @Mapping(source = "name", target = "name")
    @Mapping(source = "password", target = "pwd")
    public abstract TestVo entityToTestVo(TestUserEntity testUserEntity);
    @Mapping(source = "name", target = "userName")
    public abstract TestUserVo entityToVo(TestUserEntity testUserEntity);
    public abstract List<TestUserVo> entityListToVoList(List<TestUserEntity> testUserEntities);
    public abstract Page<TestUserVo> pageEntityToPageVO(IPage<TestUserEntity> list);
}