lxw
2023-10-21 672913e8146c7f82f8157cc8bbd8499344870cdf
getOriginalZip原始包下载
2个文件已修改
8 ■■■■ 已修改文件
src/main/java/com/whyc/controller/ProductController.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/whyc/service/ProductBomHistoryService.java 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/main/java/com/whyc/controller/ProductController.java
@@ -90,8 +90,8 @@
    @ApiOperation(value = "根据产品母料型号,定制单号,版本下载原始压缩包文件",notes = "11.17修改后使用")
    @GetMapping("getOriginalZip")
    public Response getOriginalZip( @RequestParam String parentModel,@RequestParam(required = false) String customCode,@RequestParam int version){
        return bomHistoryService.getOriginalZip(parentModel,customCode,version);
    public Response getOriginalZip(@RequestParam String parentCode, @RequestParam String parentModel,@RequestParam(required = false) String customCode,@RequestParam int version){
        return bomHistoryService.getOriginalZip(parentCode,parentModel,customCode,version);
    }
src/main/java/com/whyc/service/ProductBomHistoryService.java
@@ -669,7 +669,7 @@
    }
    //根据产品母料型号,定制单号,版本下载原始压缩包文件
    public Response getOriginalZip(String parentModel, String customCode, int version) {
    public Response getOriginalZip(String parentCode,String parentModel, String customCode, int version) {
        String fileDirName = FileDirPath.getFileDirName();
        String withOutDwg=fileDirName+File.separator+"doc_file"+File.separator+"product"+File.separator+parentModel;
        if(customCode!=null&&!customCode.isEmpty()){
@@ -685,7 +685,7 @@
        String[] filePath = file.list();//获取该文件夹下的所有文件以及目录的名字
        if(filePath!=null&&filePath.length>0){
            for (String tmp:filePath) {
                if(tmp.contains(parentModel)&&tmp.contains(".zip")){
                if((tmp.contains(parentCode)||tmp.contains(parentModel))&&tmp.contains(".zip")){
                    bl=true;
                    withOutDwg=withOutDwg+File.separator+tmp;
                    break;