package com.winhc.repal.model.cvt; import com.winhc.repal.entity.RepalBook; import com.winhc.repal.model.dto.RepalBookDTO; import com.winhc.repal.model.vo.RepalBookVO; import org.springframework.beans.BeanUtils; /** * @description RepalBook 对象转换类 * @author Generator * @date 2022-04-08 */ public class RepalBookConvert { public static RepalBook DTOToEntity(RepalBookDTO dto) { RepalBook entity = new RepalBook(); BeanUtils.copyProperties(dto, entity); return entity; } public static RepalBookVO EntityToVO(RepalBook entity) { RepalBookVO vo = new RepalBookVO (); BeanUtils.copyProperties(entity, vo); return vo; } }