package com.iailab.module.system.convert.tenant;
|
|
import com.iailab.module.infra.api.db.dto.DataSourceConfigRespDTO;
|
import com.iailab.module.system.api.tenant.dto.TenantDataSourceConfigRespDTO;
|
import com.iailab.module.system.controller.admin.tenant.vo.tenant.TenantSaveReqVO;
|
import com.iailab.module.system.controller.admin.user.vo.user.UserSaveReqVO;
|
import org.mapstruct.Mapper;
|
import org.mapstruct.factory.Mappers;
|
|
/**
|
* 租户 Convert
|
*
|
* @author iailab
|
*/
|
@Mapper
|
public interface TenantConvert {
|
|
TenantConvert INSTANCE = Mappers.getMapper(TenantConvert.class);
|
|
default UserSaveReqVO convert02(TenantSaveReqVO bean) {
|
UserSaveReqVO reqVO = new UserSaveReqVO();
|
reqVO.setUsername(bean.getUsername());
|
reqVO.setPassword(bean.getPassword());
|
reqVO.setNickname(bean.getContactName()).setMobile(bean.getContactMobile());
|
return reqVO;
|
}
|
|
TenantDataSourceConfigRespDTO convert(DataSourceConfigRespDTO bean);
|
|
}
|