Przeglądaj źródła

Merge branch 'wq1' of SH-Arbitrate/Mediation-Backend into dev

wangqiong123 2 lat temu
rodzic
commit
c84ba68599

+ 4
- 2
ruoyi-admin/src/main/java/com/ruoyi/web/controller/wisdomarbitrate/mscase/MsVideoConferenceController.java Wyświetl plik

120
                 }
120
                 }
121
             }else {
121
             }else {
122
                 // 如果是调解书并且是pdf,则删除之前的在新增
122
                 // 如果是调解书并且是pdf,则删除之前的在新增
123
-                if(isMediaBook != null && isMediaBook == 1 && caseId!=null){
123
+                if(isMediaBook != null && isMediaBook == 1 ){
124
                     if(StrUtil.isNotEmpty(suffix)&&!suffix.equals("pdf")){
124
                     if(StrUtil.isNotEmpty(suffix)&&!suffix.equals("pdf")){
125
                         return AjaxResult.error("请上传pdf格式文件");
125
                         return AjaxResult.error("请上传pdf格式文件");
126
                     }
126
                     }
127
                     annexType=AnnexTypeEnum.MEDIATE_BOOK_PDF.getCode();
127
                     annexType=AnnexTypeEnum.MEDIATE_BOOK_PDF.getCode();
128
                     // 先删除之前的附件
128
                     // 先删除之前的附件
129
-                    msCaseAttachMapper.deleteCaseAttachByCasedIdAndType(caseId, annexType);
129
+                    if(caseId!=null) {
130
+                        msCaseAttachMapper.deleteCaseAttachByCasedIdAndType(caseId, annexType);
131
+                    }
130
                 }
132
                 }
131
                 Long annexId = saveCaseAttach(annexType, fileName, file.getOriginalFilename(), caseId);
133
                 Long annexId = saveCaseAttach(annexType, fileName, file.getOriginalFilename(), caseId);
132
                 // 是否上传到onlyoffice
134
                 // 是否上传到onlyoffice