jiazx0107
39 分钟以前 0661d40712d7d1ce234f9d0afa6a58f7b8ca56ec
fzzy-igdss-core/src/main/java/com/fzzy/igds/service/FileService.java
@@ -178,6 +178,38 @@
    }
    /**
     * 获取临时路径
     * @param companyId
     * @return
     */
    public String getTempFilePath(String companyId) {
        String basePath = FrameworkConfig.getProfile() + "TEMP/";
        if (org.apache.commons.lang3.StringUtils.isNotEmpty(companyId)) {
            basePath += companyId + "/";
        }
        File file = new File(basePath);
        if (!file.exists()) {
            file.mkdirs();
        }
        return basePath;
    }
    /**
     * 获取模板路径
     * @return
     */
    public String getConfPath() {
        String basePath = FrameworkConfig.getProfile() + "CONF/";
        File file = new File(basePath);
        if (!file.exists()) {
            file.mkdirs();
        }
        return basePath;
    }
    /**
     * 压缩图片
     *
     * @param filePath   压缩前路径
@@ -201,4 +233,6 @@
        ImageIO.write(compressedImage, "jpg", new File(outputPath));
    }
}