All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.haoxuer.discover.user.rest.convert.UserBindResponseConvert Maven / Gradle / Ivy

There is a newer version: 3.3.18-20230117
Show newest version
package com.haoxuer.discover.user.rest.convert;

import com.haoxuer.discover.user.api.domain.response.UserBindResponse;
import com.haoxuer.discover.user.data.entity.UserBind;
import com.haoxuer.discover.data.rest.core.Conver;
import com.haoxuer.discover.data.utils.BeanDataUtils;

public class UserBindResponseConvert implements Conver {
    @Override
    public UserBindResponse conver(UserBind source) {
        UserBindResponse result = new UserBindResponse();
        BeanDataUtils.copyProperties(source,result);

        if(source.getUser()!=null){
           result.setUser(source.getUser().getId());
        }
         if(source.getUser()!=null){
            result.setUserName(source.getUser().getName());
         }

         result.setBindTypeName(source.getBindType()+"");

        return result;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy