package com.gkhy.labRiskManage.application.attachment.converter; import com.gkhy.labRiskManage.application.attachment.service.dto.resp.AttachmentAppRespDTO; import com.gkhy.labRiskManage.domain.attachment.dto.resp.AttachmentDomainDTO; import org.springframework.beans.BeanUtils; import org.springframework.stereotype.Component; /** * @email 1603559716@qq.com * @author: zf * @date: 2023/5/7 * @time: 17:12 */ @Component public class AttachmentAppConverter { public AttachmentAppRespDTO getAppRespDTO(AttachmentDomainDTO attachmentDomainDTO){ if(attachmentDomainDTO == null){ return null; } AttachmentAppRespDTO appRespDTO = new AttachmentAppRespDTO(); BeanUtils.copyProperties(attachmentDomainDTO,appRespDTO); return appRespDTO; } }