Przeglądaj źródła

update 取消多余父部门类别编码获取

AprilWind 1 rok temu
rodzic
commit
479b17a8c2

+ 0 - 5
ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/domain/vo/SysDeptVo.java

@@ -41,11 +41,6 @@ public class SysDeptVo implements Serializable {
      */
     private String parentName;
 
-    /**
-     * 父部门类别编码
-     */
-    private String parentCategory;
-
     /**
      * 祖级列表
      */

+ 2 - 5
ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysDeptServiceImpl.java

@@ -135,11 +135,8 @@ public class SysDeptServiceImpl implements ISysDeptService, DeptService {
             return null;
         }
         SysDeptVo parentDept = baseMapper.selectVoOne(new LambdaQueryWrapper<SysDept>()
-            .select(SysDept::getDeptName, SysDept::getDeptCategory).eq(SysDept::getDeptId, dept.getParentId()));
-        if (ObjectUtil.isNotNull(parentDept)) {
-            dept.setParentName(parentDept.getDeptName());
-            dept.setParentCategory(parentDept.getDeptCategory());
-        }
+            .select(SysDept::getDeptName).eq(SysDept::getDeptId, dept.getParentId()));
+        dept.setParentName(ObjectUtil.isNotNull(parentDept) ? parentDept.getDeptName() : null);
         return dept;
     }