package com.cf.imes.module.system.convert.organ;

import com.cf.imes.module.system.controller.admin.organ.vo.organ.OrganSaveReqVO;
import com.cf.imes.module.system.controller.admin.user.vo.user.UserSaveReqVO;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

/**
 * 组织 Convert
 *
 * @author 晨丰科技
 */
@Mapper
public interface OrganConvert {

    OrganConvert INSTANCE = Mappers.getMapper(OrganConvert.class);

    default UserSaveReqVO convert02(OrganSaveReqVO bean) {
        UserSaveReqVO reqVO = new UserSaveReqVO();
        reqVO.setUsername(bean.getUsername());
        reqVO.setPassword(bean.getPassword());
        reqVO.setNickname(bean.getContactName()).setMobile(bean.getContactMobile());
        return reqVO;
    }

}
