Commit cad0f4b6 authored by 蔡镇泽's avatar 蔡镇泽

更改文件上传接口返回值类型

parent 37566872
...@@ -12,7 +12,6 @@ import com.hungraim.ltc.pojo.entity.serviceManage.ChSrvOrganEmp; ...@@ -12,7 +12,6 @@ import com.hungraim.ltc.pojo.entity.serviceManage.ChSrvOrganEmp;
import com.hungraim.ltc.pojo.vo.disable.SrvOrganEmpListVo; import com.hungraim.ltc.pojo.vo.disable.SrvOrganEmpListVo;
import com.hungraim.ltc.pojo.vo.disable.SrvOrganEmpVo; import com.hungraim.ltc.pojo.vo.disable.SrvOrganEmpVo;
import com.hungraim.ltc.pojo.vo.system.AttachUpdateVo; import com.hungraim.ltc.pojo.vo.system.AttachUpdateVo;
import com.hungraim.ltc.pojo.vo.system.AttachVo;
import com.hungraim.ltc.service.OrganService; import com.hungraim.ltc.service.OrganService;
import com.hungraim.ltc.service.SrvOrganEmpService; import com.hungraim.ltc.service.SrvOrganEmpService;
import com.hungraim.ltc.util.AttachType; import com.hungraim.ltc.util.AttachType;
...@@ -24,7 +23,6 @@ import org.springframework.beans.BeanUtils; ...@@ -24,7 +23,6 @@ import org.springframework.beans.BeanUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import java.util.ArrayList;
import java.util.List; import java.util.List;
@Service @Service
...@@ -68,16 +66,9 @@ public class SrvOrganEmpServiceImpl implements SrvOrganEmpService { ...@@ -68,16 +66,9 @@ public class SrvOrganEmpServiceImpl implements SrvOrganEmpService {
srvOrganEmpVo.setEmpCateId(chCfgSrvEmpType.getEmpCateId()); srvOrganEmpVo.setEmpCateId(chCfgSrvEmpType.getEmpCateId());
srvOrganEmpVo.setUnifiedSocialCreditCode(chSrvOrgan.getUnifiedSocialCreditCode()); srvOrganEmpVo.setUnifiedSocialCreditCode(chSrvOrgan.getUnifiedSocialCreditCode());
try { try {
Result<List<AttachVo>> listResult = attachFeignService.selectAttachs(empId, AttachType.SRV_ORGAN_EMP.getUploadType()); Result<List<ChFndAttach>> listResult = attachFeignService.selectAttachs(empId, AttachType.SRV_ORGAN_EMP.getUploadType());
if (ResultCode.SUCCESS.getCode().equals(listResult.getCode())) { if (ResultCode.SUCCESS.getCode().equals(listResult.getCode())) {
List<ChFndAttach> attaches = new ArrayList<>(); srvOrganEmpVo.setFileDataList(listResult.getData());
List<AttachVo> data = listResult.getData();
for (AttachVo datum : data) {
ChFndAttach attach = new ChFndAttach();
BeanUtils.copyProperties(datum, attach);
attaches.add(attach);
}
srvOrganEmpVo.setFileDataList(attaches);
} else { } else {
log.error("请求获取护理人员上传文件出错,出错信息:{}", listResult.getMsg()); log.error("请求获取护理人员上传文件出错,出错信息:{}", listResult.getMsg());
} }
......
...@@ -76,7 +76,7 @@ public class FileUploadController { ...@@ -76,7 +76,7 @@ public class FileUploadController {
if (null == ctrlId || 0 == ctrlId || null == attachType) { if (null == ctrlId || 0 == ctrlId || null == attachType) {
return Result.failed(ResultCode.REQUEST_PARAM_ERROR); return Result.failed(ResultCode.REQUEST_PARAM_ERROR);
} }
List<ChFndAttach> attachVos = attachService.selectAttachs(ctrlId, attachType); List<ChFndAttach> chFndAttaches = attachService.selectAttachs(ctrlId, attachType);
return Result.success(attachVos); return Result.success(chFndAttaches);
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment