maven
5 天以前 74dfb82a264f1b779e50058145953caca907f6f2
src/main/java/com/ruoyi/purchase/service/impl/TicketRegistrationServiceImpl.java
@@ -135,7 +135,7 @@
        BeanUtils.copyProperties(ticketRegistrationDto, ticketRegistration);
        ticketRegistration.setPurchaseContractNumber(purchaseLedger.getPurchaseContractNumber());
        ticketRegistration.setTenantId(purchaseLedger.getTenantId());
        ticketRegistration.setIssueDate(ticketRegistrationDto.getIssueDate());
        ticketRegistration.setIssueDate(ticketRegistrationDto.getEntryDate());
        ticketRegistration.setContractAmount(purchaseLedger.getContractAmount());
        ticketRegistration.setSalesLedgerId(purchaseLedger.getSalesLedgerId());
        ticketRegistration.setEnterDate(ticketRegistrationDto.getEnterDate());
@@ -222,13 +222,7 @@
            Path formalFilePath = formalDirPath.resolve(formalFilename);
            try {
                // 执行文件迁移(使用原子操作确保安全性)
//                Files.move(
//                        Paths.get(tempFile.getTempPath()),
//                        formalFilePath,
//                        StandardCopyOption.REPLACE_EXISTING,
//                        StandardCopyOption.ATOMIC_MOVE
//                );
                // 原子移动失败,使用复制+删除
                Files.copy(Paths.get(tempFile.getTempPath()), formalFilePath, StandardCopyOption.REPLACE_EXISTING);
                Files.deleteIfExists(Paths.get(tempFile.getTempPath()));