| | |
| | | |
| | | String templatePath = FileUtils.path(cmsProperties.getTemplatePath(), company.getCode()); |
| | | String staticPath = FileUtils.path(cmsProperties.getStaticPath(), company.getCode()); |
| | | String downloadPath = FileUtils.path(cmsProperties.getDownloadPath(), company.getCode()); |
| | | |
| | | String fileName = "template.zip"; |
| | | ZipUtil.zip(FileUtil.file(staticPath + "/template.zip"), true, FileUtil.file(templatePath), FileUtil.file(staticPath)); |
| | | |
| | | return Result.ok("success", cmsProperties.getStaticUrl() + company.getCode() + "/" + fileName); |
| | | ZipUtil.zip(FileUtil.file(downloadPath + "/template.zip"), true, FileUtil.file(templatePath), FileUtil.file(staticPath)); |
| | | String url = cmsProperties.getStaticUrl() + "download/" + company.getCode(); |
| | | return Result.ok("success", url +"/" + fileName); |
| | | } |
| | | } |