Преглед на файлове

feat(采购):出证下载

Wangyafan преди 9 месеца
родител
ревизия
4939a1330e

+ 2 - 2
src/main/java/com/sunxung/factoring/service/purchcontractmanagement/impl/PurchContractElectronicInfoServiceImpl.java

@@ -664,8 +664,8 @@ public class PurchContractElectronicInfoServiceImpl extends ServiceImpl<PurchCon
         fileName = new String(fileName.getBytes("UTF-8"), "ISO8859-1");
         res.setContentType("application/zip");
         res.setHeader("Content-disposition", String.format("attachment; filename=" + fileName));
-        PurchContractManagement purchContractManagement = purchContractService.get(managerId);
-        PurchContractBasicInfo purchContractBasicInfo = purchContractBasicInfoService.findByBusinessNumberAndSupplierId(purchContractManagement.getBusinessNumber(), purchContractManagement.getSupplierId());
+        PurchContractBasicInfo purchContractBasicInfo = purchContractBasicInfoService
+                .lambdaQuery().eq(PurchContractBasicInfo::getPurchContractManagementId,managerId).one();
         AttachmentDto attachmentDto = AttachmentDto.builder()
                 .setEntityId(purchContractBasicInfo.getId())
                 .setChildEnum(FileModuleDict.ChildEnum.PURCHASE_CONTRACT_SIGN_FILE_REPORT)