liusheng
2023-08-09 2c16ba7f4cdfedf4ec05395e20caf9c87f2b5101
ruoyi-project/src/main/java/com/ruoyi/project/service/impl/ServiceReimbursementServiceImpl.java
@@ -241,9 +241,13 @@
        List<RbDetailFile> parseArray = JSON.parseArray(remShare.getAnnexfiles(), RbDetailFile.class);
        for (int i = 0; i < parseArray.size(); i++) {
            RbDetailFile rbDetailFile = parseArray.get(i);
            log.info("filePath的修改:{}", filePath);
            String strFile = rbDetailFile.getUrl().replaceAll("/profile/upload", filePath);
            File filetest = new File(strFile);
            String url = rbDetailFile.getUrl();
            //file用的是绝对位置
            String substring = url.substring(url.indexOf("/profile/upload") + "/profile/upload".length());
            String strFile = rbDetailFile.getUrl().replace(filePath, "/profile/upload");
            File filetest = new File(filePath + substring);
            try {
                log.info("请求第三方的入参strFile : {}, strFUrl : {}", strFile, filePath);
                String struploadResult = HttpClientKit.sendPostWithFile(filetest, strFUrl);