chenr 2 сар өмнө
parent
commit
3c502b8fa0

+ 4 - 0
blade-service/blade-business/src/main/java/org/springblade/business/mapper/ArchiveFileMapper.xml

@@ -160,6 +160,10 @@
         <if test="vo.rectification != null and vo.rectification != ''">
             and u.rectification = #{vo.rectification}
         </if>
+        <if test="vo.sourceType != null and vo.sourceType != ''">
+            and u.source_type = #{sourceType}
+        </if>
+
         <if test="vo.rectification == null and vo.archiveId == null">
             and (u.is_auto_file is null or u.is_auto_file != 1)
         </if>

+ 7 - 4
blade-service/blade-manager/src/main/java/org/springblade/manager/controller/ArchiveTreeContractController.java

@@ -154,7 +154,10 @@ public class ArchiveTreeContractController extends BladeController {
     @PostMapping("/update")
     @ApiOperationSupport(order = 5)
     @ApiOperation(value = "修改", notes = "传入archiveTreeContract")
-    public R update(@Valid @RequestBody ArchiveTreeContract archiveTreeContract) {
+    /**
+     * isSaveChild 0是保存子节点,1不保存子节点
+     */
+    public R update(@Valid @RequestBody ArchiveTreeContract archiveTreeContract,Integer isSaveChild) {
         if (archiveTreeContract == null) {
             return R.fail(200, "未查询到对应节点信息");
         }
@@ -219,9 +222,9 @@ public class ArchiveTreeContractController extends BladeController {
 
         boolean b = archiveTreeContractService.updateById(ar);
         //更新下级节点为同一规则
-
-        archiveTreeContractService.updateAllSonNodeIdsForArchiveAutoRule(ar);
-
+        if(isSaveChild==0){
+            archiveTreeContractService.updateAllSonNodeIdsForArchiveAutoRule(ar);
+        }
         return R.status(b);
     }